-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathwork-setup.sh
More file actions
executable file
·136 lines (103 loc) · 3.37 KB
/
Copy pathwork-setup.sh
File metadata and controls
executable file
·136 lines (103 loc) · 3.37 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
#!/bin/zsh
set -eo pipefail
if [[ $# > 0 && $1=="--dry-run" ]]; then
echo "Running in dry run mode, no action"
exit 0
fi
# oh-my-zsh
if [[ -z ${ZSH+x} ]]; then
echo "Installing Oh My Zsh"
sh -c "$(curl -fsSL https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh)" "" --unattended --keep-zshrc
else
echo "Oh My Zsh already present, skipping..."
fi
# homebrew
if ! xcode-select -p > /dev/null; then
xcode-select --install
fi
if [[ $(command -v brew) == "" ]]; then
echo "Installing brew"
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
else
echo "brew already present, updating..."
brew update && brew upgrade
fi
# starship
brew install starship
brew install --cask font-fira-code-nerd-font
cp starship.toml ~/.config/starship.toml
# git
brew install git git-gui
brew install --cask git-credential-manager
brew install delta
brew install jesseduffield/lazygit/lazygit
cp lazygit.yml "$(lazygit -cd)/config.yml"
# gh (github cli)
brew install gh
git config --global user.email "andre.lameirinhas@gmail.com"
git config --global user.name "André Lameirinhas"
git config --global pull.rebase true
git config --global rerere.enabled true
git config --global column.ui auto
git config --global branch.sort -committerdate
git config --global rebase.updateRefs true
git config --global core.pager delta
git config --global interactive.diffFilter 'delta --color-only'
git config --global delta.navigate true
git config --global delta.line-numbers true
git config --global merge.conflictStyle zdiff3
git config --global diff.colorMoved default
# dops (better docker ps)
brew tap mikescher/tap && brew install dops
# fzf
brew install fzf
$(brew --prefix)/opt/fzf/install --key-bindings --completion --no-update-rc
# z
if [[ ! -f ~/z.sh ]]; then
echo "Installing z"
curl -o ~/z.sh https://raw.githubusercontent.com/rupa/z/master/z.sh
else
echo "z already present, skipping..."
fi
# claude code
curl -fsSL https://claude.ai/install.sh | bash
# nvm
PROFILE=/dev/null bash -c 'curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.1/install.sh | bash'
# bat (cat clone with wings)
brew install bat
# fd (find alternative)
brew install fd
# eza (modern ls)
brew install eza
# nvim
brew install neovim
# gcloud
brew install google-cloud-sdk
gcloud components install gke-gcloud-auth-plugin
# watch
brew install watch
# glow (markdown reader)
brew install glow
# htop (process viewer)
brew install htop
# fastfetch
brew install fastfetch
# xan (CSV magician)
brew install xan
# rg (faster and better grep)
brew install ripgrep
# mole (macos maintenance)
brew install mole
# rtk (token-optimized CLI proxy for Claude Code)
brew install rtk
rtk init -g --auto-patch
source languages.sh
# casks
brew install --adopt --casks iterm2 visual-studio-code docker rectangle opera raycast meetingbar dbeaver-community bruno libreoffice vlc
echo "Finished initial installation. Generating and sourcing .zshrc"
sed -i "" "1s/^/PYTHON_INSTALLED=$PYTHON_INSTALLED\n/" zshrc
sed -i "" "1s/^/RUBY_INSTALLED=$RUBY_INSTALLED\n/" zshrc
awk 'BEGIN {cmd = "readlink -f scripts/coffee.sh" cmd | getline coffee_loc close(cmd)} /aliases/ {print; print "alias coffee=" coffee_loc; next}1' zshrc > ~/.zshrc
source ~/.zshrc
# add brew-upgrader to crontab
(crontab -l; echo "0 8 * * * $(readlink -f scripts/brew-upgrader.sh)") | sort -u | crontab -