diff --git a/configs/.zshrc b/configs/.zshrc index 950ab74..c746378 100644 --- a/configs/.zshrc +++ b/configs/.zshrc @@ -50,6 +50,7 @@ alias timestamp='date -u +%FT%TZ' alias yt-dlp-opus="yt-dlp -f 251 -x" alias ltcp="cp ~/.dotfiles/latex_template/{macros,preamble,template,letterfonts}.tex ." alias jekyll_export="jekyll b -d ./_archive && cd _archive && tar cf ../site.tar ./ && cd .. && gzip -9 -f site.tar && rm -rf _archive" +alias rebuild="sudo nixos-rebuild switch --flake path:/etc/nixos --impure" # ffmpeg section diff --git a/init_nix b/init_nix new file mode 100644 index 0000000..02608f4 --- /dev/null +++ b/init_nix @@ -0,0 +1,11 @@ +#!/bin/sh +set -e + +if ! command -v git &> /dev/null +then + echo "git should be installed" + exit 255 +fi + +git clone https://github.com/ivabus/dotfiles $HOME/.dotfiles +exec sh $HOME/.dotfiles/tools/install_nix.sh < /dev/tty diff --git a/tools/install_nix.sh b/tools/install_nix.sh new file mode 100755 index 0000000..b017aa4 --- /dev/null +++ b/tools/install_nix.sh @@ -0,0 +1,12 @@ +#/bin/sh +set -e + +mkdir $HOME/.config +./relink.sh +mkdir -p $HOME/.dotfiles/zsh/{plugins,themes} +ZSH="$HOME/.dotfiles/zsh" +echo "Installing zsh theme and plugins" +curl -fsSL https://raw.githubusercontent.com/ivabus/ivabus-zsh-theme/master/ivabus.zsh-theme -o $HOME/.dotfiles/zsh/themes/ivabus.zsh-theme +git clone https://github.com/zsh-users/zsh-syntax-highlighting.git $HOME/.dotfiles/zsh/plugins/zsh-syntax-highlighting +curl -fLo "${XDG_DATA_HOME:-$HOME/.local/share}"/nvim/site/autoload/plug.vim --create-dirs https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim +nvim -c :PlugInstall -c :q -c :q