Skip to content

Commit

Permalink
codeql: Only purge python cache if CODEQL_PYTHON is set
Browse files Browse the repository at this point in the history
  • Loading branch information
jvesely committed Jan 25, 2024
1 parent 3380105 commit aa8a951
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,11 @@ jobs:
- name: Autobuild
uses: github/codeql-action/autobuild@v3

- name: Cache cleanup
- name: Pip cache cleanup
shell: bash
# CODEQL_PYTHON is only defined if dependencies were installed [0]
# [0] https://docs.github.com/en/code-security/code-scanning/creating-an-advanced-setup-for-code-scanning/customizing-your-advanced-setup-for-code-scanning?learn=code_security_actions&learnProduct=code-security#analyzing-python-dependencies
if: ${{ env.CODEQL_PYTHON != '' }}
run: |
$CODEQL_PYTHON -m pip cache info
$CODEQL_PYTHON -m pip cache purge
Expand Down

0 comments on commit aa8a951

Please sign in to comment.