aboutsummaryrefslogtreecommitdiff
path: root/templates
diff options
context:
space:
mode:
authorJunio C Hamano <junkio@cox.net>2005-10-10 13:50:01 -0700
committerJunio C Hamano <junkio@cox.net>2005-10-10 13:51:52 -0700
commit4769948afe7c502d37746edc2ee2c084c9dcb325 (patch)
treecb6045a7e6dc192bfce076ed8c1bab3795822b5d /templates
parentd5b0c9ea178dab3599674ccff50645c0464b8c31 (diff)
downloadgit-4769948afe7c502d37746edc2ee2c084c9dcb325.tar.gz
git-4769948afe7c502d37746edc2ee2c084c9dcb325.tar.xz
Deal with $(bindir) and friends with whitespaces.
... using HPA's shellquote macro. Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'templates')
-rw-r--r--templates/Makefile10
1 files changed, 8 insertions, 2 deletions
diff --git a/templates/Makefile b/templates/Makefile
index c23aee866..07e928e56 100644
--- a/templates/Makefile
+++ b/templates/Makefile
@@ -6,6 +6,12 @@ prefix ?= $(HOME)
template_dir ?= $(prefix)/share/git-core/templates/
# DESTDIR=
+# Shell quote;
+# Result of this needs to be placed inside ''
+shq = $(subst ','\'',$(1))
+# This has surrounding ''
+shellquote = '$(call shq,$(1))'
+
all: boilerplates.made custom
find blt
@@ -38,6 +44,6 @@ clean:
rm -rf blt boilerplates.made
install: all
- $(INSTALL) -d -m755 $(DESTDIR)$(template_dir)
+ $(INSTALL) -d -m755 $(call shellquote,$(DESTDIR)$(template_dir))
(cd blt && $(TAR) cf - .) | \
- (cd $(DESTDIR)$(template_dir) && $(TAR) xf -)
+ (cd $(call shellquote,$(DESTDIR)$(template_dir)) && $(TAR) xf -)