Skip to content

Commit

Permalink
Use outputs
Browse files Browse the repository at this point in the history
  • Loading branch information
EmilKWarmdahl committed Nov 19, 2024
1 parent 1821f80 commit 8955143
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ permissions:
jobs:
rosetta-version:
runs-on: ubuntu-latest
outputs:
OUTFILE_SHORT: ${{steps.version.outputs.outfile}}
steps:
- name: Checkout Repository
uses: actions/checkout@v4
Expand All @@ -27,18 +29,21 @@ jobs:
submodules: recursive

- name: Get the rosetta version
id: version
run: |
CARGO_VERSION=$(yq .package.version "Cargo.toml")
if [ ! "1.2.0" = "$CARGO_VERSION" ] ; then
echo "::error::$CARGO_VERSION does not match ${{ github.ref_name }}."
exit 1
fi
echo "OUTFILE_SHORT=${{ env.OUTFOLDER }}/windows/concordium-rosetta-$CARGO_VERSION" >> $GITHUB_ENV
echo "outfile=${{ env.OUTFOLDER }}/windows/concordium-rosetta-$CARGO_VERSION" >> $GITHUB_OUTPUT
release-rosetta-macos:
needs: rosetta-version
runs-on: macos-latest
environment: release
env:
OUTFILE: ${{needs.rosetta-version.outputs.OUTFILE_SHORT}}
steps:
- name: Checkout Repository
uses: actions/checkout@v4
Expand All @@ -53,9 +58,6 @@ jobs:
role-to-assume: ${{ env.IAM_ROLE }}
role-session-name: ReleaseRosettaSession

- name: Get the rosetta version
run: |
echo "OUTFILE=${{ env.OUTFILE_SHORT }}" >> $GITHUB_ENV

- name: Check if version exist in s3
run: |
Expand Down Expand Up @@ -83,6 +85,8 @@ jobs:
runs-on: windows-latest
needs: rosetta-version
environment: release
env:
OUTFILE: ${{needs.rosetta-version.outputs.OUTFILE_SHORT}}
steps:
- name: Checkout Repository
uses: actions/checkout@v4
Expand All @@ -97,10 +101,6 @@ jobs:
role-to-assume: ${{ env.IAM_ROLE }}
role-session-name: ReleaseRosettaSession

- name: Get the rosetta version
run: |
CARGO_VERSION=$(yq .package.version "Cargo.toml")
echo "OUTFILE=${{ env.OUTFILE_SHORT }}.exe" >> $GITHUB_ENV

- name: Check if version exist in s3
run: |
Expand Down

0 comments on commit 8955143

Please sign in to comment.