From 3844a9a533cf20ae193c6028e7d17c6822ece4a6 Mon Sep 17 00:00:00 2001 From: qwjyh Date: Mon, 3 Oct 2022 03:27:48 +0900 Subject: [PATCH 1/4] new: config.fish & ln script --- bin/install.sh | 1 + dotfiles/fish/config.fish | 23 +++++++++++++++++++++++ 2 files changed, 24 insertions(+) create mode 100644 bin/install.sh create mode 100644 dotfiles/fish/config.fish diff --git a/bin/install.sh b/bin/install.sh new file mode 100644 index 0000000..cabc0ff --- /dev/null +++ b/bin/install.sh @@ -0,0 +1 @@ +ln -s (pwd)/dotfiles/fish/config.fish ~/.config/fish/config.fish diff --git a/dotfiles/fish/config.fish b/dotfiles/fish/config.fish new file mode 100644 index 0000000..8347384 --- /dev/null +++ b/dotfiles/fish/config.fish @@ -0,0 +1,23 @@ +# load .bashrc +bass source ~/.bashrc + +# ssh-agent +if not keychain + source $HOME/.keychain/DESKTOP-6DPNBNH-fish + ssh-add ~/.ssh/id_rsa_eccs + ssh-add ~/.ssh/id_ed25519 +end + +# opam configuration +#source /home/urata/.opam/opam-init/init.fish > /dev/null 2> /dev/null; or true +# deleted + +# key bindings +bind \b backward-kill-word + +# starship +starship init fish | source +#function set_win_title +# echo -ne "\033]0; (basename "$PWD") \007" +#end +#set tarship_precmd_uesr_func "set_win_title" From c04d5e6dbb168bd23dd9c61de53e25ba6a76db1d Mon Sep 17 00:00:00 2001 From: qwjyh Date: Mon, 3 Oct 2022 03:29:33 +0900 Subject: [PATCH 2/4] add: fish :ssh-agent evaluation --- dotfiles/fish/config.fish | 3 +++ 1 file changed, 3 insertions(+) diff --git a/dotfiles/fish/config.fish b/dotfiles/fish/config.fish index 8347384..6b23632 100644 --- a/dotfiles/fish/config.fish +++ b/dotfiles/fish/config.fish @@ -7,6 +7,9 @@ if not keychain ssh-add ~/.ssh/id_rsa_eccs ssh-add ~/.ssh/id_ed25519 end +# https://wiki.archlinux.jp/index.php/Fish#ssh-agent_.E3.81.AE.E8.A9.95.E4.BE.A1 +eval (ssh-agent -c) + # opam configuration #source /home/urata/.opam/opam-init/init.fish > /dev/null 2> /dev/null; or true From fe8217cff43a73a849fe176e76bc359bfba12f72 Mon Sep 17 00:00:00 2001 From: qwjyh Date: Thu, 6 Oct 2022 23:20:40 +0900 Subject: [PATCH 3/4] fix: fish keychain --- dotfiles/fish/config.fish | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/dotfiles/fish/config.fish b/dotfiles/fish/config.fish index 6b23632..e147f7d 100644 --- a/dotfiles/fish/config.fish +++ b/dotfiles/fish/config.fish @@ -2,14 +2,11 @@ bass source ~/.bashrc # ssh-agent -if not keychain - source $HOME/.keychain/DESKTOP-6DPNBNH-fish - ssh-add ~/.ssh/id_rsa_eccs - ssh-add ~/.ssh/id_ed25519 +if status --is-interactive + set -x SHELL fish + keychain --eval --quiet -Q id_rsa, id_ed25519 | source + set -x SHELL bash end -# https://wiki.archlinux.jp/index.php/Fish#ssh-agent_.E3.81.AE.E8.A9.95.E4.BE.A1 -eval (ssh-agent -c) - # opam configuration #source /home/urata/.opam/opam-init/init.fish > /dev/null 2> /dev/null; or true From a5be748c5d6cd81fd25d02959e740bc9624299e0 Mon Sep 17 00:00:00 2001 From: qwjyh Date: Thu, 6 Oct 2022 23:34:12 +0900 Subject: [PATCH 4/4] update: fish: opam init --- dotfiles/fish/config.fish | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/dotfiles/fish/config.fish b/dotfiles/fish/config.fish index acbf87c..09b6f19 100644 --- a/dotfiles/fish/config.fish +++ b/dotfiles/fish/config.fish @@ -14,10 +14,11 @@ if status is-interactive set -x SHELL fish keychain --eval --quiet -Q id_rsa, id_ed25519 | source set -x SHELL bash + + # opam + # source ~/.opam/opam-init/init.fish > /dev/null 2> /dev/null; or true end -# opam -# source ~/.opam/opam-init/init.fish > /dev/null 2> /dev/null; or true # key bindings bind \b backward-kill-word \ No newline at end of file