Sign in

Search issue titles and bodies, change requests and comments. Private repositories you cannot read are not included.

vole
Clone

Read only, no credentials:

https://rodent.software/git/vole.git

Write over SSH with a registered key:

git clone ssh://git@0.0.0.0:2222/vole.git

A free and open-source forge that lives in your Git repo.

Store changes under changes/<ulid>/change.md

b492b557f5cc5633b3dcb21fdbb5e2ad98d0bc16 · Keenan Nemetz · 3d ago · parent 9bce3723

Store changes under changes/<ulid>/change.md

The web, the CLI, and the docs call these items changes; only the metadata
tree still said requests. Rename the directory and the record file so the
format and the product use one word.

The tree is a contract, so this is a format change rather than a display
change: the top-level layout stays closed, and a request path no longer
validates. An existing repository is migrated by rewriting its vole branch,
which is an audited admin force-push; the index rebuilds from the new tip
and the #N aliases keep their ULIDs because the rewrite preserves commit
order.

Refs #202 (01M6S3JC3Y2KA6EFJK6APX7A1T).

metadata/issues.go +8−8

@@ -4,7 +4,7 @@
4 4 // refs/heads/vole
5 5 // issues/<ulid>/issue.md frontmatter + body
6 6 // issues/<ulid>/comments/<ulid>.md frontmatter + body
7 // requests/... reserved for change requests
7 // changes/... reserved for change requests
8 8 //
9 9 // Metadata is frontmatter markdown rather than JSON because the diffs are the
10 10 // interface: one field per line, one label per line, so closing an issue changes
@@ -42,8 +42,8 @@ const (
42 42 Ref = "refs/heads/vole"
43 43 // IssuesDir is the issues subtree inside that branch.
44 44 IssuesDir = "issues"
45 // RequestsDir is the change-request subtree.
46 RequestsDir = "requests"
45 // ChangesDir is the change-request subtree.
46 ChangesDir = "changes"
47 47 // ReleasesDir is the release-artifact subtree.
48 48 ReleasesDir = "releases"
49 49
@@ -469,8 +469,8 @@ func (e *ValidationError) Error() string {
469 469 }
470 470
471 471 // Validate checks the metadata branch at commit and reports every problem. The
472 // top-level layout is closed: only issues/ and requests/ may appear, so a typo in
473 // a directory name is caught instead of silently ignored by the web.
472 // top-level layout is closed: only issues/, changes/ and releases/ may appear, so
473 // a typo in a directory name is caught instead of silently ignored by the web.
474 474 func ValidateIssues(g *git.Repo, commit string) []string {
475 475 if commit == "" || commit == git.ZeroSHA {
476 476 return nil // deleting the branch is allowed
@@ -482,7 +482,7 @@ func ValidateIssues(g *git.Repo, commit string) []string {
482 482 // Refuse an oversized tree before reading any of it: a rejected push should
483 483 // cost the receiver nothing either.
484 484 var problems []string
485 for _, prefix := range []string{IssuesDir, RequestsDir} {
485 for _, prefix := range []string{IssuesDir, ChangesDir} {
486 486 paths, shas := metadataPaths(blobs, prefix)
487 487 problems = append(problems, metadataSizeProblems(paths, shas, g)...)
488 488 }
@@ -495,7 +495,7 @@ func ValidateIssues(g *git.Repo, commit string) []string {
495 495 case strings.HasPrefix(e.Name, IssuesDir+"/"):
496 496 paths = append(paths, e.Name)
497 497 shas = append(shas, e.SHA)
498 case strings.HasPrefix(e.Name, RequestsDir+"/"):
498 case strings.HasPrefix(e.Name, ChangesDir+"/"):
499 499 // Reserved: change requests are validated by their own code when they
500 500 // land. Accepting the prefix now keeps the layout stable.
501 501 case strings.HasPrefix(e.Name, ReleasesDir+"/"):
@@ -505,7 +505,7 @@ func ValidateIssues(g *git.Repo, commit string) []string {
505 505 default:
506 506 problems = append(problems, fmt.Sprintf(
507 507 "%s: metadata may only contain %s/, %s/ and %s/",
508 e.Name, IssuesDir, RequestsDir, ReleasesDir))
508 e.Name, IssuesDir, ChangesDir, ReleasesDir))
509 509 continue
510 510 }
511 511 }