Any #git #precommit experts here? I'm on a team where we use #pre-commit hooks for some checks. The `.pre-commit-config.yml` is part of the repo. However, I would like to add some local (to my machine) pre-commit hooks (`darker`) that other developers in the team don't want to have as part of there default setup.
Can I specify an additional configuration file that I don't commit to the repo (or somehow use an environment variable) to specify local pre-commit hooks?
Another blog post written (primarily for work) on using R and precommit
ce vendredi 30 juin 2023 au #BreizhCamp à #Rennes, je parlerai d'une façon d'outiller la qualité de code avec #precommit, un outil qui permet de lancer vos formateurs de code, linter, générateur de documentation, etc. sur le cycle de vie #git de vos projets.
Du commit à la production en passant par l'intégration continue, maintenez vos exigences de qualité de code, qu'elles soient définies en solo ou en équipe.
Diaporama source et pdf disponibles sur https://github.com/lucsorel/hook-il-est-beau-notre-code.
#breizhcamp #rennes #precommit #git
If your #git #repository runs #automatedTests or #linters #precommit or #prepush I WILL --no-verify that shit *everytime*
#software #programming #huskey #husky #github #commit #webdev #softwaredevelopment #testing
#testing #softwaredevelopment #webdev #commit #github #husky #huskey #programming #software #prepush #precommit #linters #automatedtests #repository #git
📢 Announcing v3.0.0 of our #github reusable #workflows
https://github.com/coatl-dev/workflows/tree/v3.0.0
#github #black #flake8 #pylint #mypy #python2 #python #nox #tox #precommit
#github #workflows #black #flake8 #pylint #mypy #python2 #python #nox #tox #precommit
We have just released version 2.3.0 of our #github reusable workflows.
Check 'em out here:
https://github.com/coatl-dev/workflows/tree/v2.3.0
#github #ci #workflows #python #nox #tox #precommit #pypi #mypy
#github #ci #workflows #python #nox #tox #precommit #pypi #mypy
🤔 Is it common for projects that use pre-commit.com not to tell people how to use it?
👉 Let me rephrase that. It is common for projects that use pre-commit.com not to tell people how to use it.
🙋 Has anyone seen a good project that explained how to use pre-commit with it that you like?
✍️ New post covering ways to skip #Git hooks:
1. --no-verify where supported
2. hook managers like #precommit which support SKIP or similar environment variable
3. core.hooksPath=/dev/null to bypass all hooks
✍️ New post on using pre-commit to run otherwise unsupported tools, with examples using 'node' and 'system'.
https://adamj.eu/tech/2023/02/09/pre-commit-hooks-unsupported-tools/
I think would helpful to have _a_ (not necessarily my) #chktex #precommit hook listed under https://pre-commit.com/hooks.html . This is where I searched for available hooks and only found the `pre-commit-latex-hook` repo, which is cool but not what I was looking for. 3/3
#TeXLaTeX
I was surprised I couldn't find [*] a #precommit hook to run the #ChkTeX #LaTeX #linter via the pre-commit framework (https://pre-commit.com) for #git . It was trivial to create a new pre-commit configuration that simply runs chktex, I published a WIP repo under: https://github.com/meliache/pre-commit-chktex .
I contains two hooks: chktex-system, which uses the system executable and chktex-conda, which installs chktex via #conda. Still I think probably this already exists somewhere and I just missed it. 1/N
#precommit #chktex #latex #linter #git #conda
New blog post on managing execute permissions in #git , including a #precommit hook for checking executable scripts.
https://adamj.eu/tech/2023/01/31/git-add-remove-execute-permissions/
#isort failing on #CI in #precommit in with this?
[extras.pipfile_deprecated_finder.2] 'pip-shims<=0.3.4' does not match '^[a-zA-Z-_.0-9]+$'
It's fixed in https://github.com/PyCQA/isort/pull/2078, bump your isort to 5.12.0.
Update with:
pre-commit autoupdate
Or:
pre-commit autoupdate --repo https://github.com/PyCQA/isort
So…who do we know at the #PyCQA that can rush a PR approval on a Saturday? I’m betting a lot of people have a broken #isort #precommit plugin right now.
https://github.com/PyCQA/isort/issues/2077
https://github.com/PyCQA/isort/pull/2078
Let's start the heated discussion:
either:
Build an application binary as part of #cicd and push it during the job back into the #git repository
OR
Build the application binary before committing via git hooks, #precommit, #Makefile, others...
#cicd #git #precommit #makefile
lors du dernier #PythonRennes, Jérôme Marchand et moi avons parlé d'outillage de la qualité de code, du commit à la production avec #precommit : des hooks #git à l'infrastructure as code #IaC en passant par #integrationContinue, la bibliothèque @pre_commit peut outiller la qualité de code des projets dans une multitude de langages : #python #java #javascript #go #rust #php etc.
- rediffusion de l'intervention : https://youtu.be/QoMOZuegwUY
- support de présentation : https://github.com/lucsorel/hook-il-est-beau-notre-code/blob/main/2022.11.07-hook_il_est_beau_notre_code.pdf
#PHP #Rust #Go #JavaScript #Java #Python #integrationcontinue #iac #git #precommit #pythonrennes
lors du dernier #PythonRennes, Jérôme Marchand et moi avons parlé d'outillage de la qualité de code, du commit à la production avec #precommit : des hooks #git à l'infrastructure as code #IaC en passant par #integrationContinue, la bibliothèque @pre_commit peut outiller la qualité de code des projets dans une multitude de langages : #python #java #javascript #go #rust #php etc.
- rediffusion de l'intervention : https://youtu.be/QoMOZuegwUY
- support de présentation : https://github.com/lucsorel/hook-il-est-beau-notre-code/blob/main/2022.11.07-hook_il_est_beau_notre_code.pdf
#pythonrennes #precommit #git #iac #integrationcontinue #python #java #javascript #go #rust #php
Dunno if the 2 hrs I just spent figuring out how to write a git #precommit hook and relearning #regularexpressions will ever repay itself in time but just knowing that I'll never commit a .m file with a comment starting with a hashtag (valid in #octave , not in #matlab ) makes my soul happy.
#precommit #regularexpressions #octave #matlab