Skip to content

Commit

Permalink
Fix
Browse files Browse the repository at this point in the history
  • Loading branch information
k1LoW committed Jan 25, 2024
1 parent 11e309d commit a879b22
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 14 deletions.
32 changes: 21 additions & 11 deletions .github/workflows/tagpr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,16 @@ jobs:
with:
distribution: goreleaser
version: latest
args: --config .goreleaser/darwin.yml --clean
args: --config .goreleaser/darwin.yml --clean --skip=publish
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Upload assets
run: |
gh release upload ${{ needs.tagpr.outputs.tagpr-tag }} dist/tbls_${{ needs.tagpr.outputs.tagpr-tag }}_darwin_arm64.zip dist/tbls_${{ needs.tagpr.outputs.tagpr-tag }}_darwin_amd64.zip dist/checksums-darwin.txt --repo ${{ github.repository }} --clobber
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

linux-assets:
needs: tagpr
if: needs.tagpr.outputs.tagpr-tag != ''
Expand Down Expand Up @@ -82,12 +88,12 @@ jobs:
docker compose up -d
sleep 20s
- name: Run GoReleaser (dry-run)
- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v5
with:
distribution: goreleaser
version: latest
args: --config .goreleaser/linux.yml --clean --snapshot --skip=publish
args: --config .goreleaser/linux.yml --clean --skip=publish
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

Expand All @@ -96,14 +102,11 @@ jobs:
env TBLS=dist/tbls-linux_linux_amd64_v1/tbls make depsdev db doc
git restore .
- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v5
with:
distribution: goreleaser
version: latest
args: --config .goreleaser/linux.yml --clean
- name: Upload assets
run: |
gh release upload ${{ needs.tagpr.outputs.tagpr-tag }} dist/tbls_${{ needs.tagpr.outputs.tagpr-tag }}_linux_arm64.tar.gz dist/tbls_${{ needs.tagpr.outputs.tagpr-tag }}_linux_amd64.tar.gz dist/checksums-linux.txt --repo ${{ github.repository }} --clobber
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

windows-assets:
needs: tagpr
Expand Down Expand Up @@ -141,10 +144,16 @@ jobs:
with:
distribution: goreleaser
version: latest
args: --config .goreleaser/windows.yml --clean
args: --config .goreleaser/windows.yml --clean --skip=publish
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Upload assets
run: |
gh release upload ${{ needs.tagpr.outputs.tagpr-tag }} dist/tbls_${{ needs.tagpr.outputs.tagpr-tag }}_windows_amd64.zip dist/checksums-windows.txt --repo ${{ github.repository }} --clobber
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

dockerimage:
needs: tagpr
if: needs.tagpr.outputs.tagpr-tag != ''
Expand Down Expand Up @@ -200,6 +209,7 @@ jobs:
org.opencontainers.image.revision=${{ github.sha }}
org.opencontainers.image.version=${{ steps.latest_version.outputs.version }}
org.opencontainers.image.source=https://github.com/k1LoW/tbls
release:
needs: [tagpr, darwin-assets, linux-assets, windows-assets, dockerimage]
runs-on: ubuntu-latest
Expand Down
2 changes: 1 addition & 1 deletion .goreleaser/darwin.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,4 +39,4 @@ changelog:
- '^test:'
release:
draft: true
replace_existing_draft: true
skip_upload: true
2 changes: 1 addition & 1 deletion .goreleaser/linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,4 +66,4 @@ nfpms:
epoch: 1
release:
draft: true
replace_existing_draft: true
skip_upload: true
2 changes: 1 addition & 1 deletion .goreleaser/windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,4 +45,4 @@ changelog:
- '^test:'
release:
draft: true
replace_existing_draft: true
skip_upload: true

0 comments on commit a879b22

Please sign in to comment.