File tree Expand file tree Collapse file tree 1 file changed +11
-13
lines changed Expand file tree Collapse file tree 1 file changed +11
-13
lines changed Original file line number Diff line number Diff line change 1
1
#!/usr/bin/env ruby
2
2
3
- # Check that modules actually pass msftidy checks first.
4
- # To install this script, make this your pre-commit hook your local
5
- # metasploit-framework clone. For example, if you have checked out
6
- # the Metasploit Framework to:
3
+ # Check that modules actually pass msftidy checks before committing
4
+ # or after merging.
7
5
#
8
- # /home/mcfakepants/git/metasploit-framework
6
+ # Simply symlink this script to your local .git/hooks/pre-commit script
7
+ # and your .git/hooks/post-merge scripts. Note the lack of a trailing
8
+ # .rb
9
9
#
10
- # then you will copy this script to :
10
+ # If you are in the top-level dir, the symlink commands would be :
11
11
#
12
- # /home/mcfakepants/git/metasploit-framework/.git/hooks/pre-commit
12
+ # ln -sf ../../tools/dev/pre-commit-hook.rb ./.git/hooks/post-commit
13
+ # ln -sf ../../tools/dev/pre-commit-hook.rb ./.git/hooks/post-merge
13
14
#
14
- # You must mark it executable (chmod +x), and do not name it
15
- # pre-commit.rb (just pre-commit)
16
- #
17
- # If you want to keep up on changes with this hook, just:
18
- #
19
- # ln -sf <this file> <path to commit hook>
15
+ # That way, you will track changes to this script when it updates
16
+ # (rarely). If you'd prefer to copy it directly, that's okay, too (mark
17
+ # it +x and don't name it filename.rb, just filename).
20
18
21
19
def merge_error_message
22
20
msg = [ ]
You can’t perform that action at this time.
0 commit comments