-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathTODO
More file actions
69 lines (49 loc) · 3.05 KB
/
TODO
File metadata and controls
69 lines (49 loc) · 3.05 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
* Move this file's contents into GitHub issues, once we have a public GitHub repo for it.
* Convert to using Grit in git_ops.rb
* Do on-demand loading of Git information, so if no hook uses an
expensive Git operation, it can be skipped. The API allows it but
the implementation isn't in place yet.
* "Illegal content" hook -- for catching incomplete merges (">>>>>>"), etc.
* "Bundle install on pull" hook
* Wire up pre-rebase hooks to allow validations for multi-file
criteria. Then you can't rebase in a new file if it would violate
the CaseClashHook, say.
* A hook should have default hook types and file extensions and
git-hook names, and should only run if those match -- or if
registered with an overrriding git-hook name or file type.
* Add option registration to Hook parent class and do appropriate
string/symbol checking there.
* Print message if a hook is registered but run is never called.
* Use SimpleCov to check coverage in test_helper.rb
* Have a simple way to "forward" to another file. That is, save the
arguments and STDIN and call another file with the same arguments
and same STDIN. That would make it easy to have a "pre-commit.d"
directory and automatically call to every executable in that
directory matching "pre-commit" in the filename. Then you could
easily combine multiple hooks -- for instance, the cloner's personal
hooks, the workplace's at-work hooks and the project's supplied
hooks. Wouldn't always be a good idea, of course.
* Document (and figure out) how to write new hooks that aren't part of RubyGitHooks gem
There are details about how directories and environment variables are set
up by git when the hooks are called that can affect things like includes done by the hook.
For example most hooks are called with GIT_DIR set to .git and the working directory
set to the repo root BUT pre and post-receive are called with GIT_DIR set to '.'
and the working directory set to <repo root>/.git.
* Project-specific hooks. Right now, create a post-clone hook in
~/.git_hooks that looks for a /.hooks directory in the newly-created
repo and copies the hooks into ~/.git_hooks. Note that for now
these hooks will then *override* your personal ones. TODO: merge them.
* Where tests have "assert_raises RuntimeError", find a more specific
error. This occurs in several places.
* In copyright_check_hook, use regexp#scan instead of first match.
* In copyright_check_hook, allow passing the top-level regexp/check as
an option. This will require documenting that it overrides some other
things like the company check option.
* In jira_ref_check_hook, allow passing in list of legal statuses.
* In jira_ref_check_hook and jira_add_comment_hook, figure out how to
deal with checking with the server to see if a bug is real and
valid. This will be a tricky UI issue.
* In jira_add_comment_hook, rescue DNS errors for VPN setups. Allow
the commit, but print a message.
* In jira_add_comment_hook, allow to specify which branches to process
* In ruby_git_hooks.rb, have "shell!" capture both STDOUT and STDERR.