registry-path.tri (493B)
1 !import prelude * 2 !export * 3 -- Existing registry layout, isolated so both route approaches share exactly 4 -- the same pure path helper rather than comparing different workloads. 5 pathJoin a b = append a (append "/" b) 6 hashShard hash = matchList t (h0 r0 : matchList (pair h0 t) 7 (h1 r1 : matchList (pair h0 (pair h1 t)) 8 (h2 _ : pair h0 (pair h1 (pair h2 t))) r1) r0) hash 9 bundleObjectPath root hash = pathJoin (pathJoin (pathJoin root "objects") (hashShard hash)) (append hash ".arboricx")