Skip to content

Commit

Permalink
ci: enable release artifacts for windows, macos
Browse files Browse the repository at this point in the history
  • Loading branch information
cilki committed May 17, 2024
1 parent 8b9e823 commit 04a9a0f
Showing 1 changed file with 31 additions and 0 deletions.
31 changes: 31 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,8 @@ jobs:
target: ${{ matrix.target }}

- uses: actions/checkout@v4
with:
fetch-tags: true

- uses: actions-rs/cargo@v1
with:
Expand Down Expand Up @@ -91,6 +93,7 @@ jobs:
run: |
export RUST_BACKTRACE=1
export RUST_LOG=debug
chmod +x linux-amd64/goldboot
linux-amd64/goldboot init --mold Goldboot
linux-amd64/goldboot cast --output goldboot-linux-x86_64.gb .
Expand All @@ -109,6 +112,8 @@ jobs:
override: true

- uses: actions/checkout@v4
with:
fetch-tags: true

- uses: actions-rs/cargo@v1
with:
Expand All @@ -120,6 +125,17 @@ jobs:
name: goldboot-x86_64-apple-darwin
path: target/release/goldboot

- name: Upload artifacts to release
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GH_REPO: ${{ github.repository }}
run: |
for tag in $(git tag --points-at HEAD); do
if cp target/release/${tag%-*} ${tag%-*}_x86_64-apple-darwin; then
gh release upload "${tag}" "${tag%-*}_x86_64-apple-darwin"
fi
done
windows:
runs-on: windows-latest
needs: github
Expand All @@ -130,6 +146,8 @@ jobs:
override: true

- uses: actions/checkout@v4
with:
fetch-tags: true

- uses: actions-rs/cargo@v1
with:
Expand All @@ -141,11 +159,24 @@ jobs:
name: goldboot-x86_64-pc-windows-msvc
path: target/release/goldboot

- name: Upload artifacts to release
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GH_REPO: ${{ github.repository }}
run: |
for tag in $(git tag --points-at HEAD); do
if cp target/release/${tag%-*} ${tag%-*}_x86_64-pc-windows-msvc; then
gh release upload "${tag}" "${tag%-*}_x86_64-pc-windows-msvc"
fi
done
docker:
runs-on: ubuntu-latest
needs: linux
steps:
- uses: actions/checkout@v4
with:
fetch-tags: true

- uses: docker/setup-qemu-action@v3

Expand Down

0 comments on commit 04a9a0f

Please sign in to comment.