Skip to content

Commit

Permalink
fix outdated references to steps.bumpVersion.outputs.NEW_VERSION
Browse files Browse the repository at this point in the history
  • Loading branch information
roryabraham committed May 12, 2021
1 parent 8dfd03c commit e532838
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 8 deletions.
10 changes: 8 additions & 2 deletions .github/workflows/finishReleaseCycle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -77,15 +77,21 @@ jobs:
WORKFLOW: createNewVersion.yml
INPUTS: '{ "SEMVER_LEVEL": "BUILD" }'

- name: Pull main to get the new version
run: |
git pull origin main
echo "NEW_VERSION=$(npm run print-version --silent)" >> $GITHUB_ENV
echo "New version is ${{ env.NEW_VERSION }}"
# Note: we need to create this tag but not push it, because of how GitUtils.getPullRequestsMergedBetween works
- name: Tag version
run: git tag ${{ steps.bumpVersion.outputs.NEW_VERSION }}
run: git tag ${{ env.NEW_VERSION }}

- name: Create new StagingDeployCash
uses: Expensify/Expensify.cash/.github/actions/createOrUpdateStagingDeploy@main
with:
GITHUB_TOKEN: ${{ secrets.OS_BOTIFY_TOKEN }}
NPM_VERSION: ${{ steps.bumpVersion.outputs.NEW_VERSION }}
NPM_VERSION: ${{ env.NEW_VERSION }}

# This Slack step is duplicated in all workflows, if you make a change to this step, make sure to update all
# the other workflows with the same change
Expand Down
10 changes: 8 additions & 2 deletions .github/workflows/lockDeploys.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,15 +36,21 @@ jobs:
WORKFLOW: updateProtectedBranch.yml
INPUTS: '{ "TARGET_BRANCH": "staging" }'

- name: Pull staging to get the new version
run: |
git pull origin staging
echo "NEW_VERSION=$(npm run print-version --silent)" >> $GITHUB_ENV
echo "New version is ${{ env.NEW_VERSION }}"
# Note: we need to create this tag but not push it, because of how GitUtils.getPullRequestsMergedBetween works
- name: Tag version
run: git tag ${{ steps.bumpVersion.outputs.NEW_VERSION }}
run: git tag ${{ env.NEW_VERSION }}

- name: Update StagingDeployCash
uses: Expensify/Expensify.cash/.github/actions/createOrUpdateStagingDeploy@main
with:
GITHUB_TOKEN: ${{ secrets.OS_BOTIFY_TOKEN }}
NPM_VERSION: ${{ steps.bumpVersion.outputs.NEW_VERSION }}
NPM_VERSION: ${{ env.NEW_VERSION }}

# This Slack step is duplicated in all workflows, if you make a change to this step, make sure to update all
# the other workflows with the same change
Expand Down
12 changes: 8 additions & 4 deletions .github/workflows/preDeploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,6 @@ jobs:
runs-on: macos-latest
needs: chooseDeployActions
if: ${{ needs.chooseDeployActions.outputs.isStagingDeployLocked == 'false' && needs.chooseDeployActions.outputs.isVersionBumpPR == 'false' }}
outputs:
newVersion: ${{ steps.bumpVersion.outputs.NEW_VERSION }}

steps:
# Version: 2.3.4
Expand Down Expand Up @@ -83,15 +81,21 @@ jobs:
WORKFLOW: updateProtectedBranch.yml
INPUTS: '{ "TARGET_BRANCH": "staging" }'

- name: Pull main to get the new version
run: |
git pull origin main
echo "NEW_VERSION=$(npm run print-version --silent)" >> $GITHUB_ENV
echo "New version is ${{ env.NEW_VERSION }}"
# Note: we need to create this tag but not push it, because of how GitUtils.getPullRequestsMergedBetween works
- name: Tag version
run: git tag ${{ steps.bumpVersion.outputs.NEW_VERSION }}
run: git tag ${{ env.NEW_VERSION }}

- name: Update StagingDeployCash
uses: Expensify/Expensify.cash/.github/actions/createOrUpdateStagingDeploy@main
with:
GITHUB_TOKEN: ${{ secrets.OS_BOTIFY_TOKEN }}
NPM_VERSION: ${{ steps.bumpVersion.outputs.NEW_VERSION }}
NPM_VERSION: ${{ env.NEW_VERSION }}
NEW_PULL_REQUESTS: https://github.com/Expensify/Expensify.cash/pull/${{ needs.chooseDeployActions.outputs.mergedPullRequest }}

# This Slack step is duplicated in all workflows, if you make a change to this step, make sure to update all
Expand Down

0 comments on commit e532838

Please sign in to comment.