Skip to content

Commit

Permalink
Remove updateProtectedBranch from preDeploy
Browse files Browse the repository at this point in the history
  • Loading branch information
roryabraham committed Jun 15, 2023
1 parent e7d7730 commit b0e9828
Showing 1 changed file with 14 additions and 11 deletions.
25 changes: 14 additions & 11 deletions .github/workflows/preDeploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -88,14 +88,23 @@ jobs:
env:
GITHUB_TOKEN: ${{ github.token }}

- name: Update staging branch from main
if: ${{ !fromJSON(needs.chooseDeployActions.outputs.SHOULD_CP) }}
uses: Expensify/App/.github/actions/composite/updateProtectedBranch@main
- uses: actions/checkout@v3
with:
ref: main
token: ${{ secrets.OS_BOTIFY_TOKEN }}

- uses: Expensify/App/.github/actions/composite/setupGitForOSBotify@main
with:
TARGET_BRANCH: staging
OS_BOTIFY_TOKEN: ${{ secrets.OS_BOTIFY_TOKEN }}
GPG_PASSPHRASE: ${{ secrets.LARGE_SECRET_PASSPHRASE }}

- name: Update staging branch from main
run: |
git switch staging
git switch main
git branch -D staging
git switch -c staging
git push --force origin staging
- name: Cherry-pick PR to staging
if: ${{ fromJSON(needs.chooseDeployActions.outputs.SHOULD_CP) }}
uses: Expensify/App/.github/actions/javascript/triggerWorkflowAndWait@main
Expand All @@ -104,12 +113,6 @@ jobs:
WORKFLOW: cherryPick.yml
INPUTS: '{ "PULL_REQUEST_NUMBER": "${{ needs.chooseDeployActions.outputs.MERGED_PR }}", "NEW_VERSION": "${{ needs.createNewVersion.outputs.NEW_VERSION }}" }'

# Version: 3.0.2
- uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8
with:
ref: staging
fetch-depth: 0

# Create a local git tag on staging so that GitUtils.getPullRequestsMergedBetween can use `git log` to generate a
# list of pull requests that were merged between this version tag and another.
# NOTE: This tag is only used locally and shouldn't be pushed to the remote.
Expand Down

0 comments on commit b0e9828

Please sign in to comment.