summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--Makefile52
1 files changed, 40 insertions, 12 deletions
diff --git a/Makefile b/Makefile
index 4ff03ea..0d69c4a 100644
--- a/Makefile
+++ b/Makefile
@@ -1,20 +1,42 @@
-OS := $(shell uname -s)
-
+XDG_CONFIG=$(HOME)/.config/
+WORKSPACE=$(HOME)/workspace
 LN = @ln -sf
 
-.PHONY: install-general
-install-general:
-	@mkdir -p $(HOME)/.config
-	@mkdir -p $(HOME)/workspace/
-	@curl -s https://github.com/fcuny.keys -o $(HOME)/.ssh/authorized_keys
+.PHONY: xdg_config
+xdg_config:
+	@mkdir -p $(XDG_CONFIG)
+
+.PHONY: go
+go:
+	@go install golang.org/x/tools/gopls@latest
+	@go install honnef.co/go/tools/cmd/staticcheck@latest
+	@go install github.com/go-delve/delve/cmd/dlv@latest
+
+.PHONY: emacs
+emacs: xdg_config git go
+	$(LN) $(PWD)/emacs $(XDG_CONFIG)
 	$(LN) $(PWD)/aspell.en.pws $(HOME)/.aspell.en.pws
-	$(LN) $(PWD)/config/git $(HOME)/.config/
-	$(LN) $(PWD)/emacs $(HOME)/.config/
-	$(LN) $(PWD)/tmux.conf $(HOME)/.tmux.conf
+
+.PHONY: zsh
+zsh:
 	$(LN) $(PWD)/zshenv $(HOME)/.zshenv
 	$(LN) $(PWD)/zshrc $(HOME)/.zshrc
-	@git config --local user.email "franck@fcuny.net"
-	@git config --local user.name "Franck Cuny"
+
+.PHONY: git
+git: xdg_config
+	$(LN) $(PWD)/config/git $(XDG_CONFIG)
+
+.PHONY: tmux
+tmux:
+	$(LN) $(PWD)/tmux.conf $(HOME)/.tmux.conf
+
+.PHONY: workspace
+workspace:
+	@mkdir -p $(WORKSPACE)
+
+.PHONY: ssh
+ssh:
+	@curl -s https://fcuny.net/ssh.pub.sig -o $(HOME)/.ssh/authorized_keys
 
 .PHONY: check-dead
 check-dead:
@@ -24,3 +46,9 @@ check-dead:
 clean-dead:
 	@find ~ -maxdepth 1 -name '.*' -type l -exec test ! -e {} \; -delete
 
+.PHONY: setup
+setup:
+	@git config --local user.email "franck@fcuny.net"
+	@git config --local user.name "Franck Cuny"
+
+all: setup xdg_config workspace emacs zsh git tmux ssh check-dead