From 092d0cd0979aa2130cc4c9705244fcfd232a075e Mon Sep 17 00:00:00 2001 From: Andrejus Date: Sun, 28 Mar 2021 18:32:01 +0100 Subject: [PATCH] fix: bump fish deps, clean up profile, drop fishlogin --- files/.bash_profile | 1 - files/.bashrc | 1 - files/.config/fish/config.fish | 7 +++--- files/.config/fish/fishfile | 10 ++++----- files/.config/fish/functions/nvm.fish | 2 +- files/.profile | 32 +++++++++++++-------------- install/02-fish.sh | 13 ----------- 7 files changed, 25 insertions(+), 41 deletions(-) diff --git a/files/.bash_profile b/files/.bash_profile index 4bfc7d0..0a45628 100644 --- a/files/.bash_profile +++ b/files/.bash_profile @@ -8,4 +8,3 @@ # References: # https://unix.stackexchange.com/questions/192521/loading-profile-from-bash-profile-or-not-using-bash-profile-at-all # https://www.stefaanlippens.net/my_bashrc_aliases_profile_and_other_stuff/ -if [ -e /home/andrejus/.nix-profile/etc/profile.d/nix.sh ]; then . /home/andrejus/.nix-profile/etc/profile.d/nix.sh; fi # added by Nix installer diff --git a/files/.bashrc b/files/.bashrc index 58dfd7c..7871ed1 100644 --- a/files/.bashrc +++ b/files/.bashrc @@ -1,4 +1,3 @@ [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm [ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion - [ -f ~/.fzf.bash ] && source ~/.fzf.bash diff --git a/files/.config/fish/config.fish b/files/.config/fish/config.fish index 16be849..5698cff 100644 --- a/files/.config/fish/config.fish +++ b/files/.config/fish/config.fish @@ -1,9 +1,10 @@ +# Only execute in interactive shell if status --is-interactive # Cross-shell setup - if begin; test -e ~/.bash_profile; and type -q bax; end - bax "source ~/.bash_profile" + if begin; test -e $HOME/.profile; and type -q replay; end + replay "source $HOME/.profile" end - + # Fish specific set fish_greeting if type -q base16-seti diff --git a/files/.config/fish/fishfile b/files/.config/fish/fishfile index 6fd64bd..dda3f6a 100644 --- a/files/.config/fish/fishfile +++ b/files/.config/fish/fishfile @@ -1,8 +1,6 @@ -fishpkg/fish-prompt-mono -tomyun/base16-fish -gazorby/fish-abbreviation-tips -oh-my-fish/plugin-license -matchai/fish-mock -jorgebucaran/fish-bax jethrokuan/z +jorgebucaran/replay.fish +jorgebucaran/hydro joseluisq/gitnow +tomyun/base16-fish +PatrickF1/fzf.fish diff --git a/files/.config/fish/functions/nvm.fish b/files/.config/fish/functions/nvm.fish index 244dbb1..8da3971 100644 --- a/files/.config/fish/functions/nvm.fish +++ b/files/.config/fish/functions/nvm.fish @@ -1,3 +1,3 @@ function nvm - bax source $NVM_DIR/nvm.sh ';' nvm $argv + replay source $NVM_DIR/nvm.sh ';' nvm $argv end diff --git a/files/.profile b/files/.profile index 15dba21..423d858 100644 --- a/files/.profile +++ b/files/.profile @@ -1,10 +1,10 @@ -# U _____ u _ _ __ __ -# \| ___"|/| \ |"| \ \ /"/u -# | _|" <| \| |> \ \ / // -# | |___ U| |\ |u /\ V /_,-. -# |_____| |_| \_| U \_/-(_/ -# << >> || \\,-.// -# (__) (__)(_") (_/(__) +# U _____ u _ _ __ __ +# \| ___"|/| \ |"| \ \ /"/u +# | _|" <| \| |> \ \ / // +# | |___ U| |\ |u /\ V /_,-. +# |_____| |_| \_| U \_/-(_/ +# << >> || \\,-.// +# (__) (__)(_") (_/(__) # # set PATH so it includes user's private bin export PATH="$HOME/bin:$PATH" @@ -65,16 +65,16 @@ export FZF_DEFAULT_COMMAND='fdfind --type f --hidden --follow --exclude .git' export FZF_CTRL_T_COMMAND="$FZF_DEFAULT_COMMAND" export FZF_COMPLETION_TRIGGER='**' -# do not use fishlogin for subshells -export SHELL=/bin/sh +# nix +if [ -e ~/.nix-profile/etc/profile.d/nix.sh ]; then . ~/.nix-profile/etc/profile.d/nix.sh; fi - # _ _ _ ____ -# U /"\ u |"| ___ U /"\ u / __"| u -# \/ _ \/ U | | u |_"_| \/ _ \/ <\___ \/ -# / ___ \ \| |/__ | | / ___ \ u___) | -# /_/ \_\ |_____| U/| |\u /_/ \_\ |____/>> -# \\ >> // \\.-,_|___|_,-.\\ >> )( (__) -# (__) (__)(_")("_)\_)-' '-(_/(__) (__)(__) +# _ _ _ ____ +# U /"\ u |"| ___ U /"\ u / __"| u +# \/ _ \/ U | | u |_"_| \/ _ \/ <\___ \/ +# / ___ \ \| |/__ | | / ___ \ u___) | +# /_/ \_\ |_____| U/| |\u /_/ \_\ |____/>> +# \\ >> // \\.-,_|___|_,-.\\ >> )( (__) +# (__) (__)(_")("_)\_)-' '-(_/(__) (__)(__) # alias vim='nvim' alias vi='vim' diff --git a/install/02-fish.sh b/install/02-fish.sh index ca0ee60..cbb017c 100755 --- a/install/02-fish.sh +++ b/install/02-fish.sh @@ -20,16 +20,3 @@ echo "fisher is installed, updating..." `fish -c "fisher"`; fish -c "fisher --version" - -if not_installed "fishlogin"; then - echo "setting up fishlogin..." - mkdir -p ~/bin - target="$HOME/bin/fishlogin" - tee -a $target << END -#!/bin/bash -exec -l fish "\$@" -END - sudo chmod +x $target - echo $target | sudo tee -a /etc/shells - sudo usermod -s $target $USER -fi