--- a/Makefile Sat Mar 13 15:52:00 2010 +0200
+++ b/Makefile Sat Mar 13 16:07:06 2010 +0200
@@ -17,11 +17,19 @@
.PHONY: install
install:
for item in $(ITEMS); do \
- [ -f $$item ] && install -m 640 $$item $(HOME)/$$item; \
- [ -d $$item ] && for file in `find $$item`; do \
- [ -d $$file ] && [ -d $(HOME)/$$file ] || mkdir -p $(HOME)/$$file; \
- [ -f $$file ] && install -m 640 $$file $(HOME)/$$file; \
- done; \
+ if [ -f $$item ]; then \
+ install -m 640 $$item $(HOME)/$$item; \
+ fi; \
+ if [ -d $$item ]; then \
+ for file in `find $$item`; do \
+ if [ -d $$file ]; then \
+ [ -d $(HOME)/$$file ] || mkdir -p $(HOME)/$$file; \
+ fi; \
+ if [ -f $$file ]; then \
+ install -m 640 $$file $(HOME)/$$file; \
+ fi; \
+ done; \
+ fi; \
done
.PHONY: uninstall