-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
59 lines (49 loc) · 1.92 KB
/
Makefile
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
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
SHELL := /bin/bash
include $(abspath make/1password.$(shell uname -s).Makefile)
include $(abspath make/ansible.$(shell uname -s).Makefile)
include $(abspath make/aws.$(shell uname -s).Makefile)
include $(abspath make/azure.$(shell uname -s).Makefile)
include $(abspath make/git.Makefile)
include $(abspath make/k8s.$(shell uname -s).Makefile)
include $(abspath make/prometheus.$(shell uname -s).Makefile)
include $(abspath make/util.$(shell uname -s).Makefile)
include $(abspath make/web.$(shell uname -s).Makefile)
.DEFAULT_GOAL := guhcampos-dotfiles
.PHONY: guhcampos-dotfiles
guhcampos-dotfiles: $(HOME)/.ansible.cfg
guhcampos-dotfiles: $(HOME)/.bash_profile
guhcampos-dotfiles: $(HOME)/.bashrc
guhcampos-dotfiles: $(HOME)/.config/user-dirs.dirs
guhcampos-dotfiles: $(HOME)/.dircolors
guhcampos-dotfiles: $(HOME)/.editorconfig
guhcampos-dotfiles: $(HOME)/.gitconfig
guhcampos-dotfiles: $(HOME)/.profile
guhcampos-dotfiles: $(HOME)/.starship.toml
guhcampos-dotfiles: $(HOME)/.tmux.conf
guhcampos-dotfiles: $(HOME)/.vim/colors/monokai.vim
guhcampos-dotfiles: $(HOME)/.vimrc
guhcampos-dotfiles: $(HOME)/.config/bash.d
# web development stuff
guhcampos-dotfiles: /opt/homebrew/bin/hugo
guhcampos-dotfiles: /opt/homebrew/bin/npx
guhcampos-dotfiles: /opt/homebrew/bin/fzf
# this ensures all files in ~/config/bash.d/*.sh exist:
guhcampos-dotfiles: $(addprefix $(HOME)/.config/bash.d/,$(notdir $(wildcard dotfiles/home/_config/bash.d/*.sh)))
$(HOME)/.config/bash.d:
mkdir -p $@
$(HOME)/.config/bash.d/%.sh: dotfiles/home/_config/bash.d/%.sh
@mkdir -p $(HOME)/.config/bash.d
@echo "GUHCAMPOS: linking $@"
@ln -sf $(realpath -s dotfiles/home/_config/bash.d/$*.sh) $@
$(HOME)/.%: dotfiles/home/_%
@echo "GUHCAMPOS: linking dotfiles in $(HOME)"
@ln -sf $(realpath -s $<) $@
.PHONY: clean
clean:
rm -rf ~/.config/bash.d/*.sh
.PHONY: docker
docker:
clear
@echo "HAS_PODMAN: $(HAS_PODMAN)"
@echo "HAS_DOCKER: $(HAS_DOCKER)"
@echo "CMD_DOCKER: $(CMD_DOCKER)"