Skip to content

feat: Github Action to enable Checkstyle #22

feat: Github Action to enable Checkstyle

feat: Github Action to enable Checkstyle #22

name: reviewdog
on:
pull_request:
types:
- opened
- synchronize
jobs:
greeting:
runs-on: ubuntu-latest
permissions:
issues: write
pull-requests: write
steps:
- uses: actions/first-interaction@v1
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
issue-message: "Thank you for contribute by creating an issue"
pr-message: "Thank you for contribute with your first pull request"
checkstyle:
name: runner / checkstyle
runs-on: ubuntu-latest
permissions:
contents: write
pull-requests: write
checks: write
steps:
- uses: actions/checkout@v4
- name: Run Checkstyle
run: |
wget -O checkstyle.jar https://github.com/checkstyle/checkstyle/releases/download/checkstyle-8.41/checkstyle-8.41-all.jar
java -jar checkstyle.jar -c /google_checks.xml src/
- name: Debug Info
run:
echo "Permissions: ${{ toJson(github.event) }}"

Check failure on line 34 in .github/workflows/checkstyle_review.yml

View workflow run for this annotation

GitHub Actions / reviewdog

Invalid workflow file

The workflow is not valid. .github/workflows/checkstyle_review.yml (Line: 34, Col: 11): A mapping was not expected
- name: reviewdog
uses: reviewdog/action-checkstyle@v1
env:
REVIEWDOG_GITHUB_API_TOKEN: ${{ secrets.CHECSTYLE_TOKEN }}
with:
github_token: ${{ secrets.CHECSTYLE_TOKEN }}
reporter: github-pr-review
checkstyle_config: google_checks.xml
fail_on_error: true