-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinit.sh
More file actions
65 lines (53 loc) · 2.16 KB
/
init.sh
File metadata and controls
65 lines (53 loc) · 2.16 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
#!/bin/bash
# =============================================================================
# System & Package Manager Setup
# =============================================================================
xcode-select --install
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)" "" --unattended
# =============================================================================
# Homebrew Packages
# =============================================================================
brew tap daipeihust/tap
brew tap laishulu/homebrew
# CLI Tools
brew install wget llvm lld bat jq neovim ripgrep fzf fd starship git-delta eza fnm macism cloc im-select zoxide zsh-history-substring-search lazygit rustup cmake tree-sitter wordnet
brew install zsh zsh-syntax-highlighting zsh-autosuggestions
# Install OpenJDK@21
brew tap sdkman/tap
brew install sdkman-cli
sdk install maven 3.6.3
# GUI Applications & Fonts
brew install --cask font-monaspace-nerd-font visual-studio-code rectangle switchhosts ghostty
# =============================================================================
# Dotfiles Setup
# =============================================================================
git clone git@github.com:xusd320/xsh.git ~/xsh
cd ~/xsh
git submodule update --init
mkdir -p ~/.config
force_link() {
src=$1
dst=$2
rm -rf "$dst"
ln -s "$src" "$dst"
echo "Linked $src -> $dst"
}
force_link ~/xsh/ghostty ~/.config/ghostty
force_link ~/xsh/zshrc ~/.zshrc
force_link ~/xsh/starship.toml ~/.config/starship.toml
force_link ~/xsh/gitconfig ~/.gitconfig
force_link ~/xsh/lazygit ~/.config/lazygit
force_link ~/xsh/bat ~/.config/bat
force_link ~/xsh/nvim ~/.config/nvim
force_link ~/xsh/ripgreprc ~/.ripgreprc
# =============================================================================
# Post-Install Configuration
# =============================================================================
# bat cache
bat cache --build
# Rust Setup
rustup-init -y
sudo chown -R $(whoami) /usr/local/bin
# Rust
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh