reg
*v0.Registry- OID
- 07bdfd…3e5f:4
reg details
caller
func() .uverse.address- OID
- 07bdfd…3e5f:8
caller details
must
func(err .uverse.error)- OID
- 07bdfd…3e5f:10
must details
resolveName
func(name string) (.uverse.address, bool)- OID
- 07bdfd…3e5f:11
resolveName details
Register
func(pkgPath string, repo string, commit string, dir string, ref string)Register records that pkgPath was built from dir of repo at commit. Calling it again for the same path replaces the caller's own claim and nobody else's, so moving a claim to a new commit after a redeploy is one call with no read first. ref is optional and is never the thing verified: a ref moves, a commit does not. It is recorded so a reader can tell a claim pinned to a released tag from one pinned to a commit on nobody's branch, and so a verifier can report a commit that has since been orphaned by a force-push. dir is empty when the package sits at the repository root.
- OID
- 07bdfd…3e5f:12
Register details
Withdraw
func(pkgPath string)Withdraw removes the caller's own claim about pkgPath.
- OID
- 07bdfd…3e5f:13
Withdraw details
PackageCount
func() intPackageCount is how many package paths carry at least one claim.
- OID
- 07bdfd…3e5f:14
PackageCount details
ClaimCount
func() intClaimCount is the total number of claims across every path.
- OID
- 07bdfd…3e5f:15
ClaimCount details
HasClaims
func(pkgPath string) boolHasClaims reports whether anything has been said about pkgPath. Cheap enough for another realm or an indexer to ask per package.
- OID
- 07bdfd…3e5f:16
HasClaims details
OwnerClaim
func(pkgPath string) (repo string, commit string, dir string, ok bool)OwnerClaim returns the repository, commit and directory claimed by the party that owns pkgPath's namespace, and whether such a claim exists. This is the only read that filters, and it filters on the one signal the chain can actually prove. Everything else a caller wants is in Render or in the events.
- OID
- 07bdfd…3e5f:17
OwnerClaim details
pageSize
untyped bigintpageSize bounds every listing: a Render that walks unbounded state is a Render that eventually stops rendering.
Value
(20 <untyped> bigint)
Render
func(path string) stringRender routes gnoweb paths: / every claimed package path /<package path> the claims about one package /help what this realm is, and how to write to it
- OID
- 07bdfd…3e5f:18
Render details
base
func() string- OID
- 07bdfd…3e5f:20
base details
pkgURL
func(pkgPath string) string- OID
- 07bdfd…3e5f:21
pkgURL details
link
func(text string, url string) stringlink does not escape its text, because every call site passes a field that is charset-validated at write time (see the note above). Escaping here would turn "gno.land/p/moul/md/v1" into "gno\\.land/p/moul/md/v1" on every row of every listing, for no safety anyone gains.
- OID
- 07bdfd…3e5f:22
link details
join
func(blocks []string) stringjoin glues blocks with exactly one blank line between them. gno collapses two consecutive blank lines inside an example's // Output: block, exactly as Go does, so a Render that ever emits them cannot be pinned by an example at all. Appending "\\n" by hand as sections are built is how a Render acquires them; assembling a list of blocks and joining once is how it stops. Every block arrives without its own leading or trailing blank.
- OID
- 07bdfd…3e5f:23
join details
pageOf
func(req *v0.Request) int- OID
- 07bdfd…3e5f:24
pageOf details
notFound
func(why string) stringnotFound echoes the requested path, which is the only untrusted string this file handles: it comes from the URL and has already failed validation by the time we are here. It is escaped rather than dropped, because "that is not a package path" without saying which one is an unhelpful error.
- OID
- 07bdfd…3e5f:25
notFound details
renderHome
func(page int) string- OID
- 07bdfd…3e5f:26
renderHome details
pager
func(page int, rows int) string- OID
- 07bdfd…3e5f:27
pager details
renderPackage
func(pkgPath string) string- OID
- 07bdfd…3e5f:28
renderPackage details
claimBlock
func(c *v0.Claim) string- OID
- 07bdfd…3e5f:29
claimBlock details
renderHelp
func() string- OID
- 07bdfd…3e5f:30