-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathinstall.conf.common.yaml
More file actions
164 lines (134 loc) · 5.61 KB
/
Copy pathinstall.conf.common.yaml
File metadata and controls
164 lines (134 loc) · 5.61 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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
# Cross-platform Dotbot config. Run on every platform, before the
# OS-specific config (install.conf.darwin.yaml / install.conf.linux.yaml)
# selected by the ./install wrapper.
- defaults:
link:
relink: true
shell:
quiet: true
- shell:
- description: Validating sudo credentials
command: "[ -n \"$CI\" ] || sudo --validate"
- description: Installing Debian/Ubuntu prerequisites
command: |
if [ "$(uname -s)" = "Linux" ] && command -v apt-get >/dev/null 2>&1; then
sudo apt-get update -qq
sudo apt-get install -y --no-install-recommends \
zsh build-essential procps curl file git \
xclip wl-clipboard libnotify-bin telnet
fi
- description: Installing XCode Command Line Tools
command: "[ \"$(uname -s)\" != \"Darwin\" ] || [ -n \"$CI\" ] || [ -x \"$(which xcodebuild)\" ] || xcode-select --install"
- clean: ['~']
- create:
- ~/Code
- ~/.tmux/plugins
- ~/bin
- ~/.config/gh-dash
- ~/.config/tuicr
- link:
# Binaries
~/bin/$: bin/$
~/bin/capitalize: bin/capitalize
~/bin/epoch: bin/epoch
~/bin/kebab: bin/kebab
~/bin/lower: bin/lower
~/bin/title: bin/title
~/bin/unzlib: bin/unzlib
~/bin/upper: bin/upper
~/bin/urlencode: bin/urlencode
~/bin/uuid: bin/uuid
~/bin/xkcd: bin/xkcd
# Git
~/.gitconfig:
path: git/gitconfig
force: true
~/.gitignore_global: git/gitignore_global
~/.git_allowed_signers: git/git_allowed_signers
~/.config/catppuccin.gitconfig: git/catppuccin.gitconfig
# Atuin
~/.config/atuin:
path: atuin
force: true
# Starship prompt
~/.config/starship.toml:
path: starship/starship.toml
force: true
# Kitty shell
~/.config/kitty: kitty
# gh-dash
~/.config/gh-dash/config.yml:
path: gh-dash/config.yml
force: true
# tuicr
~/.config/tuicr/config.toml:
path: tuicr/config.toml
force: true
# Tmux
~/.tmux.conf: tmux/tmux.conf
~/.tmux/now-playing.sh: tmux/now-playing.sh
~/.tmux/next-meeting.sh: tmux/next-meeting.sh
# Nvim
~/.config/nvim: vim
# Zsh
~/.zshrc: zsh/zshrc
- shell:
- description: Installing Homebrew
command: "[ -x \"$(command -v brew)\" ] || /bin/bash -c \"$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)\""
- description: Updating Homebrew
command: |
for b in /opt/homebrew/bin/brew /home/linuxbrew/.linuxbrew/bin/brew /usr/local/bin/brew; do
[ -x "$b" ] && eval "$("$b" shellenv)" && break
done
brew update
- description: Installing Brewfile bundle
command: |
for b in /opt/homebrew/bin/brew /home/linuxbrew/.linuxbrew/bin/brew /usr/local/bin/brew; do
[ -x "$b" ] && eval "$("$b" shellenv)" && break
done
brew bundle --file=brew/Brewfile.common || exit 1
if [ "$(uname -s)" = "Darwin" ]; then
if [ -n "$CI" ]; then
# CI can't install casks or Mac App Store apps, so bundle only the
# taps and brew formulae from the macOS file.
grep -E '^(tap|brew)' brew/Brewfile.darwin | brew bundle --file=- || exit 1
else
brew bundle --file=brew/Brewfile.darwin || exit 1
fi
fi
stdout: true
stderr: true
# Hide "last login" line when starting a new terminal session
- description: Hushing login
command: "[ -f ~/.hushlogin ] || touch ~/.hushlogin"
- description: Adding ZSH to list of acceptable shells
command: "[ -n \"$CI\" ] || grep -q \"$(which zsh)\" /etc/shells || sudo sh -c \"echo $(which zsh) >> /etc/shells\""
- description: Making ZSH the default shell
command: "[ -n \"$CI\" ] || [ \"$SHELL\" = \"$(which zsh)\" ] || sudo chsh -s $(which zsh) $(whoami)"
- description: Installing ZSH autocompletions
command: "git clone https://github.com/zsh-users/zsh-completions ${DOTFILES}/zsh/plugins/zsh-completions 2> /dev/null || exit 0"
- description: Installing ZSH autosuggestions
command: "git clone https://github.com/zsh-users/zsh-autosuggestions ${DOTFILES}/zsh/plugins/zsh-autosuggestions 2> /dev/null || exit 0"
- description: Installing ZSH syntax highlighting
command: "git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${DOTFILES}/zsh/plugins/zsh-syntax-highlighting 2> /dev/null || exit 0"
- description: Installing git-trim
command: "git clone https://github.com/jasonmccreary/git-trim.git ${DOTFILES}/zsh/plugins/git-trim 2> /dev/null || exit 0"
- description: Installing tmux plugins
command: "git clone https://github.com/tmux-plugins/tpm ~/.tmux/plugins/tpm || exit 0"
- description: Clear sudo credential cache
command: "[ -n \"$CI\" ] || sudo --reset-timestamp"
- description: Installing bat's theme
command: |
for b in /opt/homebrew/bin/brew /home/linuxbrew/.linuxbrew/bin/brew /usr/local/bin/brew; do
[ -x "$b" ] && eval "$("$b" shellenv)" && break
done
mkdir -p "$(bat --config-dir)/themes" && \
wget -P "$(bat --config-dir)/themes" https://github.com/catppuccin/bat/raw/main/themes/Catppuccin%20Mocha.tmTheme && \
bat cache --build || exit 0
- description: Installing gh extensions
command: |
for b in /opt/homebrew/bin/brew /home/linuxbrew/.linuxbrew/bin/brew /usr/local/bin/brew; do
[ -x "$b" ] && eval "$("$b" shellenv)" && break
done
gh extension install dlvhdr/gh-dash 2>/dev/null || true
gh extension install korosuke613/gh-user-stars 2>/dev/null || true