-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.install.sh
executable file
·246 lines (221 loc) · 8.2 KB
/
.install.sh
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
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
#!/bin/zsh
# Install xCode cli tools
echo "Installing commandline tools..."
xcode-select --install
# Install zap-zsh
zsh <(curl -s https://raw.githubusercontent.com/zap-zsh/zap/master/install.zsh) --branch release-v1
# Copying and checking out configuration files
echo "Checking out configuration files to ${HOME}"
[ ! -d "$HOME/dotfiles" ] && git clone --bare https://github.com/amogower/dotfiles.git $HOME/dotfiles
git --git-dir=$HOME/dotfiles/ --work-tree=$HOME checkout master
# Reload zsh
source $HOME/.zshrc
# Homebrew
## Install
echo "Installing brew..."
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
brew analytics off
## Taps
echo "Tapping brew..."
brew tap homebrew/cask-fonts
brew tap homebrew/cask-versions
brew tap koekeishiya/formulae
brew tap FelixKratz/formulae
brew tap hashicorp/tap
## Formulae
echo "Installing brew formulae..."
### Essentials
brew install git
brew install git-delta
brew install llvm
brew install wget
brew install jq
brew install ripgrep
brew install mas
brew install gh
brew install ifstat
brew install switchaudio-osx
brew install tmux
brew install fzf
brew install asdf
brew install bat
brew install eza
brew install tailspin
brew install stern
brew install duti
brew install foreman
brew install watch
brew install watchman
brew install trash
brew install gpg2
brew install gnupg
brew install pinentry-mac
brew install docker
brew install kubectl
brew install kubectx
brew install hashicorp/tap/terraform
brew install helm
brew install flyctl
brew install redis
brew install task
brew install timewarrior
brew install dooit
brew install skhd
brew install sketchybar
brew install borders
brew install yabai
brew install nnn
brew install jesseduffield/lazygit/lazygit
## Casks
echo "Installing brew casks..."
### Terminals & Browsers
brew install --cask alacritty
brew install --cask kitty
brew install --cask arc
### Utils
brew install --cask 1password
brew install --cask 1password-cli
brew install --cask karabiner-elements
brew install --cask alt-tab
brew install --cask setapp
brew install --cask appcleaner
brew install --cask google-cloud-sdk
### Dev
brew install --cask colima
brew install --cask visual-studio-code
brew install --cask visual-studio-code-insiders
brew install --cask jetbrains-toolbox
brew install --cask postman
brew install --cask herd
brew install --cask tinkerwell
brew install --cask helo
brew install --cask dbngin
### Work
brew install --cask microsoft-teams
brew instsal --cask microsoft-office
brew install --cask microsoft-remote-desktop
brew install --cask slack
### Reversing
brew install --cask machoview
brew install --cask hex-fiend
brew install --cask cutter
brew install --cask sloth
### Nice to have
brew install --cask beeper
brew install --cask raycast
brew install --cask krisp
brew install --cask whatsapp
### Fonts
brew install --cask sf-symbols
brew install --cask font-hack-nerd-font
brew install --cask font-jetbrains-mono-nerd-font
brew install --cask font-fira-code-nerd-font
# Mac App Store Apps
echo "Installing App Store apps..."
mas install 1451685025 # Wireguard
mas install 497799835 # Xcode
# macOS Settings
echo "Changing macOS defaults..."
defaults write com.apple.NetworkBrowser BrowseAllInterfaces 1
defaults write com.apple.desktopservices DSDontWriteNetworkStores -bool true
defaults write com.apple.spaces spans-displays -bool false
defaults write com.apple.dock autohide -bool true
defaults write com.apple.dock "mru-spaces" -bool "false"
defaults write NSGlobalDomain NSAutomaticWindowAnimationsEnabled -bool false
defaults write com.apple.LaunchServices LSQuarantine -bool false
defaults write NSGlobalDomain com.apple.swipescrolldirection -bool false
defaults write NSGlobalDomain KeyRepeat -int 1
defaults write NSGlobalDomain NSAutomaticSpellingCorrectionEnabled -bool false
defaults write NSGlobalDomain AppleShowAllExtensions -bool true
defaults write NSGlobalDomain _HIHideMenuBar -bool true
defaults write NSGlobalDomain AppleHighlightColor -string "0.65098 0.85490 0.58431"
defaults write NSGlobalDomain AppleAccentColor -int 1
defaults write com.apple.screencapture location -string "$HOME/Desktop"
defaults write com.apple.screencapture disable-shadow -bool true
defaults write com.apple.screencapture type -string "png"
defaults write com.apple.finder DisableAllAnimations -bool true
defaults write com.apple.finder ShowExternalHardDrivesOnDesktop -bool false
defaults write com.apple.finder ShowHardDrivesOnDesktop -bool false
defaults write com.apple.finder ShowMountedServersOnDesktop -bool false
defaults write com.apple.finder ShowRemovableMediaOnDesktop -bool false
defaults write com.apple.Finder AppleShowAllFiles -bool true
defaults write com.apple.finder FXDefaultSearchScope -string "SCcf"
defaults write com.apple.finder FXEnableExtensionChangeWarning -bool false
defaults write com.apple.finder _FXShowPosixPathInTitle -bool true
defaults write com.apple.finder FXPreferredViewStyle -string "Nlsv"
defaults write com.apple.finder ShowStatusBar -bool false
defaults write com.apple.TimeMachine DoNotOfferNewDisksForBackup -bool YES
defaults write com.apple.Safari AutoOpenSafeDownloads -bool false
defaults write com.apple.Safari IncludeDevelopMenu -bool true
defaults write com.apple.Safari WebKitDeveloperExtrasEnabledPreferenceKey -bool true
defaults write com.apple.Safari com.apple.Safari.ContentPageGroupIdentifier.WebKit2DeveloperExtrasEnabled -bool true
defaults write NSGlobalDomain WebKitDeveloperExtras -bool true
defaults write com.apple.mail AddressesIncludeNameOnPasteboard -bool false
# Set default apps
duti -s com.microsoft.VSCodeInsiders .css all
duti -s com.microsoft.VSCodeInsiders .js all
duti -s com.microsoft.VSCodeInsiders .jsx all
duti -s com.microsoft.VSCodeInsiders .ts all
duti -s com.microsoft.VSCodeInsiders .tsx all
duti -s com.microsoft.VSCodeInsiders .go all
duti -s com.microsoft.VSCodeInsiders .py all
duti -s com.microsoft.VSCodeInsiders .rb all
duti -s com.microsoft.VSCodeInsiders .php all
duti -s com.microsoft.VSCodeInsiders .java all
duti -s com.microsoft.VSCodeInsiders .c all
duti -s com.microsoft.VSCodeInsiders .h all
duti -s com.microsoft.VSCodeInsiders .cpp all
duti -s com.microsoft.VSCodeInsiders .hpp all
duti -s com.microsoft.VSCodeInsiders .rs all
duti -s com.microsoft.VSCodeInsiders .md all
duti -s com.microsoft.VSCodeInsiders .json all
duti -s com.microsoft.VSCodeInsiders .yml all
duti -s com.microsoft.VSCodeInsiders .yaml all
duti -s com.microsoft.VSCodeInsiders .toml all
duti -s com.microsoft.VSCodeInsiders .xml all
duti -s com.microsoft.VSCodeInsiders .svg all
duti -s com.microsoft.VSCodeInsiders .txt all
duti -s com.microsoft.VSCodeInsiders .md all
duti -s com.microsoft.VSCodeInsiders .log all
duti -s com.microsoft.VSCodeInsiders .conf all
duti -s com.microsoft.VSCodeInsiders .ini all
duti -s com.microsoft.VSCodeInsiders .env all
duti -s com.microsoft.VSCodeInsiders .gitignore all
duti -s com.microsoft.VSCodeInsiders .gitattributes all
duti -s com.microsoft.VSCodeInsiders .lock all
# Installing Fonts
git clone [email protected]:shaunsingh/SFMono-Nerd-Font-Ligaturized.git /tmp/SFMono_Nerd_Font
mv /tmp/SFMono_Nerd_Font/* $HOME/Library/Fonts
rm -rf /tmp/SFMono_Nerd_Font/
curl -L https://github.com/kvndrsslr/sketchybar-app-font/releases/download/v1.0.16/sketchybar-app-font.ttf -o $HOME/Library/Fonts/sketchybar-app-font.ttf
# Installing asdf plugins
asdf plugin add bun
asdf install bun latest
asdf plugin add deno
asdf install deno latest
asdf plugin add direnv
asdf direnv setup --shell zsh --version latest
asdf plugin add java
asdf install java latest
asdf plugin add neovim
asdf install neovim latest
asdf plugin add nodejs
asdf install nodejs latest
asdf plugin add pnpm
asdf install pnpm latest
asdf plugin add python
asdf install python latest
source $HOME/.zshrc
cat .zshrc_post_install >> $HOME/.zshrc
cfg config --local status.showUntrackedFiles no
# Start Services
echo "Starting background services..."
brew services start redis
brew services start skhd
yabai --start-service
brew services start sketchybar
brew services start borders
csrutil status
echo "Do not forget to disable SIP..."
echo "Add sudoer manually:\n '$(whoami) ALL = (root) NOPASSWD: sha256:$(shasum -a 256 $(which yabai) | awk "{print \$1;}") $(which yabai) --load-sa' to '/private/etc/sudoers.d/yabai'"
echo "Installation complete...\n"