]> git.madduck.net Git - etc/vcsh.git/commitdiff

madduck's git repository

Every one of the projects in this repository is available at the canonical URL git://git.madduck.net/madduck/pub/<projectpath> — see each project's metadata for the exact URL.

All patches and comments are welcome. Please squash your changes to logical commits before using git-format-patch and git-send-email to patches@git.madduck.net. If you'd read over the Git project's submission guidelines and adhered to them, I'd be especially grateful.

SSH access, as well as push access can be individually arranged.

If you use my repositories frequently, consider adding the following snippet to ~/.gitconfig and using the third clone URL listed for each project:

[url "git://git.madduck.net/madduck/"]
  insteadOf = madduck:

Only run init hook during init
authormartin f. krafft <madduck@madduck.net>
Sat, 2 Nov 2019 08:02:21 +0000 (21:02 +1300)
committermartin f. krafft <madduck@madduck.net>
Sat, 2 Nov 2019 08:02:21 +0000 (21:02 +1300)
.config/vcsh/hooks-available/post-init.write-gitignore

index 012db00b3be29d32042eb1a8fb37c755f0428edb..4039ca8738cd618b8a1fe825b74810f8f205c09e 100755 (executable)
@@ -1,5 +1,9 @@
 #!/bin/sh
 
+# only run during an actual init (not when init is called as part of e.g.
+# clone).
+[ $VCSH_COMMAND = init ] || exit 0
+
 cd $GIT_WORK_TREE
 
 GIT_IGNORE_FILE=.gitignore.d/$VCSH_REPO_NAME