- Update & split scripts - Main package install script - Fish / environment install script - Dockerfile for testing locally
73 lines
1.8 KiB
Bash
Executable File
73 lines
1.8 KiB
Bash
Executable File
#!/bin/fish
|
|
|
|
set PYTHON_VERSION 3.11.6
|
|
set NODE_VERSION lts/hydrogen
|
|
|
|
# dont run as root/sudo
|
|
if [ "$EUID" -eq 0 ]
|
|
then echo "Please do not run as root / sudo"
|
|
exit 1
|
|
end
|
|
|
|
# install rust toolchain
|
|
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
|
|
|
|
# install pyenv
|
|
git clone https://github.com/pyenv/pyenv.git $HOME/.pyenv
|
|
|
|
# install nvm
|
|
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/master/install.sh | bash
|
|
|
|
# install fzf from source
|
|
git clone --depth 1 https://github.com/junegunn/fzf.git ~/.fzf
|
|
bash ~/.fzf/install --no-update-rc --completion --key-bindings
|
|
|
|
# install fisher
|
|
curl -sL https://raw.githubusercontent.com/jorgebucaran/fisher/main/functions/fisher.fish | source && fisher install jorgebucaran/fisher
|
|
|
|
# copy fish config
|
|
if test -f "~/.config/fish/functions/config.fish"; then
|
|
echo "config.fish already exist, please rename to continue."
|
|
exit 1
|
|
end
|
|
cp fish/config.fish ~/.config/fish/
|
|
|
|
# copy fishfile
|
|
if test -f "~/.config/fish/fish_plugins"; then
|
|
echo "fish_plugins already exist, please rename to continue."
|
|
exit 1
|
|
end
|
|
cp fish/fish_plugins ~/.config/fish/
|
|
|
|
# setup pyenv, cargo + local bin paths in fish
|
|
mkdir $HOME/.local/bin
|
|
set -Ux PYENV_ROOT $HOME/.pyenv
|
|
fish_add_path $PYENV_ROOT/bin
|
|
fish_add_path $HOME/.local/bin
|
|
fish_add_path $HOME/.cargo/bin
|
|
|
|
# install packages from fishfile
|
|
fisher update
|
|
|
|
cp -R fish/theme-t31m/functions/* ~/.config/fish/functions/
|
|
|
|
# install node via nvm
|
|
nvm install $NODE_VERSION
|
|
nvm alias default $NODE_VERSION
|
|
|
|
# Install Python
|
|
pyenv install $PYTHON_VERSION
|
|
# pip install --upgrade pip
|
|
|
|
# Install pipx for future non-user local packages
|
|
pipx ensurepath
|
|
|
|
# pipx completions
|
|
pipx completions
|
|
register-python-argcomplete --shell fish pipx >~/.config/fish/completions/pipx.fish
|
|
|
|
# cp vimrc
|
|
echo "Installing .vimrc"
|
|
cp dot.vimrc $HOME/.vimrc
|
|
|