name: branch-deploy on: issue_comment: types: [created] permissions: write-all jobs: rubocop: name: runner / rspec runs-on: ubuntu-latest steps: - name: branch-deploy id: branch-deploy uses: GrantBirki/branch-deploy@333ba95ed89be2efe1cd49dc2781c8556a742eba # pin@v1.3.0 # Check out the ref from the output of the IssueOps command - uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # pin@v3.0.2 with: ref: ${{ steps.branch-deploy.outputs.ref }} - uses: ruby/setup-ruby@cd4241788aec4fdcd3325da7068efa9b62a017af with: ruby-version: 2.7.5 bundler-cache: true - name: bootstrap run: script/bootstrap # Here we run a deploy. It is "gated" by the IssueOps logic and will only run if the outputs from our branch-deploy step indicate that the workflow should continue - name: deploy if: ${{ steps.branch-deploy.outputs.continue == 'true' && steps.branch-deploy.outputs.noop != 'true' }} run: | set -o pipefail script/deploy | tee deploy.out MSG=$(cat deploy.out) MSG="\`\`\`output\n${MSG}\n\`\`\`" echo 'DEPLOY_MESSAGE<> $GITHUB_ENV echo "$MSG" >> $GITHUB_ENV echo 'EOF' >> $GITHUB_ENV