Simplifying linking bit

This commit is contained in:
Dan Buch 2014-09-30 22:37:55 -04:00
parent 6b98ca459f
commit 39aa7597b3

View File

@ -2,7 +2,7 @@ SOURCES := $(shell ls | grep -E -v 'README|Makefile')
TARGETS := $(patsubst %,$(HOME)/.%,$(SOURCES))
$(HOME)/.%: %
if [[ ! -e '$@' ]] ; then ln -sv '$(PWD)/$^' '$@' ; fi
$(RM) '$@' && ln -svf '$(PWD)/$^' '$@'
.PHONY: all
all: $(TARGETS)