detached 20b8786

without goreleaser

commit
20b87861c47676f02d4295e4636cd19764ffe36e
author
bnema · · 2024-04-19 15:41 UTC
parent
75e22ba
signature
unsigned
1 file · +28 -8
M .github/workflows/go.yml +28 -8
@@ -16,16 +16,36 @@ jobs:
1616 with:
1717 go-version: 1.21
1818
19- - name: Run GoReleaser
20- uses: goreleaser/goreleaser-action@v3
19+ - name: Build
20+ run: |
21+ go mod tidy
22+ CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags "-s -w -X main.build=${{ github.ref_name }} -X main.commit=${{ github.sha }} -X main.date=$(date +'%Y-%m-%dT%H:%M:%SZ')" -o gordon-linux-amd64 ./cmd/cli/main.go
23+ CGO_ENABLED=0 GOOS=windows GOARCH=amd64 go build -ldflags "-s -w -X main.build=${{ github.ref_name }} -X main.commit=${{ github.sha }} -X main.date=$(date +'%Y-%m-%dT%H:%M:%SZ')" -o gordon-windows-amd64.exe ./cmd/cli/main.go
24+ CGO_ENABLED=0 GOOS=darwin GOARCH=amd64 go build -ldflags "-s -w -X main.build=${{ github.ref_name }} -X main.commit=${{ github.sha }} -X main.date=$(date +'%Y-%m-%dT%H:%M:%SZ')" -o gordon-darwin-amd64 ./cmd/cli/main.go
25+ CGO_ENABLED=0 GOOS=linux GOARCH=arm64 go build -ldflags "-s -w -X main.build=${{ github.ref_name }} -X main.commit=${{ github.sha }} -X main.date=$(date +'%Y-%m-%dT%H:%M:%SZ')" -o gordon-linux-arm64 ./cmd/cli/main.go
26+ CGO_ENABLED=0 GOOS=windows GOARCH=arm64 go build -ldflags "-s -w -X main.build=${{ github.ref_name }} -X main.commit=${{ github.sha }} -X main.date=$(date +'%Y-%m-%dT%H:%M:%SZ')" -o gordon-windows-arm64.exe ./cmd/cli/main.go
27+ CGO_ENABLED=0 GOOS=darwin GOARCH=arm64 go build -ldflags "-s -w -X main.build=${{ github.ref_name }} -X main.commit=${{ github.sha }} -X main.date=$(date +'%Y-%m-%dT%H:%M:%SZ')" -o gordon-darwin-arm64 ./cmd/cli/main.go
28+
29+ - name: Build Docker Images
30+ run: |
31+ docker buildx build --platform linux/amd64 --tag ghcr.io/bnema/gordon:${{ github.ref_name }}-amd64 --label org.opencontainers.image.created=$(date +'%Y-%m-%dT%H:%M:%SZ') --label org.opencontainers.image.title=gordon --label org.opencontainers.image.revision=${{ github.sha }} --label org.opencontainers.image.version=${{ github.ref_name }} --label org.opencontainers.image.source=https://github.com/bnema/gordon --push .
32+ docker buildx build --platform linux/arm64 --tag ghcr.io/bnema/gordon:${{ github.ref_name }}-arm64 --label org.opencontainers.image.created=$(date +'%Y-%m-%dT%H:%M:%SZ') --label org.opencontainers.image.title=gordon --label org.opencontainers.image.revision=${{ github.sha }} --label org.opencontainers.image.version=${{ github.ref_name }} --label org.opencontainers.image.source=https://github.com/bnema/gordon --push .
2133 env:
2234 GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
23- with:
24- version: latest
25- args: release --clean
26- registry: ghcr.io
27- username: ${{ github.actor }}
28- password: ${{ secrets.GITHUB_TOKEN }}
35+
36+ - name: Create Docker Manifest
37+ run: |
38+ docker manifest create ghcr.io/bnema/gordon:latest ghcr.io/bnema/gordon:${{ github.ref_name }}-amd64 ghcr.io/bnema/gordon:${{ github.ref_name }}-arm64 --amend
39+ docker manifest push ghcr.io/bnema/gordon:latest
40+
41+ - name: Create Release Artifacts
42+ run: |
43+ zip -j gordon_${{ github.ref_name }}_linux_amd64.zip gordon-linux-amd64
44+ zip -j gordon_${{ github.ref_name }}_windows_amd64.zip gordon-windows-amd64.exe
45+ zip -j gordon_${{ github.ref_name }}_darwin_amd64.zip gordon-darwin-amd64
46+ zip -j gordon_${{ github.ref_name }}_linux_arm64.zip gordon-linux-arm64
47+ zip -j gordon_${{ github.ref_name }}_windows_arm64.zip gordon-windows-arm64.exe
48+ zip -j gordon_${{ github.ref_name }}_darwin_arm64.zip gordon-darwin-arm64
2949
3050 - name: Install Cosign
3151 run: |
@@ -16,16 +16,36 @@ jobs:
16 with:16 with:
17 go-version: 1.2117 go-version: 1.21
18 18
19- - name: Run GoReleaser19+ - name: Build
20- uses: goreleaser/goreleaser-action@v320+ run: |
21+ go mod tidy
22+ CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags "-s -w -X main.build=${{ github.ref_name }} -X main.commit=${{ github.sha }} -X main.date=$(date +'%Y-%m-%dT%H:%M:%SZ')" -o gordon-linux-amd64 ./cmd/cli/main.go
23+ CGO_ENABLED=0 GOOS=windows GOARCH=amd64 go build -ldflags "-s -w -X main.build=${{ github.ref_name }} -X main.commit=${{ github.sha }} -X main.date=$(date +'%Y-%m-%dT%H:%M:%SZ')" -o gordon-windows-amd64.exe ./cmd/cli/main.go
24+ CGO_ENABLED=0 GOOS=darwin GOARCH=amd64 go build -ldflags "-s -w -X main.build=${{ github.ref_name }} -X main.commit=${{ github.sha }} -X main.date=$(date +'%Y-%m-%dT%H:%M:%SZ')" -o gordon-darwin-amd64 ./cmd/cli/main.go
25+ CGO_ENABLED=0 GOOS=linux GOARCH=arm64 go build -ldflags "-s -w -X main.build=${{ github.ref_name }} -X main.commit=${{ github.sha }} -X main.date=$(date +'%Y-%m-%dT%H:%M:%SZ')" -o gordon-linux-arm64 ./cmd/cli/main.go
26+ CGO_ENABLED=0 GOOS=windows GOARCH=arm64 go build -ldflags "-s -w -X main.build=${{ github.ref_name }} -X main.commit=${{ github.sha }} -X main.date=$(date +'%Y-%m-%dT%H:%M:%SZ')" -o gordon-windows-arm64.exe ./cmd/cli/main.go
27+ CGO_ENABLED=0 GOOS=darwin GOARCH=arm64 go build -ldflags "-s -w -X main.build=${{ github.ref_name }} -X main.commit=${{ github.sha }} -X main.date=$(date +'%Y-%m-%dT%H:%M:%SZ')" -o gordon-darwin-arm64 ./cmd/cli/main.go
28+
29+ - name: Build Docker Images
30+ run: |
31+ docker buildx build --platform linux/amd64 --tag ghcr.io/bnema/gordon:${{ github.ref_name }}-amd64 --label org.opencontainers.image.created=$(date +'%Y-%m-%dT%H:%M:%SZ') --label org.opencontainers.image.title=gordon --label org.opencontainers.image.revision=${{ github.sha }} --label org.opencontainers.image.version=${{ github.ref_name }} --label org.opencontainers.image.source=https://github.com/bnema/gordon --push .
32+ docker buildx build --platform linux/arm64 --tag ghcr.io/bnema/gordon:${{ github.ref_name }}-arm64 --label org.opencontainers.image.created=$(date +'%Y-%m-%dT%H:%M:%SZ') --label org.opencontainers.image.title=gordon --label org.opencontainers.image.revision=${{ github.sha }} --label org.opencontainers.image.version=${{ github.ref_name }} --label org.opencontainers.image.source=https://github.com/bnema/gordon --push .
21 env:33 env:
22 GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}34 GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
23- with:35+
24- version: latest36+ - name: Create Docker Manifest
25- args: release --clean37+ run: |
26- registry: ghcr.io38+ docker manifest create ghcr.io/bnema/gordon:latest ghcr.io/bnema/gordon:${{ github.ref_name }}-amd64 ghcr.io/bnema/gordon:${{ github.ref_name }}-arm64 --amend
27- username: ${{ github.actor }}39+ docker manifest push ghcr.io/bnema/gordon:latest
28- password: ${{ secrets.GITHUB_TOKEN }}40+
41+ - name: Create Release Artifacts
42+ run: |
43+ zip -j gordon_${{ github.ref_name }}_linux_amd64.zip gordon-linux-amd64
44+ zip -j gordon_${{ github.ref_name }}_windows_amd64.zip gordon-windows-amd64.exe
45+ zip -j gordon_${{ github.ref_name }}_darwin_amd64.zip gordon-darwin-amd64
46+ zip -j gordon_${{ github.ref_name }}_linux_arm64.zip gordon-linux-arm64
47+ zip -j gordon_${{ github.ref_name }}_windows_arm64.zip gordon-windows-arm64.exe
48+ zip -j gordon_${{ github.ref_name }}_darwin_arm64.zip gordon-darwin-arm64
29 49
30 - name: Install Cosign50 - name: Install Cosign
31 run: |51 run: |

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 7

Tags 106

↑↓ moveenter openesc close