Skip to content

Commit

Permalink
release source code with vendored dependencies
Browse files Browse the repository at this point in the history
Signed-off-by: Kristoffer Dalby <[email protected]>
  • Loading branch information
kradalby authored and juanfont committed Apr 20, 2023
1 parent 977eb1d commit e6b2649
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,6 @@ jobs:
- uses: cachix/install-nix-action@v16

- name: Run goreleaser
run: nix develop --command -- goreleaser release --rm-dist
run: nix develop --command -- goreleaser release --clean
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ ignored/
*.out

# Dependency directories (remove the comment below to include it)
# vendor/
vendor/

dist/
/headscale
Expand Down
8 changes: 8 additions & 0 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
before:
hooks:
- go mod tidy -compat=1.20
- go mod vendor

release:
prerelease: auto
Expand Down Expand Up @@ -44,6 +45,13 @@ archives:
name_template: "{{ .ProjectName }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}"
format: binary

source:
enabled: true
name_template: "{{ .ProjectName }}_{{ .Version }}"
format: tar.gz
files:
- "vendor/"

nfpms:
# Configure nFPM for .deb and .rpm releases
#
Expand Down

0 comments on commit e6b2649

Please sign in to comment.