-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsetup
executable file
·49 lines (37 loc) · 1.31 KB
/
setup
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
#!/bin/bash
# Set up XDG_CONFIG_HOME
export XDG_CONFIG_HOME="$HOME"/.config
mkdir -p "$XDG_CONFIG_HOME"
mkdir -p "$XDG_CONFIG_HOME"/nixpkgs
# Create symlinks for existing configurations
ln -sf "$PWD/nvim" "$XDG_CONFIG_HOME"/nvim
ln -sf "$PWD/.inputrc" "$HOME"/.inputrc
ln -sf "$PWD/.tmux.conf" "$HOME"/.tmux.conf
ln -sf "$PWD/config.nix" "$XDG_CONFIG_HOME"/nixpkgs/config.nix
# Fetch and set up Zsh configuration files from my main dotfiles repo
curl -o "$HOME/.zshrc" https://raw.githubusercontent.com/mischavandenburg/dotfiles/main/.zshrc
curl -o "$HOME/.zprofile" https://raw.githubusercontent.com/mischavandenburg/dotfiles/main/.zprofile
# Install Nix packages from config.nix
nix-env -iA nixpkgs.myPackages
### brew installation way
# # Nix is broken due to timeouts, falling back to brew
# packages=(
# fd
# ripgrep
# npm
# lazygit
# fzf
# )
#
# # Iterate over the array and install each package
# for package in "${packages[@]}"; do
# echo "Installing $package..."
# /home/linuxbrew/.linuxbrew/bin/brew install "$package"
# done
echo "All packages have been installed."
# Set up pure prompt
mkdir -p "$HOME/.zsh"
git clone https://github.com/sindresorhus/pure.git "$HOME/.zsh/pure"
# Silence source warning
touch "$HOME/.privaterc"
echo "Setup complete. Zsh configuration files have been downloaded and set up."