summaryrefslogtreecommitdiff
path: root/home/ebisu/meta/system/shell/fish
diff options
context:
space:
mode:
authorFuwn <[email protected]>2024-08-28 20:36:04 -0700
committerFuwn <[email protected]>2024-08-28 20:36:04 -0700
commitf3c31e4ad7fab36e151f3a2e207fafb1eda1a787 (patch)
treee265a1a5270b4522049110b8bc5aa13fda142c2f /home/ebisu/meta/system/shell/fish
parentmany (diff)
downloadnixos-config-f3c31e4ad7fab36e151f3a2e207fafb1eda1a787.tar.xz
nixos-config-f3c31e4ad7fab36e151f3a2e207fafb1eda1a787.zip
hi
Diffstat (limited to 'home/ebisu/meta/system/shell/fish')
-rw-r--r--home/ebisu/meta/system/shell/fish/default.nix149
1 files changed, 149 insertions, 0 deletions
diff --git a/home/ebisu/meta/system/shell/fish/default.nix b/home/ebisu/meta/system/shell/fish/default.nix
new file mode 100644
index 0000000..55f441d
--- /dev/null
+++ b/home/ebisu/meta/system/shell/fish/default.nix
@@ -0,0 +1,149 @@
+{ pkgs, ... }: {
+ programs.fish = {
+ enable = true;
+
+ shellInit = ''
+ if status is-interactive
+ set fish_greeting
+
+ fish_vi_key_bindings
+
+ function fish_postexec --on-event fish_postexec
+ if test "$argv" != "clear"
+ echo
+ end
+ end
+
+ function vpn
+ env BIND_INTERFACE=wgpia0 LD_PRELOAD=/usr/lib/bindToInterface.so $argv
+ end
+ end
+
+ set -l config_home (set -q XDG_CONFIG_HOME; and echo $XDG_CONFIG_HOME; or echo $HOME/.config)
+
+ set HISTSIZE -1
+ set HISTFILESIZE -1
+ set SAVEHIST -1
+
+ source "$config_home/shell/profile"
+ bass source "~/.nix-profile/etc/profile.d/hm-session-vars.sh"
+
+ bind \ce edit_command_buffer
+
+ zoxide init fish | source
+
+ cat ~/.cache/wal/sequences
+
+ starship init fish | source
+ '';
+
+ plugins = [
+ {
+ name = "fzf.fish";
+
+ src = pkgs.fetchFromGitHub {
+ owner = "patrickf1";
+ repo = "fzf.fish";
+ rev = "8920367cf85eee5218cc25a11e209d46e2591e7a";
+ sha256 = "sha256-T8KYLA/r/gOKvAivKRoeqIwE2pINlxFQtZJHpOy9GMM=";
+ };
+ }
+ {
+ name = "bass";
+
+ src = pkgs.fetchFromGitHub {
+ owner = "edc";
+ repo = "bass";
+ rev = "79b62958ecf4e87334f24d6743e5766475bcf4d0";
+ sha256 = "sha256-3d/qL+hovNA4VMWZ0n1L+dSM1lcz7P5CQJyy+/8exTc=";
+ };
+ }
+ {
+ name = "nvm.fish";
+
+ src = pkgs.fetchFromGitHub {
+ owner = "jorgebucaran";
+ repo = "nvm.fish";
+ rev = "b8edb1ee24cbbf7259196b0cb3c6c4ab65b07929";
+ sha256 = "sha256-7JxIQSseBv81SSpWH1pufx8fh9EQhbo3r2nVVREwc58=";
+ };
+ }
+ {
+ name = "sponge";
+
+ src = pkgs.fetchFromGitHub {
+ owner = "meaningful-ooo";
+ repo = "sponge";
+ rev = "384299545104d5256648cee9d8b117aaa9a6d7be";
+ sha256 = "sha256-MdcZUDRtNJdiyo2l9o5ma7nAX84xEJbGFhAVhK+Zm1w=";
+ };
+ }
+ {
+ name = "autopair.fish";
+
+ src = pkgs.fetchFromGitHub {
+ owner = "jorgebucaran";
+ repo = "autopair.fish";
+ rev = "4d1752ff5b39819ab58d7337c69220342e9de0e2";
+ sha256 = "sha256-qt3t1iKRRNuiLWiVoiAYOu+9E7jsyECyIqZJ/oRIT1A=";
+ };
+ }
+ ];
+
+ shellAliases = {
+ # Verbosity
+ cp = "cp -iv";
+ mv = "mv -iv";
+ # rm = "rm -vI";
+ bc = "bc -ql";
+ rsync = "rsync -vrPlu";
+ mkd = "mkdir -pv";
+ yt = "yt-dlp --embed-metadata -i";
+ yta = "yt -x -f bestaudio/best";
+ ytt = "yt --skip-download --write-thumbnail";
+ ffmpeg = "ffmpeg -hide_banner";
+ wdic = "wdic --homophones --kanji --color --pager";
+ hakuneko = "hakuneko-desktop --no-sandbox";
+ fastfetch = "clear && /usr/bin/env fastfetch";
+
+ # Modern Alternatives & Alias Rewrites
+ sxiv = "nsxiv";
+ unzip = "ripunzip unzip-file";
+ nvim = "lvim";
+ vim = "lvim";
+ vimdiff = "lvim -d";
+ rm = "rip";
+
+ # Colourise
+ ls = "exa -h --no-quotes --color=auto --group-directories-first";
+ grep = "grep --color=auto";
+ diff = "diff --color=auto";
+ ccat = "highlight --out-format=ansi";
+ ip = "ip -color=auto";
+
+ # Abbreviations
+ ka = "killall";
+ g = "git";
+ sdn = "shutdown -h now";
+ e = "$EDITOR";
+ v = "$EDITOR";
+ ff = "fastfetch";
+
+ # Other
+ pacbins = "comm -23 <(yay -Qqett | sort) <(yay -Qqg base -g base-devel | sort | uniq)";
+ chan = "chan-downloader -c 10";
+ taiga = "bottles-cli run -b Taiga -p Taiga";
+ rotd = "systemctl --user restart opentabledriver.service";
+ ks = "kaguya stream --user-agent 'Mozilla/5.0 (X11; Linux x86_64; rv:120.0) Gecko/20100101 Firefox/120.0'";
+ def = "myougiden";
+ suzuri = "SUZURI_MINIMAL=1 SUZURI_REVERSE=1 ~/Documents/Code/Git/Fuwn/suzuri/suzuri";
+ "5ch" = "html2md -i 'https://ff5ch.syoboi.jp/' -s section | glow";
+ shinobu = "curl --silent https://shinobu.fuwn.workers.dev/shinobu -o /tmp/shinobu && nsxiv /tmp/shinobu";
+ auto_subtitle = "source $HOME/Documents/Code/Git/Random/auto-subtitle/venv/bin/activate && auto_subtitle --model medium --task translate --srt_only True";
+ steamy = "mangohud gamemoderun steam-runtime";
+ koix = "koi -f";
+ seamonkey = "$HOME/.local/src/seamonkey/seamonkey-bin";
+ doom = "$HOME/.config/emacs/bin/doom";
+ };
+ };
+}