Anthony Sottile
2af0b0b4f3
better no-cover for windows
2018-12-27 18:25:52 -08:00
Pedro Algarvio
8ffd1f69d7
Address review comments
2018-12-27 17:18:11 +00:00
Pedro Algarvio
79c8b1fceb
Allow hook alias to be used in SKIP. Includes test.
2018-12-27 12:03:27 +00:00
Pedro Algarvio
5840f880a9
Address review comments and test failures
2018-12-27 12:03:27 +00:00
Pedro Algarvio
afbc57f2ad
Go back to optional. Requires less changes to existing code.
2018-12-27 12:03:27 +00:00
Pedro Algarvio
b096c0b8f2
Allow aliasing a hook and calling it by it's alias
2018-12-27 12:03:27 +00:00
Anthony Sottile
c5c0a0699b
Merge pull request #895 from pre-commit/rip_runner
...
Remove stateful Runner
2018-12-26 23:11:38 -08:00
Anthony Sottile
2b8291d18f
add a no-cover for py3 [ci skip]
2018-12-26 22:45:13 -08:00
Anthony Sottile
fe409f1a43
Remove stateful Runner
2018-12-26 22:33:21 -08:00
Anthony Sottile
de942894ff
Pick a better python shebang for hook executable
2018-12-25 12:11:02 -08:00
Anthony Sottile
435d9945a3
Switch from deprecated docs-off args to --no-document
2018-12-19 14:22:09 -08:00
Chris Kuehl
45e3dab00d
Shuffle arguments before running hooks
2018-11-19 17:53:19 -08:00
Anthony Sottile
e15d7cde86
Upgrade the sample config
2018-11-15 14:17:10 -08:00
Anthony Sottile
dc84f21dd4
Merge pull request #857 from runz0rd/master
...
Reraises InvalidManifestError as RepositoryCannotBeUpdatedError
2018-11-14 17:29:43 -08:00
Anthony Sottile
aaa3976a29
Use text_type instead of str()
2018-11-13 17:23:32 -08:00
Milos Pejanovic
e339de22d7
Added requested changes
2018-11-14 01:59:18 +01:00
Milos Pejanovic
bf8c8521cd
Added a test and small change for error output
2018-11-14 00:43:04 +01:00
Anthony Sottile
6bac405d40
Minor cleanups
2018-11-01 18:05:36 -07:00
Milos Pejanovic
1c97d3f5fd
Added a try except block which reraises InvalidManifestError as RepositoryCannotBeUpdatedError
2018-10-31 17:39:47 +01:00
Chris Kuehl
9125439c3a
Force serial hook runs during tests
2018-10-24 16:33:06 -07:00
Chris Kuehl
aa50a8cde0
Switch to using concurrent.futures
2018-10-24 16:33:06 -07:00
Chris Kuehl
b6926e8e2e
Attempt to partition files to use all possible cores
2018-10-24 16:33:06 -07:00
Chris Kuehl
ec0ed8aef5
Handle CPU detection errors and running on Travis
2018-10-24 16:16:13 -07:00
Chris Kuehl
ba5e27e4ec
Implement concurrent execution of individual hooks
2018-10-24 16:16:10 -07:00
Anthony Sottile
1f1cd2bc39
Merge pull request #839 from georgeyk/refactor-xargs-partition
...
Update xargs.partition with platform information
2018-10-23 22:55:30 -07:00
Anthony Sottile
ead906aed0
Compute win32 python2 length according to encoded size
2018-10-23 22:02:48 -07:00
Anthony Sottile
6cde287a1e
Install multi-hook repositories only once
2018-10-23 10:28:37 -07:00
Anthony Sottile
9f60561d6f
Replace resources with importlib_resources
2018-10-14 14:37:35 -07:00
Anthony Sottile
ebe5132576
Replace pkg_resources.get_distribution with importlib-metadata
2018-10-14 12:24:59 -07:00
Anthony Sottile
3181b461aa
fix pushing to new branch not identifying all commits
2018-10-10 20:08:16 -07:00
George Y. Kussumoto
c9e297ddb6
Fix xargs.partition: win32 new string length computation
2018-10-09 22:54:41 -03:00
George Y. Kussumoto
333ea75e45
Refactor xargs.partition: _command_length usage
2018-10-06 20:04:17 -03:00
George Y. Kussumoto
2ad69e12ce
Fix xargs.partition: use sys.getfilesystemencoding
...
The previous `sys.getdefaultencoding` almost always fallsback to
`ascii` while `sys.getfilesystemencoding` is utf-8 once in utf-8 mode.
2018-10-05 16:39:49 -03:00
George Y. Kussumoto
fa4c03da65
Update xargs.partition with platform information
...
Change how xargs.partition computes the command length (including
arguments) depending on the plataform.
More specifically, 'win32' uses the amount of characters while posix
system uses the byte count.
2018-10-05 11:54:31 -03:00
George Y. Kussumoto
1b496c5fc3
Fix check-useless-exclude to consider types filter
2018-10-02 12:17:46 -03:00
Anthony Sottile
18b6f4b519
Fix rev-parse for older git versions
2018-09-22 11:12:27 -07:00
Anthony Sottile
ce25b652b9
Exempt language: fail hooks from check-hooks-apply
2018-09-02 18:54:34 -07:00
Jeffrey Rackauckas
3d777bb386
Move logic to handle terminal not supporting colors to use_color
2018-08-30 19:15:46 -07:00
Jeffrey Rackauckas
a970d3b69b
Removing useless pass statement.
2018-08-30 18:45:29 -07:00
Jeffrey Rackauckas
1bd6fce7dc
Don't print bogus characters on windows terminals that don't support colors.
2018-08-29 18:54:55 -07:00
Anthony Sottile
f042e302d8
Merge pull request #815 from pre-commit/update_config
...
Update config
2018-08-16 07:44:27 -07:00
Anthony Sottile
72d10903d5
Update config
2018-08-15 17:55:06 -07:00
Anthony Sottile
a6e2e1d4bb
Add language: fail
2018-08-10 18:11:28 -07:00
Mickaël Schoentgen
67d6fcb0f6
Fix several ResourceWarning: unclosed file
2018-08-10 18:30:22 +02:00
Anthony Sottile
3f78487769
Support pre-commit install inside a worktree
2018-08-06 09:26:42 -07:00
Anthony Sottile
7e69d117c6
Work around sys.executable issue using brew python on macos
...
https://github.com/Homebrew/homebrew-core/issues/30445
2018-07-24 16:05:26 -07:00
Matt Layman
fd1bc21d8e
Use parens instead of different logic pattern.
2018-07-19 23:27:29 -04:00
Matt Layman
4640dc7b4a
Run only the specified hook even when stages exist in config.
...
This branches fixes the run logic so that when
`pre-commit run some_hook -a` runs when the config contains
`stages: ['commit']` for some other hook, only the hook specified as an
argument will run.
Fixes #772
2018-07-19 21:45:43 -04:00
Anthony Sottile
99972df1da
Merge pull request #797 from pre-commit/default_python_3_venv
...
Default to python3 when using python_venv under python 2
2018-07-17 20:20:54 -07:00
Anthony Sottile
0eaacd7c8e
Default to python3 when using python_venv under python 2
2018-07-17 18:24:29 -07:00