You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, I'm struggling a bit to get this working on changed files only (to keep it fast). My action looks like this:
name: reviewdogon: [pull_request]jobs:
reviewdog:
name: runnerruns-on: ubuntu-latestpermissions:
contents: readpull-requests: writesteps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v4with:
version: 9run_install: false
- name: Install Node.jsuses: actions/setup-node@v4with:
node-version: 20cache: 'pnpm'
- name: Install dependenciesrun: pnpm install
- id: filesuses: Ana06/get-changed-files@v2.3.0
- name: Get changed JS filesrun: | matching_files=() for changed_file in ${{ steps.files.outputs.added_modified }}; do if [[ "$changed_file" =~ \.(js|jsx|ts|tsx)$ ]]; then matching_files+=("$changed_file") fi done # Set env var to be used in next step echo "CHANGED_JS_FILES=${matching_files[@]}" >> $GITHUB_ENV
- run: | # If I run this line, it does show the eslint errors I expect # npx --no-install -c "eslint ${{ env.CHANGED_JS_FILES }}"
- uses: reviewdog/action-eslint@v1with:
github_token: ${{ secrets.GITHUB_TOKEN }}reporter: github-pr-reviewlevel: erroreslint_flags: "${{ env.CHANGED_JS_FILES }}"
As mentioned in the code above, if I uncomment the step that does: npx --no-install -c "eslint ${{ env.CHANGED_JS_FILES }}" it correctly shows eslint errors in stdout, but when running through the next step, it provides no output, no errors and there are no review comments.
I know it's not a permissions issue, since I have another action for reviewdog-shellcheck using the same token, and that one works perfectly fine.
Any clue what I'm doing wrong here?
The text was updated successfully, but these errors were encountered:
Hi, I'm struggling a bit to get this working on changed files only (to keep it fast). My action looks like this:
As mentioned in the code above, if I uncomment the step that does:
npx --no-install -c "eslint ${{ env.CHANGED_JS_FILES }}"
it correctly shows eslint errors in stdout, but when running through the next step, it provides no output, no errors and there are no review comments.I know it's not a permissions issue, since I have another action for reviewdog-shellcheck using the same token, and that one works perfectly fine.
Any clue what I'm doing wrong here?
The text was updated successfully, but these errors were encountered: