File: pre-commit.sh

package info (click to toggle)
python-nxtomomill 1.1.0-4
  • links: PTS, VCS
  • area: main
  • in suites: sid, trixie
  • size: 2,564 kB
  • sloc: python: 15,970; makefile: 13; sh: 3
file content (10 lines) | stat: -rwxr-xr-x 362 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
#!/bin/bash
# This script installs a pre-commit hook on the local repository
# It allows black to run before any git commit.

# Install pre-commit, with a local install fallback
pip install --quiet --upgrade pre-commit 2>/dev/null \
    || pip install --quiet --user --upgrade pre-commit

# Install the pre-commit hook on the local repository
pre-commit install