def climb
import ezx@1.11.0.0/src/pkg/path.bend as Pathimport Base
174# the path with `n` of its components climbed back off, which is where a
175# package re-roots when a module of it was reached through that many `..`
176def climb(count: Nat, path: String) -> String:
177 match count:
178 case 0n:
179 norm(path)
180 case 1n+q:
181 climb(q, dir(path))