Gno.land
Package ns is a Plan 9 namespace: a private, mutable mount table over gno.land/p/moul/x/plan9/ninep file trees. This is the idea the rest of the suite exists for. Plan 9's leverage does not come from "everything is a file", it comes from every process owning its own name-to-resource mapping, so a name can be REPLACED and any service can be composed, shadowed, sandboxed or mocked without the program knowing. Gno has one global tree and no way to hold a view of it; an Ns is that view. Bind flags follow bind(2): MREPL replaces, MBEFORE splices the new directory in front of the old one, MAFTER behind it, and MCREATE (OR'd onto any of them) marks the union member that new files are created in. Two Plan 9 properties are load-bearing and reproduced deliberately: - A union is TOP LEVEL ONLY. Binding /a onto /b unions the two directories at /b; /b/c resolves in whichever member won the walk, and is not itself a union unless something is bound there too. - A bind captures a CHANNEL, not a name. The source is resolved once, at bind time, and the resulting file is what is stored. Rebinding the source afterwards does not retroactively move the target. ".." is removed lexically before resolution starts and never reaches a server, per "Lexical File Names in Plan 9, or Getting Dot-Dot Right". NOTICE. Plan 9 from Bell Labs is the work of the Computing Science Research Center at Bell Labs; the name and the marks are theirs, and the copyright is held by the Plan 9 Foundation ([https://p9f.org](https://p9f.org)). This package is not affiliated with, endorsed by, or sponsored by them, and contains no Plan 9 code: it borrows the vocabulary so that the design reads without a glossary, and it is an homage, asking what that ecosystem's spirit looks like on a chain. Full attribution: NOTICE.md at the root of moul/gno-contracts.