Ignore build artifact
[khome.git] / Makefile
index ca39916..0051363 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -8,6 +8,8 @@ DEPS := $(wildcard deps/*)
     $(DEPS) \
     deps \
     home \
+    diff \
+    pull \
     mpdconf \
     pkgs_brew_cask_install \
     pkgs_brew_install \
@@ -126,24 +128,14 @@ endef
 $(foreach d,$(DEPS),$(eval $(call GEN_DEP_RULE,$(d))))
 
 diff:
-       diff  $(HOME)/.Rprofile                           home/.Rprofile                           ||  true
-       diff  $(HOME)/.compton.conf                       home/.compton.conf                       ||  true
-       diff  $(HOME)/.config/dunst/dunstrc               home/.config/dunst/dunstrc               ||  true
-       diff  $(HOME)/.config/mimeapps.list               home/.config/mimeapps.list               ||  true
-       diff  $(HOME)/.config/neofetch/config.conf        home/.config/neofetch/config.conf        ||  true
-       diff  $(HOME)/.config/ranger/rc.conf              home/.config/ranger/rc.conf              ||  true
-       diff  $(HOME)/.config/screengrab/screengrab.conf  home/.config/screengrab/screengrab.conf  ||  true
-       diff  $(HOME)/.fonts.conf                         home/.fonts.conf                         ||  true
-       diff  $(HOME)/.mpdconf                            home/.mpdconf                            ||  true
-       diff  $(HOME)/.newsboat/config                    home/.newsboat/config                    ||  true
-       diff  $(HOME)/.profile                            home/.profile                            ||  true
-       diff  $(HOME)/.tmux.conf                          home/.tmux.conf                          ||  true
-       diff  $(HOME)/.xbindkeysrc                        home/.xbindkeysrc                        ||  true
-       diff  $(HOME)/lib/login_aliases.sh                home/lib/login_aliases.sh                ||  true
-       diff  $(HOME)/lib/login_functions.sh              home/lib/login_functions.sh              ||  true
-       diff  $(HOME)/lib/login_variables.sh              home/lib/login_variables.sh              ||  true
-       diff  $(HOME)/lib/login_variables_dpi_high.sh     home/lib/login_variables_dpi_high.sh     ||  true
-       diff  $(HOME)/lib/login_variables_dpi_norm.sh     home/lib/login_variables_dpi_norm.sh     ||  true
+       find home -type f -print0 \
+       | sed -z 's/^home\///g' \
+       | xargs -0 -I% sh -c 'echo %; diff --color=always ~/% home/%'
+
+pull:
+       find home -type f -print0 \
+       | sed -z 's/^home\///g' \
+       | xargs -0 -I% sh -c 'diff -q ~/% home/% > /dev/null || cp ~/% home/%'
 
 clean:
        rm -rf ./debfiles
This page took 0.033588 seconds and 4 git commands to generate.