jupyter-packaging icon indicating copy to clipboard operation
jupyter-packaging copied to clipboard

Add optional pre-commit install step

Open blink1073 opened this issue 2 years ago • 0 comments

As we're switching more libraries to use pre-commit, it would be handy to have an option install pre-commit on editable installs. This should be a config option like:

[tool.jupyter-packaging]
install-pre-commit = True

That runs the following after the setuptools build_editable hook:

subprocess.run([sys.executable, '-m', 'pre_commit', 'install'])

We'd need to add a dependency on pre_commit, which is already on conda-forge.

This depends on #103

blink1073 avatar Mar 27 '22 20:03 blink1073