Skip to content

Commit

Permalink
Merge pull request #95 from acsone/fix-precommit-gitlab-ci-ape
Browse files Browse the repository at this point in the history
Issue with gitlab-ci cache. Update according precommit docs.
  • Loading branch information
sbidoul authored Jan 25, 2023
2 parents 4f19e51 + a840d4d commit 05b54d2
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions acsoo/templates/project/+project.name+/.gitlab-ci.yml.bob
Original file line number Diff line number Diff line change
Expand Up @@ -22,13 +22,15 @@ variables:
pre-commit:
stage: test
image: python:{{{ project.python_version }}}
variables:
PRE_COMMIT_HOME: ${CI_PROJECT_DIR}/.cache/pre-commit
cache:
key: pre-commit
paths:
- .pre-commit
- ${PRE_COMMIT_HOME}
script:
- pip install pre-commit
- PRE_COMMIT_HOME=$PWD/.pre-commit pre-commit run --all-files --show-diff-on-failure
- pre-commit run --all-files --show-diff-on-failure
needs: []
interruptible: true

Expand Down

0 comments on commit 05b54d2

Please sign in to comment.