Fs.dirname: def of cswap-bend-cli@0.1.0.0 Import: import cswap-bend-cli@0.1.0.0/fs.bend as Fs Lines 156-158 of cswap-bend-cli@0.1.0.0/fs.bend: https://jend.leeeet.dev/read.txt?path=cswap-bend-cli@0.1.0.0/fs.bend&start_line=156&end_line=158 import Base # Everything before the last `/`: "a/b/c" is "a/b", "/x" is "/", "x" is ".". def dirname(+p: String) -> String: dirname.fin(String.reverse(slash.drop(String.reverse(p))), String.starts_with(p, "/")) Uses (5): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String.reverse https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String.starts_with https://jend.leeeet.dev/definition.txt?path=cswap-bend-cli@0.1.0.0/fs.bend&name=dirname.fin https://jend.leeeet.dev/definition.txt?path=cswap-bend-cli@0.1.0.0/fs.bend&name=slash.drop