confOS/Makefile
Mylloon 634ad14a18
Revert "test"
This reverts commit b43682344e.
2023-03-19 19:20:18 +01:00

57 lines
857 B
Makefile

# Version control
VC = git
# Hide some verbose messages from Make
MAKEFLAGS += --no-print-directory
all: full-sync
# Pull latest changes
refresh:
@$(VC) pull
# Pull and sync
full-sync:
@$(MAKE) refresh
@$(MAKE) sync
# === All platforms ==
# .config
sync-dotconfig:
@mkdir -p $(HOME)/.config/fish/conf.d
@mkdir -p $(HOME)/.config/fish/functions
@echo .config directory synced!
# .emacs.d
sync-emacs:
@echo Emacs config synced!
# .mozilla
sync-mozilla:
@echo Firefox config synced!
# .unison
sync-unison:
@echo Unison preferences synced!
# === Specific platforms ==
sync:
ifeq ($(shell grep -c "archlinux" /proc/version), 1)
# Arch
@$(MAKE) sync-dotconfig
@$(MAKE) sync-emacs
@$(MAKE) sync-mozilla
else ifeq ($(shell grep -c "WSL" /proc/version), 1)
# WSL
@$(MAKE) sync-dotconfig
@$(MAKE) sync-emacs
@$(MAKE) sync-unison
endif