Makefile - dotfiles - These are my dotfiles. There are many like it, but these are mine.
 (HTM) git clone git://jay.scot/dotfiles
 (DIR) Log
 (DIR) Files
 (DIR) Refs
 (DIR) README
       ---
       Makefile (745B)
       ---
            1 REPOSITORY = http://git.suckless.org/dmenu
            2 SRC_DIR = src
            3 PINNED_REVISION = HEAD
            4 PATCH_DIR = patches
            5 
            6 all: $(SRC_DIR)
            7 
            8 clean: reset
            9         @if test -d $(SRC_DIR); then \
           10                 $(MAKE) -C "${SRC_DIR}" -s clean; \
           11                 git -C "${SRC_DIR}" clean -f; \
           12         fi
           13 
           14 $(SRC_DIR): clone reset patch
           15         @cp config.h $@
           16         $(MAKE) -C "${SRC_DIR}" -s
           17 
           18 patch: $(PATCH_DIR)/*
           19         @for file in $^ ; do \
           20                 patch -d "${SRC_DIR}" < $${file}; \
           21         done
           22 reset:
           23         @if [ -n "$(strip $(PINNED_REVISION))" ]; then \
           24                 git -C "${SRC_DIR}" reset --hard $(PINNED_REVISION); \
           25         fi
           26 
           27 clone:
           28         @if ! test -d $(SRC_DIR); then \
           29                 git clone $(REPOSITORY) $(SRC_DIR); \
           30         fi
           31 
           32 update: clean
           33         @git -C "${SRC_DIR}" pull
           34 
           35 install:
           36         $(MAKE) -C "${SRC_DIR}" -s install
           37 
           38 
           39 .PHONY: all clean update install reset clone