Files
starter-workflows/code-scanning/pmd.yml
T

37 lines
974 B
YAML
Raw Normal View History

2021-10-27 15:35:18 -04:00
# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.
name: pmd
on:
push:
branches: [ $default-branch, $protected-branches ]
pull_request:
branches: [ $default-branch ]
schedule:
- cron: $cron-weekly
jobs:
2021-12-01 15:50:22 -05:00
pmd-code-scan:
2021-10-27 15:35:18 -04:00
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
2021-12-01 15:50:22 -05:00
- name: Set up JDK 11
uses: actions/setup-java@v2
2021-10-27 15:35:18 -04:00
with:
2021-12-01 15:50:22 -05:00
java-version: '11'
distribution: 'adopt'
cache: maven
- name: Run PMD
id: pmd
2021-12-03 10:33:18 -05:00
uses: pmd/pmd-github-action@7ed79622882840855e297f090460face22328ece
2021-10-27 15:35:18 -04:00
with:
2021-12-01 15:50:22 -05:00
rulesets: 'rulesets/java/quickstart.xml'
sourcePath: 'src/main/java'
- name: Upload SARIF file
2021-10-27 15:35:18 -04:00
uses: github/codeql-action/upload-sarif@v1
with:
2021-12-01 15:50:22 -05:00
sarif_file: pmd-report.sarif