-
Notifications
You must be signed in to change notification settings - Fork 3
/
install.sh
executable file
·104 lines (77 loc) · 2.59 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
#!/bin/bash
# Inspiration:
# - http://fredkelly.net/articles/2014/10/19/developing_on_yosemite.html
# - https://github.com/sorenvind/dev-env
# - https://github.com/mads-hartmann/dotfiles
set -euo pipefail
PREFIX='>'
# Set up OS settings
echo "$PREFIX Setting up OS settings..."
./mac-os/configure-macos.sh
./mac-os/configure-dock.sh
sudo xcode-select --install || true
# Install homebrew
export HOMEBREW_NO_ENV_HINTS=true
if test ! $(which brew)
then
echo "$PREFIX Installing brew..."
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"
brew doctor
fi
# up the limit for files opened
sudo launchctl limit maxfiles 2048 unlimited
echo "$PREFIX Brew: updating and upgrading..."
brew update
brew upgrade
brew tap homebrew/cask-fonts
echo "$PREFIX Brew: tapping..."
for module in `cat brew-packages.list`; do
brew install "$module"
done
for module in `cat brew-casks.list`; do
brew install --cask "$module"
done
# Install oh-my-zsh
OMZ=~/.oh-my-zsh
if test ! -d $OMZ
then
echo "> Installing oh my zsh..."
curl -L http://install.ohmyz.sh | sh
fi
mkdir -p $OMZ/completions
echo "$PREFIX Install global python packages..."
pip3 install --quiet virtualenv pylint flake8
echo "$PREFIX Setup symlinks for dotfiles and shell stuff..."
# Symlink dot files
ln -fs $PWD/home/.zshrc ~
ln -fs $PWD/home/.ssh/config ~/.ssh
# install node 20
nvm install v20
# install poetry
curl -sSL https://install.python-poetry.org | python3 -
# Install bun
curl -fsSL https://bun.sh/install | bash
bun completions
# move .gitconfig without e-mail
cp ./home/.gitconfig ~
# And oh my zsh theme
mkdir -p ~/.oh-my-zsh/themes/
ln -fs $PWD/skovhus.zsh-theme ~/.oh-my-zsh/themes/skovhus.zsh-theme
echo "$PREFIX Setting up VS Code..."
mkdir -p ~/Library/Application\ Support/Code/User
ln -fs $PWD/apps/vs-code/settings.json ~/Library/Application\ Support/Code/User
ln -fs $PWD/apps/vs-code/keybindings.json ~/Library/Application\ Support/Code/User
for module in `cat apps/vs-code/extensions.list`; do
code --install-extension "$module" || true
done
echo "$PREFIX Done!"
echo "-----------------------------------------"
echo "Manual steps:"
echo "-----------------------------------------"
echo "- Setup terminal to import solarized.terminal profile"
echo "- Add e-mail to ~/.gitconfig"
echo "- Fix all issues from running brew doctor"
echo "- Restart"
echo "- Set up short cuts http://apple.stackexchange.com/questions/167967/creating-system-wide-keyboard-shortcut-to-launch-applications"
echo "- Install Moom from App Store"
echo "- Configure moom, log in to Dropbox, Chrome, jumpcut, raycast..."