tmp #2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: PR Command | |
concurrency: | |
group: ci-${{ github.run_id }} | |
cancel-in-progress: true | |
on: | |
issue_comment: | |
types: [created] | |
jobs: | |
build-and-test: | |
runs-on: ubuntu-latest | |
if: ${{ github.event.issue.pull_request && startsWith(github.event.comment.body, '/build_test') }} | |
steps: | |
- name: Command handler for building and testing | |
id: command | |
uses: xt0rted/slash-command-action@v1 | |
with: | |
repo-token: ${{ secrets.GITHUB_TOKEN }} | |
command: build_test | |
reaction: "true" | |
reaction-type: "+1" | |
allow-edits: "false" | |
permission-level: write | |
- name: Build preview image | |
id: build-image | |
run: echo "tag=quay.io/macao/demo:latest" >> $GITHUB_OUTPUT | |
- name: Print the preview image | |
uses: thollander/actions-comment-pull-request@v1 | |
with: | |
message: |- | |
Preview image available: | |
``` | |
${{ steps.build-image.outputs.tag }} | |
``` | |
- name: Run tests | |
run: echo "Running tests" |