Closed nik-kor closed 8 years ago
@tarmolov +1
@nik-kor the best place to store such ignores (os, editor specific) is your global .gitttgnore
https://help.github.com/articles/ignoring-files/#create-a-global-gitignore
@tarmolov I hate you. No, just joking)
yeah, it's a good idea to use global ignore settings. Have to figure out how to extract them because they can be anywhere and I, probably, should analyze git settings
@nik-kor why ever need to extract it. Just manage it on your own machine.
@Guria because I want to teach git-hooks to ignore some files inside git-hooks/ folders.
Aren't githooks already ignores all that ignored by git just from its nature?
No, it isn't.) I mean this https://github.com/tarmolov/git-hooks-js/blob/master/lib/git-hooks.js#L109 should be teached to ignore some stuff from .githooks
Let's use git-check-ignore to check path before execution hook. It seems it'll solve the issue and you don't need to add a separate .githooksignore
.
$ git check-ignore -q node_modules/.bin/mocha
$ echo $?
0
$ git check-ignore -q bin/git-hooks
$ echo $?
1
have to check while it is not working in node 0.10....(
Just a couple of remarks and I'm ready to merge it :)
rebased it.
Thank you
Thank you too! I knew some stuff doing this tiny PR)
Now you probably start hating me ^^
I think
.githooksignore
should absolutely the same as original .gitignore becausegit-hooks
andgit
are tightly connected and tangled ;)