Skip to content

Commit

Permalink
get release with gh cli (#198)
Browse files Browse the repository at this point in the history
* check build status on main
* get release info with gh cli
  • Loading branch information
scareything authored Sep 8, 2023
1 parent 9c2e439 commit 2e858f2
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 6 deletions.
15 changes: 10 additions & 5 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,20 +13,23 @@ jobs:

- name: Get Release
id: get_release
uses: bruceadams/get-release@v1.3.2
run: |
url=$(gh release view --json url --jq .url)
echo "url=${url}" | tee -a $GITHUB_OUTPUT
tag_name=$(gh release view --json tagName --jq .tagName)
echo "tag_name=${tag_name}" | tee -a $GITHUB_OUTPUT
env:
GITHUB_TOKEN: ${{ github.token }}

- name: Download xcframework
run: curl ${{ github.server_url }}/${{ github.repository }}/releases/download/${{ steps.get_release.outputs.tag_name }}/CZiti.xcframework.zip -L -o CZiti.xcframework.zip
run: curl ${{ steps.get_release.outputs.url }}/CZiti.xcframework.zip -LO

- name: Compute Checksum
id: calc_checksum
run: |
# checksum=$(swift package compute-checksum ./CZiti.xcframework.zip)
checksum=$(shasum -a 256 ./CZiti.xcframework.zip | cut -d " " -f1)
echo "checksum: ${checksum}"
echo "checksum=${checksum}" >> $GITHUB_OUTPUT
echo "checksum=${checksum}" | tee -a $GITHUB_OUTPUT
- name: Checkout Distribution Project
uses: actions/checkout@v3
Expand Down Expand Up @@ -80,7 +83,9 @@ jobs:

- name: Get Release
id: get_release
uses: bruceadams/get-release@v1.3.2
run: |
tag_name=$(gh release view --json tagName --jq .tagName)
echo "tag_name=${tag_name}" | tee -a $GITHUB_OUTPUT
env:
GITHUB_TOKEN: ${{ github.token }}

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
![Ziggy using the ziti-sdk-swift](https://raw.githubusercontent.com/openziti/branding/main/images/banners/Swift.jpg)

# Ziti SDK for Swift
![Build Status](https://github.com/openziti/ziti-sdk-swift/workflows/CI/badge.svg?branch=master)
![Build Status](https://github.com/openziti/ziti-sdk-swift/workflows/CI/badge.svg?branch=main)

An SDK for accessing Ziti from macOS and iOS applications using the Swift programming language.

Expand Down

0 comments on commit 2e858f2

Please sign in to comment.