detached f886b9a

chore: bootstrap ermite-git module with license, readme and CI

commit
f886b9a5515611d4a7e50909355482f655db2226
author
brice · · 2026-10-09 16:42 UTC
parent
none (root commit)
signature
GPG VerifiedCD88F9E564E0102646FB6077A1A07C7C7C3E349D · arch-gpg Verified for the committer email
7 files · +105 -0
A .forgejo/workflows/ci.yml +41 -0
@@ -0,0 +1,41 @@
1+name: CI
2+
3+on:
4+ push:
5+ branches: [main]
6+ pull_request:
7+
8+env:
9+ # Test the module alone, with the versions in go.mod (never a go.work).
10+ GOWORK: "off"
11+ GOPRIVATE: bnema.dev/ermite*
12+
13+jobs:
14+ lint:
15+ name: Lint
16+ runs-on: ubuntu-latest
17+ steps:
18+ - uses: actions/checkout@v6
19+ - uses: actions/setup-go@v5
20+ with:
21+ go-version-file: go.mod
22+ cache: true
23+ - uses: golangci/golangci-lint-action@v9
24+ with:
25+ version: v2.14.0
26+
27+ test:
28+ name: Test
29+ runs-on: ubuntu-latest
30+ steps:
31+ - uses: actions/checkout@v6
32+ - uses: actions/setup-go@v5
33+ with:
34+ go-version-file: go.mod
35+ cache: true
36+ - name: Verify tidy
37+ run: |
38+ go mod tidy
39+ git diff --exit-code -- go.mod go.sum
40+ - run: go vet ./...
41+ - run: go test -race ./...
@@ -0,0 +1,41 @@
1+name: CI
2+
3+on:
4+ push:
5+ branches: [main]
6+ pull_request:
7+
8+env:
9+ # Test the module alone, with the versions in go.mod (never a go.work).
10+ GOWORK: "off"
11+ GOPRIVATE: bnema.dev/ermite*
12+
13+jobs:
14+ lint:
15+ name: Lint
16+ runs-on: ubuntu-latest
17+ steps:
18+ - uses: actions/checkout@v6
19+ - uses: actions/setup-go@v5
20+ with:
21+ go-version-file: go.mod
22+ cache: true
23+ - uses: golangci/golangci-lint-action@v9
24+ with:
25+ version: v2.14.0
26+
27+ test:
28+ name: Test
29+ runs-on: ubuntu-latest
30+ steps:
31+ - uses: actions/checkout@v6
32+ - uses: actions/setup-go@v5
33+ with:
34+ go-version-file: go.mod
35+ cache: true
36+ - name: Verify tidy
37+ run: |
38+ go mod tidy
39+ git diff --exit-code -- go.mod go.sum
40+ - run: go vet ./...
41+ - run: go test -race ./...
A .gitignore +1 -0
@@ -0,0 +1,1 @@
1+/tmp/
@@ -0,0 +1,1 @@
1+/tmp/
A .golangci.yml +13 -0
@@ -0,0 +1,13 @@
1+version: "2"
2+
3+linters:
4+ enable:
5+ - errcheck
6+ - govet
7+ - ineffassign
8+ - misspell
9+ - staticcheck
10+ - unconvert
11+ - unused
12+ exclusions:
13+ generated: strict
@@ -0,0 +1,13 @@
1+version: "2"
2+
3+linters:
4+ enable:
5+ - errcheck
6+ - govet
7+ - ineffassign
8+ - misspell
9+ - staticcheck
10+ - unconvert
11+ - unused
12+ exclusions:
13+ generated: strict
A LICENSE +21 -0
@@ -0,0 +1,21 @@
1+MIT License
2+
3+Copyright (c) 2026 bnema
4+
5+Permission is hereby granted, free of charge, to any person obtaining a copy
6+of this software and associated documentation files (the "Software"), to deal
7+in the Software without restriction, including without limitation the rights
8+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+copies of the Software, and to permit persons to whom the Software is
10+furnished to do so, subject to the following conditions:
11+
12+The above copyright notice and this permission notice shall be included in all
13+copies or substantial portions of the Software.
14+
15+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+SOFTWARE.
@@ -0,0 +1,21 @@
1+MIT License
2+
3+Copyright (c) 2026 bnema
4+
5+Permission is hereby granted, free of charge, to any person obtaining a copy
6+of this software and associated documentation files (the "Software"), to deal
7+in the Software without restriction, including without limitation the rights
8+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+copies of the Software, and to permit persons to whom the Software is
10+furnished to do so, subject to the following conditions:
11+
12+The above copyright notice and this permission notice shall be included in all
13+copies or substantial portions of the Software.
14+
15+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+SOFTWARE.
A README.md +19 -0
@@ -0,0 +1,19 @@
1+# ermite-git
2+
3+A fast, read-only Git repository reader for Go: refs, objects, packfiles, trees and history, using commit-graph and changed-path Bloom filters. Standard library only.
4+
5+Status: early development, no stable API.
6+
7+```go
8+import git "bnema.dev/ermite-git"
9+```
10+
11+## Test
12+
13+```sh
14+go test ./...
15+```
16+
17+## License
18+
19+MIT. See [LICENSE](LICENSE).
@@ -0,0 +1,19 @@
1+# ermite-git
2+
3+A fast, read-only Git repository reader for Go: refs, objects, packfiles, trees and history, using commit-graph and changed-path Bloom filters. Standard library only.
4+
5+Status: early development, no stable API.
6+
7+```go
8+import git "bnema.dev/ermite-git"
9+```
10+
11+## Test
12+
13+```sh
14+go test ./...
15+```
16+
17+## License
18+
19+MIT. See [LICENSE](LICENSE).
A doc.go +7 -0
@@ -0,0 +1,7 @@
1+// SPDX-License-Identifier: MIT
2+
3+// Package git reads Git repositories without the git binary: refs, loose
4+// and packed objects, trees, blobs and commit history. It uses the
5+// commit-graph and changed-path Bloom filters when present. It never
6+// writes to a repository.
7+package git
@@ -0,0 +1,7 @@
1+// SPDX-License-Identifier: MIT
2+
3+// Package git reads Git repositories without the git binary: refs, loose
4+// and packed objects, trees, blobs and commit history. It uses the
5+// commit-graph and changed-path Bloom filters when present. It never
6+// writes to a repository.
7+package git
A go.mod +3 -0
@@ -0,0 +1,3 @@
1+module bnema.dev/ermite-git
2+
3+go 1.27.1
@@ -0,0 +1,3 @@
1+module bnema.dev/ermite-git
2+
3+go 1.27.1

Keyboard shortcuts

Single-key shortcuts are on. ctrl k and esc work whatever this says.

ctrl k :
go to a section, branch, tag, file or repository
?
this list
j k
move the row cursor down / up
enter
open the row under the cursor; on Files, a directory opens or closes in place
↑ ↓ ← → home end
in the file tree (focus on a row): previous / next row, close / open a directory or go to its parent / first entry, first / last row. They never open a file
l h
on Files: open a directory or a file / close a directory or go up to its parent, then to the parent page. Elsewhere: into the side panel (on a merge request, its files) / back to the content; there j k move between its controls
g g G
first / last row
/
filter the list; on Files, find a file anywhere in the repository (esc clears, enter opens the best match)
b
switch branch or tag
g s g f g c g b g m g i g r g a
tabs: summary, files, commits, branches & tags, merge requests, issues, releases, actions (when available)
g h
home
w
wide mode: use the whole width of the screen, or not (remembered)
y
copy a permalink pinned to the commit
d u x
diff: split / unified / collapse or expand all
e E
diff: the whole file in view / every file, with the lines the hunks hide
n
merge request: next note in the diff
esc
close a dialog, leave a field

Branches 1

Tags 2

↑↓ moveenter openesc close