Commit Graph

110 Commits

Author SHA1 Message Date
Anthony Sottile
53643def07 remove unused --config options from commands which don't use it 2022-06-22 16:06:15 -07:00
Matt Whitaker
702ebf402c Expose prepare-commit-msg arguments as environment vars 2022-06-11 14:25:55 -04:00
Anthony Sottile
777ffdd692 deprecate pre-commit-validate-{config,manifest} 2022-04-24 19:08:47 -04:00
Anthony Sottile
fd0177ae3a implement default_install_hook_types
this implements a configurable fallback for the default value of `pre-commit install`
2022-04-02 15:11:31 -04:00
Anthony Sottile
525191f34b update master to main 2022-03-24 13:52:25 -04:00
Lee Trout
e58bcb51fc Fix typo in help docs for to-ref and from-ref 2022-03-02 17:33:11 -05:00
Anthony Sottile
04de6a2e57 drop python 3.6 support
python 3.6 reached end of life on 2021-12-23
2022-01-18 18:44:20 -05:00
Anthony Sottile
c8cf74dc71 replace exit(main()) with raise SystemExit(main())
Committed via https://github.com/asottile/all-repos
2021-10-23 13:23:48 -04:00
Jordan Speicher
4cd8b364dd Add: post-rewrite hook support 2021-09-01 14:50:59 -05:00
Florent Clarret
584fd585ec Expose local branch ref as an environment variable 2021-06-19 18:18:14 +02:00
Paweł Sacawa
6b73138c73 Add: post-merge hook support 2021-02-23 19:00:02 -08:00
surafelabebe
cb5ed6276d Expose remote branch ref as an environment variable 2021-01-22 13:18:25 -08:00
Anthony Sottile
91530f1005 check cygwin mismatch earlier 2020-09-20 10:42:11 -07:00
Anthony Sottile
68510596d3 warn on old list-style configuration 2020-07-25 13:04:54 -07:00
Greg Singer
1b435f1f1f add init-templatedir --no-allow-missing-config
Add a `--no-allow-missing-config` option to the `init-templatedir`
command. Enable configuration of a Git template that requires newly
cloned repos to have a `pre-commit` config.
2020-07-20 19:02:35 -07:00
ModischFabrications
26adf1d560 add support for post-commit 2020-04-27 10:55:22 -07:00
Anthony Sottile
1e0db9c2c8 Fix help description for --from-ref and --to-ref 2020-03-12 12:27:54 -07:00
Anthony Sottile
d35b00352f Make more readable --from-ref / --to-ref aliases for --source / --origin 2020-02-23 11:07:57 -08:00
Andrew Hare
18fa004254 Add post-checkout 2020-02-23 10:22:18 -08:00
Anthony Sottile
95b8d71bd9 Move most of the actual hook script into pre-commit hook-impl 2020-01-21 16:41:22 -08:00
Anthony Sottile
0bb8a8fabe Move test to install_uninstall test so environment variables apply 2020-01-16 13:02:20 -08:00
David Martinez Barreiro
57cc814b8b Push remote env var details 2020-01-16 12:35:04 -08:00
Anthony Sottile
df40e862f4 More miscellaneous cleanup 2020-01-13 11:47:34 -08:00
Anthony Sottile
67c2dcd90d Remove pre_commit.five 2020-01-12 13:39:53 -08:00
Anthony Sottile
327ed924a3 Add types to pre-commit 2020-01-12 10:15:01 -08:00
Anthony Sottile
30c1e8289f upgrade hooks, pyupgrade pre-commit 2020-01-12 09:27:04 -08:00
orcutt989
c7d938c2c4 corrected styling 2020-01-10 18:49:21 -05:00
orcutt989
2cf127f2d3 fix prog arg to return correct version 2020-01-10 18:43:13 -05:00
Anthony Sottile
ae97bb5068 Remove autoupdate --tags-only option 2020-01-05 14:04:41 -08:00
Anthony Sottile
8a3c740f9e Implement pre-commit autoupdate --freeze 2019-12-28 13:07:39 -08:00
Anthony Sottile
c699e255a1 support pre-merge-commit 2019-12-26 21:21:00 -08:00
Anthony Sottile
2bdbd9e7a0 Fix for newest git 2019-12-06 09:27:19 -08:00
Anthony Sottile
0760bec3ff Show better error message when running inside .git 2019-11-18 14:57:41 -08:00
Anthony Sottile
36609ee305 Fix hook_types when calling init-templatedir 2019-09-30 10:29:53 -07:00
Anthony Sottile
a18646deb2 Allow --hook-type to be specified multiple times 2019-09-23 11:14:36 -07:00
Anthony Sottile
da80cc6479 Allow init-templatedir to be called outside of git 2019-08-03 11:41:54 -07:00
Edgar Geier
aaa249bda9 Overwrite default value of --color argument with PRE_COMMIT_COLOR env var 2019-07-23 17:42:28 +02:00
Anthony Sottile
9a52eefc99 Implement pre-commit init-templatedir 2019-07-20 20:33:42 -07:00
Anthony Sottile
3def940574 reorder pre-commit sub commands 2019-07-20 16:28:35 -07:00
Marc Jay
e60f541559 Adds support for prepare-commit-msg hooks
Adds a prepare-commit-msg hook stage which allows for hooks which add
dynamic suggested/placeholder text to commit messages that an author can
use as a starting point for writing a commit message
2019-04-21 21:07:13 +01:00
Anthony Sottile
917586a0e0 Don't require git for clean, gc, sample-config 2019-03-02 19:01:05 -08:00
Anthony Sottile
9e34e6e316 pre-commit gc 2019-01-02 19:07:23 -08:00
Anthony Sottile
e4f0b4c1b7 Only configure logging inside the context 2019-01-01 15:01:37 -08:00
Anthony Sottile
bdc58cc33f Teach pre-commit try-repo to clone uncommitted changes 2019-01-01 15:01:36 -08:00
Anthony Sottile
4da461d90a Fix try-repo relpath while in a sub-directory 2019-01-01 11:57:06 -08:00
Anthony Sottile
fe409f1a43 Remove stateful Runner 2018-12-26 22:33:21 -08:00
Anthony Sottile
c01ffc83f8 Separate store from runner 2018-06-29 22:35:53 -07:00
Anthony Sottile
6d683a5fac clean: separate store from runner 2018-06-29 20:08:23 -07:00
Anthony Sottile
0e430be0ce autoupdate: separate store from runner 2018-06-29 20:04:16 -07:00
Anthony Sottile
cd8179a974 Apply relative files to try-repo also 2018-05-12 10:01:14 -07:00