-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathMakefile
More file actions
55 lines (42 loc) · 1.84 KB
/
Copy pathMakefile
File metadata and controls
55 lines (42 loc) · 1.84 KB
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
# Makefile for setting up dotfiles and misc workstation settings
UNAME := $(shell uname)
XDG_CONFIG_HOME ?= $(HOME)/.config
# Active packages stowed on Linux. Desktop WM configs (sway, i3, alacritty, wofi)
# live under legacy/ and are not deployed.
STOW_PACKAGES = bash git tmux nvim bin systemd gnupg ghostty chrome hyprland quickshell autostart uwsm
.PHONY: clean vim shell stow unstow linux check links restow-desktop
all: stow vim shell
clean: unstow
vim:
mkdir -p $(HOME)/.backups
mkdir -p $(HOME)/.vim/bundle
git clone https://github.com/VundleVim/Vundle.vim.git ~/.vim/bundle/Vundle.vim
# Run this only when on MacOS
ifeq ($(UNAME), Darwin)
brew:
brew install shellcheck
endif
# TODO: use git submodules here
shell:
mkdir -p $(HOME)/.third_party
git clone https://github.com/olivierverdier/zsh-git-prompt.git ${HOME}/.third_party/zsh-git-prompt
git clone https://github.com/jonmosco/kube-ps1.git ${HOME}/.third_party/kube-ps1
test -d ${HOME}/.bash-git-prompt/.git || git clone --depth=1 https://github.com/magicmonty/bash-git-prompt.git ${HOME}/.bash-git-prompt
stow: links restow-desktop
stow --verbose --target=$$HOME --restow $(STOW_PACKAGES)
unstow:
stow --verbose --target=$$HOME --delete $(STOW_PACKAGES)
linux: stow
check: links
stow --verbose --simulate --target=$$HOME --restow $(STOW_PACKAGES)
# Remove manual absolute symlinks that block stow, then restow desktop configs
restow-desktop:
rm -f $(HOME)/.config/hypr/hypridle.conf $(HOME)/.config/hypr/hyprlock.conf $(HOME)/.config/hypr/hyprpaper.conf
rm -f $(HOME)/.config/quickshell
stow --verbose --target=$$HOME --restow hyprland quickshell
links:
ln -sf $(CURDIR)/dircolors $(HOME)/.dircolors
ln -sf $(CURDIR)/.path $(HOME)/.path
ln -sf $(CURDIR)/exports $(HOME)/.exports
ln -sf $(CURDIR)/aliases $(HOME)/.aliases
ln -sf $(CURDIR)/bash/bash_git_prompt $(HOME)/.bash_git_prompt