-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
26 lines (21 loc) · 902 Bytes
/
Copy pathMakefile
File metadata and controls
26 lines (21 loc) · 902 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
REPO_FILES := $(wildcard .??*)
REPO_CONFIG_DIRS := $(wildcard .config/*)
IGNORE_FILES := .DS_Store .git .gitmodules .gitignore .config
IGNORE_DIRS := .claude
DOT_FILES := $(filter-out $(IGNORE_FILES),$(REPO_FILES))
CONFIG_DIRS := $(filter-out $(IGNORE_DIRS),$(REPO_CONFIG_DIRS))
all: install
check:
@$(foreach dotfile, $(DOT_FILES), /bin/ls -dF $(dotfile);)
@$(foreach configdir, $(CONFIG_DIRS), echo $(configdir);)
install:
mkdir -p ${HOME}/.config
@$(foreach dotfile, $(DOT_FILES), ln -sfnv $(abspath $(dotfile)) "$(HOME)/$(dotfile)";)
@$(foreach configdir, $(CONFIG_DIRS), ln -sfnv $(abspath $(configdir)) "$(HOME)/$(configdir)";)
touch ${HOME}/.w3m/history
.PHONY: emacs
emacs:
emacs --batch -f batch-byte-compile ~/.emacs.d/init.el
clean:
@-$(foreach dotfile, $(DOT_FILES), rm -vrf $(HOME)/$(dotfile);)
@-$(foreach configdir, $(REPO_CONFIG_DIRS), rm -vrf $(HOME)/$(configdir);)