-
-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Do not fail on every non-slash command #124
Comments
Hi @MOZGIII thanks for bringing this up. It's missing from the sample in the readme, but there's a setting you can add to job steps called You can use this along with an if condition on the remaining steps so they only run when the command is provided. It would look something like this: jobs:
check_comments:
name: Check comments for /lint
steps:
- uses: xt0rted/slash-command-action@v1
id: command
continue-on-error: true
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
command: lint
- run: echo "Runs on all /lint commands"
if: steps.command.outputs.command-name
- run: echo "Runs only on /lint js command"
if: steps.command.outputs.command-name && steps.command.outputs.command-arguments == 'js'
- run: echo "Runs only on /lint css command"
if: steps.command.outputs.command-name && steps.command.outputs.command-arguments == 'css'
- run: echo "This step always runs" Making the change you proposed in #123 will remove the need for |
This #123 is unrelated, and it just fixes a bug. |
|
Can you add this to the README? I believe most users will want this. |
There is a problem with slash-command-action which is on absence of a slash command the job fails (instead of simply ignore, i.e., skip). This is documented on xt0rted/slash-command-action#124. There is a workaround also documented on that issue, but here instead let's get rid of the action. In this new implementation all comments sent to the pull request are parsed, if any starts with "/test_kata-deploy" then the job is triggered. Signed-off-by: Wainer dos Santos Moschetta <wainersm@redhat.com>
There is a problem with slash-command-action which is on absence of a slash command the job fails (instead of simply ignore, i.e., skip). This is documented on xt0rted/slash-command-action#124. There is a workaround also documented on that issue, but here instead let's get rid of the action. In this new implementation all comments sent to the pull request are parsed, if any starts with "/test_kata-deploy" then the job is triggered. Fixes kata-containers#2836 Signed-off-by: Wainer dos Santos Moschetta <wainersm@redhat.com>
Currently, the task fails for every non-slash command, making the regular discussions on the PR impossible due to email spam from Github Actions.
Can we figure out a workaround for it?
The text was updated successfully, but these errors were encountered: