Skip to content

Commit e794099

Browse files
committed
workflows: add tics into the linter for quality gating
TICS allows us to track the quality of our project. `client` mode can be used to gate the PRs if they are under certain threshold. Signed-off-by: Talha Can Havadar <talha.can.havadar@canonical.com>
1 parent 4e98482 commit e794099

1 file changed

Lines changed: 23 additions & 0 deletions

File tree

.github/workflows/linter.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -169,3 +169,26 @@ jobs:
169169
echo "::group::unit test results"
170170
cargo test --bins
171171
echo "::endgroup::"
172+
tics:
173+
runs-on: ubuntu-latest
174+
env:
175+
TICS_CHANGED_LIST: tics_changed.list
176+
GH_TOKEN: ${{ github.token }}
177+
steps:
178+
- uses: actions/checkout@v4
179+
with:
180+
fetch-depth: 0
181+
- name: Get PR files
182+
env:
183+
PR_NUMBER: ${{ github.event.number }}
184+
run: |
185+
gh pr diff "$PR_NUMBER" --name-only >> "$TICS_CHANGED_LIST"
186+
- name: Run TICS analysis
187+
uses: tiobe/tics-github-action@v3.4.0
188+
with:
189+
mode: client
190+
project: fpgad
191+
viewerUrl: https://canonical.tiobe.com/tiobeweb/TICS/api/cfg?name=default
192+
ticsAuthToken: ${{ secrets.TICSAUTHTOKEN }}
193+
installTics: true
194+
filelist: ${{ env.TICS_CHANGED_LIST }}

0 commit comments

Comments
 (0)