Code

Fix off-by-one in read_tree_recursive
[git.git] / templates / Makefile
index 0722a926f71fb91a03a916e02fea456e8cc0086d..a12c6e214e65d39136b1ed41a8ff0ea25e28f91b 100644 (file)
@@ -31,9 +31,11 @@ boilerplates.made : $(bpsrc)
                dir=`expr "$$dst" : '\(.*\)/'` && \
                mkdir -p blt/$$dir && \
                case "$$boilerplate" in \
-               *--) ;; \
-               *) cp -p $$boilerplate blt/$$dst ;; \
-               esac || exit; \
+               *--) continue;; \
+               esac && \
+               cp $$boilerplate blt/$$dst && \
+               if test -x "blt/$$dst"; then rx=rx; else rx=r; fi && \
+               chmod a+$$rx "blt/$$dst" || exit; \
        done && \
        date >$@