For prereleases, we want to be able to push updates to either staging (for rc's) or a protonova build (for qa releases). We don't want to go through the hassle of PR's for those, so this PR opens the interface of the action to allow it specify a change-method and branch-name. If change-method is set to merge, then the changes will be merged directly into the branch that is set by branch-name.
An example usage might look like this:
name: Publish
jobs:
publish-to-npm: ...
auto-deploy-prerelease:
needs: publish-to-npm
runs-on: ubuntu-latest
steps:
- name: Build branch name (staging if rc, use PR number and library name if qa)
run: |
tag_name=${{ github.event.release.tag_name }}
if [[ $VERSION =~ -rc\. ]]; then
echo "branch_name=staging" >> $GITHUB_ENV
else
[[ $tag_name =~ -qa-([0-9]+)\. ]]
branch_name="proto/my-library-${BASH_REMATCH[1]}"
echo "branch_name=$branch_name" >> $GITHUB_ENV
fi
- uses: planningcenter/pco-release-action/deploy@v1
if: 'github.event.release.prerelease'
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
change-method: 'merge'
branch-name: ${{ env.branch_name }}
To see the specific tasks where the Asana app for GitHub is being used, see below:
For prereleases, we want to be able to push updates to either
staging
(for rc's) or a protonova build (for qa releases). We don't want to go through the hassle of PR's for those, so this PR opens the interface of the action to allow it specify achange-method
andbranch-name
. Ifchange-method
is set tomerge
, then the changes will be merged directly into the branch that is set bybranch-name
.An example usage might look like this: