Skip to content

Commit

Permalink
Update release_build.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
iletai authored Mar 22, 2024
1 parent 9153327 commit 39b7e23
Showing 1 changed file with 33 additions and 23 deletions.
56 changes: 33 additions & 23 deletions .github/workflows/release_build.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
---
name: Release Tag
on:
workflow_call:
Expand All @@ -9,26 +10,35 @@ on:
- master
jobs:
create_tag:
- uses: actions/checkout@v4

- name: Create tag
uses: actions/github-script@v5
with:
script: |
github.rest.git.createRef({
owner: context.repo.owner,
repo: context.repo.repo,
ref: 'refs/tags/${{ github.event.inputs.tagname }}',
sha: context.sha
})
- name: Build executable for release
run: swift build -c release --arch arm64 --arch x86_64 --product
SwiftUICalendarView
- name: Compress archive
run: tar -czf ${{ github.event.inputs.tagname }}.tar.gz -C
.build/apple/Products/Release SwiftUICalendarView
- name: Release
uses: softprops/action-gh-release@v2
with:
files: ${{ github.event.inputs.tagname }}.tar.gz
token: ${{ secrets.GH_TOKEN }}
name: Setup Tag
runs-on: ${{ matrix.os }}
strategy:
matrix:
os:
- macos-14
swift:
- "5.9"
steps:
- name: Checkout Repository
uses: actions/checkout@v4
- name: Create tag
uses: actions/github-script@v5
with:
script: |
github.rest.git.createRef({
owner: context.repo.owner,
repo: context.repo.repo,
ref: 'refs/tags/${{ github.event.inputs.tagname }}',
sha: context.sha
})
- name: Build executable for release
run: swift build -c release --arch arm64 --arch x86_64 --product
SwiftUICalendarView
- name: Compress archive
run: tar -czf ${{ github.event.inputs.tagname }}.tar.gz -C
.build/apple/Products/Release SwiftUICalendarView
- name: Release
uses: softprops/action-gh-release@v2
with:
files: ${{ github.event.inputs.tagname }}.tar.gz
token: ${{ secrets.GH_TOKEN }}

0 comments on commit 39b7e23

Please sign in to comment.