aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2019-05-29 14:38:35 +1200
committerTom Ryder <tom@sanctum.geek.nz>2019-05-29 14:38:35 +1200
commit2df4949713ee433a158ad310b51613ce7cd66099 (patch)
tree294962bc5e0d09ab01ee31a0994e216724c14a02 /Makefile
parentRemove mapping loop from normal CTRL-L in vimrc (diff)
downloaddotfiles-2df4949713ee433a158ad310b51613ce7cd66099.tar.gz
dotfiles-2df4949713ee433a158ad310b51613ce7cd66099.zip
Add first attempt at Git template dir
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile14
1 files changed, 12 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index 9468ff85..3740970e 100644
--- a/Makefile
+++ b/Makefile
@@ -261,7 +261,9 @@ GAMES = games/aaf \
games/xyzzy \
games/zs
-all: $(BINS) git/gitconfig gnupg/gpg.conf
+GIT_TEMPLATE_HOOKS = git/template/hooks/post-update
+
+all: $(BINS) git/gitconfig $(GIT_TEMPLATE_HOOKS) gnupg/gpg.conf
clean distclean:
rm -f -- \
@@ -269,6 +271,7 @@ clean distclean:
$(BINS_M4) \
$(BINS_SH) \
$(GAMES) \
+ $(GIT_TEMPLATE_HOOKS) \
dillo/dillorc \
dillo/dillorc.m4 \
git/gitconfig \
@@ -414,8 +417,15 @@ install-games-man:
mkdir -p -- $(HOME)/.local/share/man/man6
cp -p -- man/man6/*.6df $(HOME)/.local/share/man/man6
-install-git: git/gitconfig
+install-git: git/gitconfig $(GIT_TEMPLATE_HOOKS)
cp -p -- git/gitconfig $(HOME)/.gitconfig
+ find git/template \
+ -type d -exec sh -c 'mkdir -p -- \
+ $(HOME)/.git-template"$${1#git/template}"' \
+ _ {} \; \
+ -o -exec sh -c 'cp -p -- "$$1" \
+ $(HOME)/.git-template"$${1#git/template}"' \
+ _ {} \;
install-gnupg: gnupg/gpg.conf
mkdir -m 0700 -p -- $(HOME)/.gnupg