Files.path.normalize: def of bend-kit-files@0.3.1.0 Import: import bend-kit-files@0.3.1.0/files.bend as Files Lines 82-88 of bend-kit-files@0.3.1.0/files.bend: https://jend.leeeet.dev/read.txt?path=bend-kit-files@0.3.1.0/files.bend&start_line=82&end_line=88 import Base # Drops empty and "." segments and resolves "..", as POSIX normpath does # (RFC 3986 ยง5.2.4 for paths), but always to one leading "/". def path.normalize(+p: String) -> String: +abs = path.is_absolute(p) path.norm.fin(abs, String.join(List.reverse(&2, String, path.norm.go(String.split(p, '/'), Nil{}, abs)), "/")) Uses (9): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Char https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List.reverse https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String.join https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String.split https://jend.leeeet.dev/definition.txt?path=bend-kit-files@0.3.1.0/files.bend&name=path.is_absolute https://jend.leeeet.dev/definition.txt?path=bend-kit-files@0.3.1.0/files.bend&name=path.norm.fin https://jend.leeeet.dev/definition.txt?path=bend-kit-files@0.3.1.0/files.bend&name=path.norm.go