Skip to content

Commit

Permalink
refactor: extract build to makefile
Browse files Browse the repository at this point in the history
  • Loading branch information
natesales committed Jul 5, 2022
1 parent 53caacd commit 2d93f6d
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
3 changes: 1 addition & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,7 @@ jobs:
- run: make
- name: Replace version with tag
run: sed -i "s/v0.0.0/${{ github.event.release.tag_name }}/g" nfpm.yml
- name: Create deb
run: nfpm package --packager deb --config nfpm.yml
- run: make release
- name: Release
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
Expand Down
6 changes: 5 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ all: dep coraza build coraza-conf

dep:
go install github.com/caddyserver/xcaddy/cmd/xcaddy@latest
go install github.com/goreleaser/nfpm/v2/cmd/nfpm@latest

coraza:
rm -rf coraza
Expand All @@ -21,4 +22,7 @@ build:
bash build.sh

clean:
rm -rf coraza* coreruleset*
rm -rf coraza* coreruleset*

release:
nfpm package --packager deb --config nfpm.yml

0 comments on commit 2d93f6d

Please sign in to comment.