def ent.other
import ezx@1.11.0.0/src/sha/dump.bend as Dumpimport Base
import ezx@1.11.0.0/src/sha/nar.bend as Nar
53# a path of the listing with what the NAR needs of it: a file's text read, a
54# symlink's target as the listing printed it
55def ent.other(
56 known: Bool,
57 +kind: String,
58 +name: String,
59 +at: String,
60 +target: String,
61 +path: String
62) -> IO(Nar.Ent):
63 match known:
64 case True{}:
65 IO.pure(Nar.Ent, Nar.Ent{kind, False{}, name, at, target})
66 case False{}:
67 IO.die(Nar.Ent, 1, "ez: nar hash: " ++ path ++ ": not a file, directory, or symlink")