Sync with make
This commit is contained in:
parent
b34ea62cf9
commit
ada40b4c0d
1 changed files with 41 additions and 0 deletions
41
Makefile
Normal file
41
Makefile
Normal file
|
@ -0,0 +1,41 @@
|
||||||
|
# Hide some verbose messages from Make
|
||||||
|
MAKEFLAGS += --no-print-directory
|
||||||
|
|
||||||
|
all: sync
|
||||||
|
|
||||||
|
# === All platforms ==
|
||||||
|
|
||||||
|
sync-dotconfig:
|
||||||
|
@mkdir -p $(HOME)/.config/fish/conf.d
|
||||||
|
@mkdir -p $(HOME)/.config/fish/functions
|
||||||
|
|
||||||
|
@echo .config directory synced!
|
||||||
|
|
||||||
|
sync-emacs:
|
||||||
|
@echo Emacs config synced!
|
||||||
|
|
||||||
|
sync-mozilla:
|
||||||
|
@echo Firefox config synced!
|
||||||
|
|
||||||
|
sync-unison:
|
||||||
|
@echo Unison preferences synced!
|
||||||
|
|
||||||
|
|
||||||
|
# === Specific platforms ==
|
||||||
|
|
||||||
|
sync:
|
||||||
|
ifeq ($(shell expr "uname -r" \> "archlinux"), 0)
|
||||||
|
# Arch
|
||||||
|
@$(MAKE) sync-dotconfig
|
||||||
|
|
||||||
|
|
||||||
|
@$(MAKE) sync-emacs
|
||||||
|
@$(MAKE) sync-mozilla
|
||||||
|
else ifeq ($(shell expr "uname -r" \> "WSL2"), 0)
|
||||||
|
# WSL
|
||||||
|
@$(MAKE) sync-dotconfig
|
||||||
|
|
||||||
|
|
||||||
|
@$(MAKE) sync-emacs
|
||||||
|
@$(MAKE) sync-unison
|
||||||
|
endif
|
Loading…
Reference in a new issue