-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinstall.sh
More file actions
executable file
·50 lines (36 loc) · 1.09 KB
/
Copy pathinstall.sh
File metadata and controls
executable file
·50 lines (36 loc) · 1.09 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
#!/usr/bin/env bash
set -euo pipefail
RED='\033[0;31m'
GREEN='\033[0;32m'
YELLOW='\033[1;33m'
BLUE='\033[0;34m'
NC='\033[0m'
info() {
printf "${BLUE}==>${NC} %s\n" "$1"
}
success() {
printf "${GREEN}==>${NC} %s\n" "$1"
}
warn() {
printf "${YELLOW}==>${NC} %s\n" "$1"
}
error() {
printf "${RED}==>${NC} %s\n" "$1"
}
DOTFILES_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
if ! command -v brew >/dev/null 2>&1; then
error "Homebrew is not installed. Install Homebrew first: https://brew.sh"
exit 1
fi
info "Installing Homebrew dependencies from Brewfile"
brew bundle --file="$DOTFILES_DIR/Brewfile"
info "Ensuring config directories exist"
mkdir -p "$HOME/.config/ghostty"
info "Linking zsh configuration"
ln -sf "$DOTFILES_DIR/zsh/.zshrc" "$HOME/.zshrc"
ln -sf "$DOTFILES_DIR/zsh/.zsh_plugins.txt" "$HOME/.zsh_plugins.txt"
info "Linking Ghostty configuration"
ln -sf "$DOTFILES_DIR/ghostty/config" "$HOME/.config/ghostty/config"
info "Linking Starship configuration"
ln -sf "$DOTFILES_DIR/starship/starship.toml" "$HOME/.config/starship.toml"
success "Dotfiles installation complete"