From 5e417a6b6c85cfd74e1717a7759fe2b5f40d9462 Mon Sep 17 00:00:00 2001 From: Jonathan Schleifer Date: Sun, 19 Mar 2023 00:28:04 +0000 Subject: [PATCH] Delete fish config as I didn't end up using it --- fish/completions/cross.fish | 27 ---- fish/completions/pkg_delete.fish | 1 - fish/completions/pkg_info.fish | 1 - fish/completions/run.fish | 1 - fish/config.fish | 68 --------- fish/functions/0x0st.fish | 3 - fish/functions/cd.fish | 66 --------- fish/functions/cross.fish | 174 ------------------------ fish/functions/cvsd.fish | 11 -- fish/functions/dlna.fish | 10 -- fish/functions/eps.fish | 4 - fish/functions/fgrep.fish | 7 - fish/functions/fish_prompt.fish | 28 ---- fish/functions/fish_right_prompt.fish | 15 -- fish/functions/fish_title.fish | 3 - fish/functions/fl.fish | 3 - fish/functions/flc.fish | 3 - fish/functions/fld.fish | 11 -- fish/functions/flgrep.fish | 8 -- fish/functions/flpu.fish | 3 - fish/functions/flveri.fish | 7 - fish/functions/grep.fish | 7 - fish/functions/gsftp.fish | 4 - fish/functions/gssh-add.fish | 4 - fish/functions/gssh.fish | 4 - fish/functions/hybrid_bindings.fish | 7 - fish/functions/ixio.fish | 3 - fish/functions/ls.fish | 9 -- fish/functions/make.fish | 15 -- fish/functions/mpv.fish | 5 - fish/functions/pkg_chk.fish | 4 - fish/functions/pkg_rolling-replace.fish | 4 - fish/functions/power_now.fish | 5 - fish/functions/prompt_pwd.fish | 19 --- fish/functions/prompt_user.fish | 5 - fish/functions/pw.fish | 3 - fish/functions/pwnk.fish | 15 -- fish/functions/pws.fish | 3 - fish/functions/run.fish | 9 -- fish/functions/tmux.fish | 3 - fish/functions/uart.fish | 13 -- fish/functions/url2pkg.fish | 5 - fish/functions/vi.fish | 3 - 43 files changed, 603 deletions(-) delete mode 100644 fish/completions/cross.fish delete mode 100644 fish/completions/pkg_delete.fish delete mode 100644 fish/completions/pkg_info.fish delete mode 100644 fish/completions/run.fish delete mode 100644 fish/config.fish delete mode 100644 fish/functions/0x0st.fish delete mode 100644 fish/functions/cd.fish delete mode 100644 fish/functions/cross.fish delete mode 100644 fish/functions/cvsd.fish delete mode 100644 fish/functions/dlna.fish delete mode 100644 fish/functions/eps.fish delete mode 100644 fish/functions/fgrep.fish delete mode 100644 fish/functions/fish_prompt.fish delete mode 100644 fish/functions/fish_right_prompt.fish delete mode 100644 fish/functions/fish_title.fish delete mode 100644 fish/functions/fl.fish delete mode 100644 fish/functions/flc.fish delete mode 100644 fish/functions/fld.fish delete mode 100644 fish/functions/flgrep.fish delete mode 100644 fish/functions/flpu.fish delete mode 100644 fish/functions/flveri.fish delete mode 100644 fish/functions/grep.fish delete mode 100644 fish/functions/gsftp.fish delete mode 100644 fish/functions/gssh-add.fish delete mode 100644 fish/functions/gssh.fish delete mode 100644 fish/functions/hybrid_bindings.fish delete mode 100644 fish/functions/ixio.fish delete mode 100644 fish/functions/ls.fish delete mode 100644 fish/functions/make.fish delete mode 100644 fish/functions/mpv.fish delete mode 100644 fish/functions/pkg_chk.fish delete mode 100644 fish/functions/pkg_rolling-replace.fish delete mode 100644 fish/functions/power_now.fish delete mode 100644 fish/functions/prompt_pwd.fish delete mode 100644 fish/functions/prompt_user.fish delete mode 100644 fish/functions/pw.fish delete mode 100644 fish/functions/pwnk.fish delete mode 100644 fish/functions/pws.fish delete mode 100644 fish/functions/run.fish delete mode 100644 fish/functions/tmux.fish delete mode 100644 fish/functions/uart.fish delete mode 100644 fish/functions/url2pkg.fish delete mode 100644 fish/functions/vi.fish diff --git a/fish/completions/cross.fish b/fish/completions/cross.fish deleted file mode 100644 index d82ca08..0000000 --- a/fish/completions/cross.fish +++ /dev/null @@ -1,27 +0,0 @@ -function __fish_cross_none - if test (count (commandline -opc)) -gt 1 - return 1 - end -end - -function __fish_cross_amiga - set -l cmd (commandline -opc) - - if test (count $cmd) != 2 || test $cmd[2] != "amiga" - return 1 - end -end - -complete -c cross -x -complete -c cross -n __fish_cross_none -x -a 3ds -complete -c cross -n __fish_cross_none -x -a nds -complete -c cross -n __fish_cross_none -x -a amiga -complete -c cross -n __fish_cross_amiga -x -a m68k -complete -c cross -n __fish_cross_amiga -x -a ppc -complete -c cross -n __fish_cross_none -x -a ios -complete -c cross -n __fish_cross_none -x -a iossim -complete -c cross -n __fish_cross_none -x -a mingw -complete -c cross -n __fish_cross_none -x -a morphos -complete -c cross -n __fish_cross_none -x -a switch -complete -c cross -n __fish_cross_none -x -a wii -complete -c cross -n __fish_cross_none -x -a wii-u diff --git a/fish/completions/pkg_delete.fish b/fish/completions/pkg_delete.fish deleted file mode 100644 index 7b5ac2a..0000000 --- a/fish/completions/pkg_delete.fish +++ /dev/null @@ -1 +0,0 @@ -complete -c pkg_delete -x -a "(pkg_info | awk '{ print \$1 }')" diff --git a/fish/completions/pkg_info.fish b/fish/completions/pkg_info.fish deleted file mode 100644 index 46e5192..0000000 --- a/fish/completions/pkg_info.fish +++ /dev/null @@ -1 +0,0 @@ -complete -c pkg_info -x -a "(pkg_info | awk '{ print \$1 }')" diff --git a/fish/completions/run.fish b/fish/completions/run.fish deleted file mode 100644 index 425184a..0000000 --- a/fish/completions/run.fish +++ /dev/null @@ -1 +0,0 @@ -complete -c run -a '(__fish_complete_subcommand)' diff --git a/fish/config.fish b/fish/config.fish deleted file mode 100644 index a04bf39..0000000 --- a/fish/config.fish +++ /dev/null @@ -1,68 +0,0 @@ -set -g fish_greeting -set -g fish_key_bindings hybrid_bindings -set -g fish_escape_delay_ms 300 -set -g fish_cursor_unknown block - -set -g fish_color_autosuggestion 303030 -set -g fish_color_command 205cb3 -set -g fish_color_comment 6600cc -set -g fish_color_cwd 209060 -set -g fish_color_end 730099 -set -g fish_color_host 176945 -set -g fish_color_jobs --bold yellow -set -g fish_color_operator cc6fdf -set -g fish_color_param 3377cf -set -g fish_color_quote ff751a -set -g fish_color_redirection bf4080 -set -g fish_color_search_match ffff00 -set -g fish_color_selection c0c0c0 -set -g fish_color_status --bold red -set -g fish_color_suffix 29bc7d -set -g fish_color_user 00ff00 -set -g fish_color_valid_path normal -set -g fish_color_vcs 43d696 -set -g fish_color_vcs_braces 29bc7d - -set -g fish_normal_user js - -test -n "$XDG_CONFIG_HOME" -or set -x XDG_CONFIG_HOME "$HOME/.config" -test -n "$XDG_CACHE_HOME" -or set -x XDG_CACHE_HOME "$HOME/.cache" -test -n "$XDG_DATA_HOME" -or set -x XDG_DATA_HOME "$HOME/.local/share" - -set -x EDITOR vim -set -x VIMINIT "source $XDG_CONFIG_HOME/vim/vimrc" -set -x LS_COLORS 'di=34:ow=44;37:tw=44;37:st=44;37:ex=31:su=7;31:sg=7;31:ln=33:or=7;33:pi=32:do=32:bd=35:cd=35:so=32:*.bz2=36:*.dmg=36:*.gz=36:*.gpg=36:*.rar=36:*.tar=36:*.tbz2=36:*.tgz=36:*.xz=36:*.zip=36:*.orig=90:*~=90' -set -x SUDO_PROMPT (printf "\033[0;31m[\033[1;31msudo -> %%U\033[0;31m]\033[0m Password for \033[1m%%p@%%H\033[0m: ") -set -x GNUPGHOME "$XDG_DATA_HOME/gnupg" -set -x CVS_RSH ssh - -if type -q gpg2 - alias gpg=gpg2 -end -if type -q gpg - # Make sure the GPG agent is running - gpg --card-status &>/dev/null - - set -l sock - if test -d "$XDG_RUNTIME_DIR/gnupg" - set sock (find $XDG_RUNTIME_DIR/gnupg -name S.gpg-agent.ssh | head -1) - end - if test -z "$sock" - set sock "$GNUPGHOME/S.gpg-agent.ssh" - end - - alias gssh="SSH_AUTH_SOCKET=$sock ssh" - alias gssh-add="SSH_AUTH_SOCKET=$sock ssh-add" - alias gsftp="SSH_AUTH_SOCKET=$sock sftp" -end - -if test (uname -s) = Darwin - set -x MAKEFLAGS -j(math (sysctl -n machdep.cpu.thread_count)'*2') -else if test (uname -s) = NetBSD - set -x MAKEFLAGS -j(math (sysctl -n hw.ncpu)'*2') -else if type -q nproc - set -x MAKEFLAGS -j(math (nproc)'*2') -end diff --git a/fish/functions/0x0st.fish b/fish/functions/0x0st.fish deleted file mode 100644 index 76fd012..0000000 --- a/fish/functions/0x0st.fish +++ /dev/null @@ -1,3 +0,0 @@ -function 0x0st - curl -F'file=@-' https://0x0.st -end diff --git a/fish/functions/cd.fish b/fish/functions/cd.fish deleted file mode 100644 index 72b852e..0000000 --- a/fish/functions/cd.fish +++ /dev/null @@ -1,66 +0,0 @@ -# -# Wrap the builtin cd command to maintain directory history. -# -function cd --description "Change directory" - set -l MAX_DIR_HIST 25 - - if test (count $argv) -gt (test "$argv[1]" = "--" && echo 2 || echo 1) - printf "%s\n" (_ "Too many args for cd command") - return 1 - end - - # Skip history in subshells. - if status --is-command-substitution - builtin cd $argv - return $status - end - - # Avoid set completions. - set -l previous $PWD - - if test "$argv" = "-" - if test "$__fish_cd_direction" = "next" - nextd - else - prevd - end - return $status - end - - # allow explicit "cd ." if the mount-point became stale in the meantime - if test "$argv" = "." - cd "$PWD" - return $status - end - - builtin cd $argv - set -l cd_status $status - - if test $cd_status -eq 0 -a "$PWD" != "$previous" - set -q dirprev - or set -l dirprev - set -q dirprev[$MAX_DIR_HIST] - and set -e dirprev[1] - - # If dirprev, dirnext, __fish_cd_direction - # are set as universal variables, honor their scope. - - set -U -q dirprev - and set -U -a dirprev $previous - or set -g -a dirprev $previous - - set -U -q dirnext - and set -U -e dirnext - or set -e dirnext - - set -U -q __fish_cd_direction - and set -U __fish_cd_direction prev - or set -g __fish_cd_direction prev - end - - if test $cd_status -eq 0 - ls - end - - return $cd_status -end diff --git a/fish/functions/cross.fish b/fish/functions/cross.fish deleted file mode 100644 index 0f42402..0000000 --- a/fish/functions/cross.fish +++ /dev/null @@ -1,174 +0,0 @@ -function cross --description 'Set up cross-compilation environment' - if test (count $argv) = 0 - echo 'Usage: cross platform [architecture1] [architecture2]' - return 1 - end - - switch $argv[1] - case 3ds nds - if test -z "$DEVKITPRO" - echo 'Please set DEVKITPRO!' - return 1 - end - if test -z "$DEVKITARM" - echo 'Please set DEVKITARM!' - return 1 - end - - set PATH $DEVKITARM/bin $PATH - set -g cross_host arm-none-eabi - set -g objfw_configure_flags --with-$argv[1] - case amiga - switch $argv[2] - case m68k - if test -z "$amiga_gcc_path" - echo 'Please set amiga_gcc_path!' - return 1 - end - - set PATH $amiga_gcc_path/bin $PATH - set -g cross_host m68k-amigaos - case ppc - if test -z "$adtools_path" - echo 'Please set adtools_path!' - return 1 - end - - set PATH $adtools_path/bin $PATH - set -g cross_host ppc-amigaos - end - - if test (count $argv) != 2 -o -z "$cross_host" - echo 'Usage: cross amiga m68k|ppc' - return 1 - end - case ios iossim - if not type -q xcrun - echo 'Can only cross-compile for iOS on a Mac with Xcode!' - return 1 - end - - set -l sdk_type - set -l default_archs - switch $argv[1] - case ios - set sdk_type iphoneos - set default_archs arm64 - case iossim - set sdk_type iphonesimulator - set default_archs x86_64 - end - - set -l sdk (xcrun --show-sdk-path --sdk $sdk_type) - set -l archs $argv[2..-1] - - if test (count $archs) = 0 - set archs $default_archs - end - - set -gx CC clang -isysroot $sdk - set -gx CPP clang -E -isysroot $sdk - set -gx CXX clang++ -isysroot $sdk - set -gx CXXPP clang++ -E -isysroot $sdk - - for arch in $archs - set -a CC -arch $arch - set -a CXX -arch $arch - end - set -a CPP -arch $archs[1] - set -a CXXPP -arch $archs[1] - - set -gx OBJC $CC - set -gx OBJCPP $CPP - set -gx OBJCXX $CXX - set -gx OBJCPPXX $CXXPP - set -gx IPHONEOS_DEPLOYMENT_TARGET 10.0 - set -g cross_host $archs[1]-apple-darwin - case macos - if test -z "$retro68_path" - echo 'Please set retro68_path!' - return 1 - end - - set PATH $retro68_path/bin $PATH - - switch $argv[2] - case m68k - set -g cross_host m68k-apple-macos - case ppc - set -g cross_host powerpc-apple-macos - end - - if test (count $argv) != 2 -o -z "$cross_host" - echo 'Usage: cross macos m68k|ppc' - return 1 - end - case mingw - set -l pkg - switch $argv[2] - case i686 x86_64 - set pkg mingw-w64-$argv[2]-gcc - set -g cross_host $argv[2]-w64-mingw32 - end - - if test (count $argv) != 2 -o -z "$cross_host" - echo 'Usage: cross mingw i686|x86_64' - return 1 - end - - set -l prefix (pkg_info -qp $pkg | awk '/^@cwd/ { print $2; exit }') - - if test -z "$prefix" - echo 'Please install $pkg from pkgsrc!' - return 1 - end - - set PATH $prefix/cross/$cross_host/bin $PATH - case morphos - set -l prefix (pkg_info -qp ppc-morphos-gcc-11 | - awk '/^@cwd/ { print $2; exit }') - - if test -z "$prefix" - echo 'Please install ppc-morphos-gcc-9 from pkgsrc!' - return 1 - end - - set PATH $prefix/gg/bin $PATH - set -gx CC ppc-morphos-gcc-11 - set -gx CXX ppc-morphos-g++-11 - set -gx OBJC ppc-morphos-gcc-11 - set -gx OBJCXX ppc-morphos-g++-11 - set -g cross_host ppc-morphos - case switch - if test -z "$DEVKITPRO" - echo 'Please set DEVKITPRO!' - return 1 - end - if test -z "$DEVKITA64" - echo 'Please set DEVKITA64!' - return 1 - end - - set PATH $DEVKITA64/bin $DEVKITPRO/tools/bin $PATH - set -g cross_host aarch64-none-elf - set -g objfw_configure_flags --with-nintendo-switch - case wii wii-u - if test -z "$DEVKITPRO" - echo 'Please set DEVKITPRO!' - return 1 - end - if test -z "$DEVKITPPC" - echo 'Please set DEVKITPPC!' - return 1 - end - - set PATH $DEVKITPPC/bin $DEVKITPRO/tools/bin $PATH - set -g cross_host powerpc-eabi - set -g objfw_configure_flags --with-$argv[1] - case '*' - echo "Unknown target: $argv[1]" - return 1 - end - - set -g objfw_configure_flags --host=$cross_host $objfw_configure_flags -end diff --git a/fish/functions/cvsd.fish b/fish/functions/cvsd.fish deleted file mode 100644 index f7d2fc4..0000000 --- a/fish/functions/cvsd.fish +++ /dev/null @@ -1,11 +0,0 @@ -function cvsd --wraps 'cvs diff' - if type -q colordiff - command cvs diff -uN $argv | colordiff | less -FRX - else - set -l red (printf "\033[31m") - set -l green (printf "\033[32m") - set -l reset (printf "\033[0m") - cvs diff -uN $argv | sed "s/^+.*\$/$green&$reset/" | - sed "s/^-.*\$/$red&$reset/" | less -FRX - end -end diff --git a/fish/functions/dlna.fish b/fish/functions/dlna.fish deleted file mode 100644 index ea971e0..0000000 --- a/fish/functions/dlna.fish +++ /dev/null @@ -1,10 +0,0 @@ -function dlna - set -l cmd minidlnad -d -R - set -a cmd -f $XDG_CONFIG_HOME/minidlna/minidlna.conf - set -a cmd -P $XDG_DATA_HOME/minidlna/minidlna.pid - - type -q caffeinate - set cmd caffeinate $cmd - - eval $cmd -end diff --git a/fish/functions/eps.fish b/fish/functions/eps.fish deleted file mode 100644 index 665d77e..0000000 --- a/fish/functions/eps.fish +++ /dev/null @@ -1,4 +0,0 @@ -function eps --description 'Expand, print and set variable $e' - set -g e $argv - echo $e -end diff --git a/fish/functions/fgrep.fish b/fish/functions/fgrep.fish deleted file mode 100644 index 9dac9ae..0000000 --- a/fish/functions/fgrep.fish +++ /dev/null @@ -1,7 +0,0 @@ -function fgrep - if type -q ggrep - command ggrep -F --color=auto $argv - else - command fgrep --color=auto $argv - end -end diff --git a/fish/functions/fish_prompt.fish b/fish/functions/fish_prompt.fish deleted file mode 100644 index 449de48..0000000 --- a/fish/functions/fish_prompt.fish +++ /dev/null @@ -1,28 +0,0 @@ -function fish_prompt --description 'Write out the prompt' - set -l suffix - switch "$USER" - case root toor - set suffix (set_color $fish_color_cwd_root)'#' - case '*' - set suffix '>' - end - - set -l branch (fossil branch current 2>/dev/null) - - if test -z "$branch" - set branch (git symbolic-ref HEAD 2>/dev/null) - set branch (string replace -r "^refs/heads/" "" $branch) - end - - set -l vcs - if test -n "$branch" - set vcs (set_color $fish_color_vcs_braces)"(" \ - (set_color $fish_color_vcs)"$branch" \ - (set_color $fish_color_vcs_braces)")" - end - - echo -n -s (set_color $fish_color_host) (prompt_user) (prompt_hostname) \ - ' ' (set_color $fish_color_cwd) (prompt_pwd) \ - (string join '' $vcs) (set_color $fish_color_suffix) $suffix \ - (set_color normal) ' ' -end diff --git a/fish/functions/fish_right_prompt.fish b/fish/functions/fish_right_prompt.fish deleted file mode 100644 index 87196f3..0000000 --- a/fish/functions/fish_right_prompt.fish +++ /dev/null @@ -1,15 +0,0 @@ -function fish_right_prompt - set -l code $status - set -l jobs (jobs | wc -l) - set -l prompt - - test $jobs -gt 0 - and set -a prompt (set_color $fish_color_jobs)$jobs - - test $code -gt 0 - and set -a prompt (set_color $fish_color_status)$code - - echo $prompt - - set_color normal -end diff --git a/fish/functions/fish_title.fish b/fish/functions/fish_title.fish deleted file mode 100644 index a8f2b85..0000000 --- a/fish/functions/fish_title.fish +++ /dev/null @@ -1,3 +0,0 @@ -function fish_title - echo (status current-command) · (prompt_pwd) · (prompt_hostname) -end diff --git a/fish/functions/fl.fish b/fish/functions/fl.fish deleted file mode 100644 index 133c9f1..0000000 --- a/fish/functions/fl.fish +++ /dev/null @@ -1,3 +0,0 @@ -function fl --wraps=fossil - command fossil $argv -end diff --git a/fish/functions/flc.fish b/fish/functions/flc.fish deleted file mode 100644 index 8d898cf..0000000 --- a/fish/functions/flc.fish +++ /dev/null @@ -1,3 +0,0 @@ -function flc --wraps='fossil changes --differ' - command fossil changes --differ $argv -end diff --git a/fish/functions/fld.fish b/fish/functions/fld.fish deleted file mode 100644 index fef9d09..0000000 --- a/fish/functions/fld.fish +++ /dev/null @@ -1,11 +0,0 @@ -function fld --wraps 'fossil diff' - if type -q colordiff - command fossil diff -N $argv | colordiff | less -FRX - else - set -l red (printf "\033[31m") - set -l green (printf "\033[32m") - set -l reset (printf "\033[0m") - fossil diff -N $argv | sed "s/^+.*\$/$green&$reset/" | - sed "s/^-.*\$/$red&$reset/" | less -FRX - end -end diff --git a/fish/functions/flgrep.fish b/fish/functions/flgrep.fish deleted file mode 100644 index 16a1cb4..0000000 --- a/fish/functions/flgrep.fish +++ /dev/null @@ -1,8 +0,0 @@ -function flgrep - set -l ret - fossil changes --all . | awk '{ print $2 }' | while read file - grep -H $argv "$file" && set ret 0 - test $status -gt 1 && return $status - end - return $ret -end diff --git a/fish/functions/flpu.fish b/fish/functions/flpu.fish deleted file mode 100644 index 50e2f95..0000000 --- a/fish/functions/flpu.fish +++ /dev/null @@ -1,3 +0,0 @@ -function flpu --wraps='fossil update' - fossil pull && fossil update $argv -end diff --git a/fish/functions/flveri.fish b/fish/functions/flveri.fish deleted file mode 100644 index cd53db5..0000000 --- a/fish/functions/flveri.fish +++ /dev/null @@ -1,7 +0,0 @@ -function flveri - if not set -q argv[1] - set argv[1] current - end - echo -e "\033[1m$argv[1]\033[0m" - fossil artifact "$argv[1]" | gpg --verify -end diff --git a/fish/functions/grep.fish b/fish/functions/grep.fish deleted file mode 100644 index 8585fa3..0000000 --- a/fish/functions/grep.fish +++ /dev/null @@ -1,7 +0,0 @@ -function grep - if type -q ggrep - command ggrep --color=auto $argv - else - command grep --color=auto $argv - end -end diff --git a/fish/functions/gsftp.fish b/fish/functions/gsftp.fish deleted file mode 100644 index c6cb07d..0000000 --- a/fish/functions/gsftp.fish +++ /dev/null @@ -1,4 +0,0 @@ -function gsftp --wraps sftp - set -lx SSH_AUTH_SOCK $GNUPGHOME/S.gpg-agent.ssh - sftp -o IdentitiesOnly=no $argv -end diff --git a/fish/functions/gssh-add.fish b/fish/functions/gssh-add.fish deleted file mode 100644 index ad7991e..0000000 --- a/fish/functions/gssh-add.fish +++ /dev/null @@ -1,4 +0,0 @@ -function gssh-add --wraps ssh-add - set -lx SSH_AUTH_SOCK $GNUPGHOME/S.gpg-agent.ssh - ssh-add $argv -end diff --git a/fish/functions/gssh.fish b/fish/functions/gssh.fish deleted file mode 100644 index 3c8fda6..0000000 --- a/fish/functions/gssh.fish +++ /dev/null @@ -1,4 +0,0 @@ -function gssh --wraps ssh - set -lx SSH_AUTH_SOCK $GNUPGHOME/S.gpg-agent.ssh - ssh -o IdentitiesOnly=no $argv -end diff --git a/fish/functions/hybrid_bindings.fish b/fish/functions/hybrid_bindings.fish deleted file mode 100644 index 5b3e07e..0000000 --- a/fish/functions/hybrid_bindings.fish +++ /dev/null @@ -1,7 +0,0 @@ -function hybrid_bindings --description 'Vi-style bindings that inherit emacs-style bindings in all modes' - for mode in default insert visual - fish_default_key_bindings -M $mode - end - - fish_vi_key_bindings --no-erase -end diff --git a/fish/functions/ixio.fish b/fish/functions/ixio.fish deleted file mode 100644 index 2a7b237..0000000 --- a/fish/functions/ixio.fish +++ /dev/null @@ -1,3 +0,0 @@ -function ixio - curl -F 'f:1=<-' ix.io -end diff --git a/fish/functions/ls.fish b/fish/functions/ls.fish deleted file mode 100644 index 0a2103c..0000000 --- a/fish/functions/ls.fish +++ /dev/null @@ -1,9 +0,0 @@ -if type -q gls - function ls --description 'List contents of directory' - command gls --color=auto $argv - end -else if command ls --color=auto &>/dev/null - function ls --description 'List contents of directory' - command ls --color=auto $argv - end -end diff --git a/fish/functions/make.fish b/fish/functions/make.fish deleted file mode 100644 index 8fc83e5..0000000 --- a/fish/functions/make.fish +++ /dev/null @@ -1,15 +0,0 @@ -# Automatically use bmake instead of make when using pkgsrc, if necessary -function make - if string match -q -r '/pkgsrc$|/pkgsrc/' $PWD - # pkgsrc does not like MAKEFLAGS including -j - set -lx MAKEFLAGS - - if type -q bmake - command bmake $argv - else - command make $argv - end - else - command make $argv - end -end diff --git a/fish/functions/mpv.fish b/fish/functions/mpv.fish deleted file mode 100644 index f0ef0b6..0000000 --- a/fish/functions/mpv.fish +++ /dev/null @@ -1,5 +0,0 @@ -# To work around mpv not liking locales that use , as a decimal separator -function mpv - set -lx LC_ALL C - command mpv $argv -end diff --git a/fish/functions/pkg_chk.fish b/fish/functions/pkg_chk.fish deleted file mode 100644 index de0a9af..0000000 --- a/fish/functions/pkg_chk.fish +++ /dev/null @@ -1,4 +0,0 @@ -function pkg_chk - set -lx MAKEFLAGS - command pkg_chk $argv -end diff --git a/fish/functions/pkg_rolling-replace.fish b/fish/functions/pkg_rolling-replace.fish deleted file mode 100644 index 3837421..0000000 --- a/fish/functions/pkg_rolling-replace.fish +++ /dev/null @@ -1,4 +0,0 @@ -function pkg_rolling-replace - set -lx MAKEFLAGS - command pkg_rolling-replace $argv -end diff --git a/fish/functions/power_now.fish b/fish/functions/power_now.fish deleted file mode 100644 index bbf80ed..0000000 --- a/fish/functions/power_now.fish +++ /dev/null @@ -1,5 +0,0 @@ -if test -f /sys/class/power_supply/BAT0/power_now - function power_now - awk '{ print $1*10^-6 " W" }' /sys/class/power_supply/BAT0/power_now - end -end diff --git a/fish/functions/prompt_pwd.fish b/fish/functions/prompt_pwd.fish deleted file mode 100644 index c92a960..0000000 --- a/fish/functions/prompt_pwd.fish +++ /dev/null @@ -1,19 +0,0 @@ -function prompt_pwd --description 'Print the current working directory' - set -l options 'h/help' - argparse -n prompt_pwd --max-args=0 $options -- $argv - or return - - if set -q _flag_help - __fish_print_help prompt_pwd - return 0 - end - - # Replace $HOME with "~" - set realhome ~ - set -l tmp (basename (string replace -r '^'"$realhome"'($|/)' '~$1' $PWD)) - - test $PWD = "/$tmp" - and set tmp $PWD - - echo $tmp -end diff --git a/fish/functions/prompt_user.fish b/fish/functions/prompt_user.fish deleted file mode 100644 index 3cab0df..0000000 --- a/fish/functions/prompt_user.fish +++ /dev/null @@ -1,5 +0,0 @@ -function prompt_user - if test (whoami) != "$fish_normal_user" - echo (whoami)"@" - end -end diff --git a/fish/functions/pw.fish b/fish/functions/pw.fish deleted file mode 100644 index 936ca6b..0000000 --- a/fish/functions/pw.fish +++ /dev/null @@ -1,3 +0,0 @@ -function pw --wraps pwnk - pwnk -k ~/.cryptopassphrase.key $argv -end diff --git a/fish/functions/pwnk.fish b/fish/functions/pwnk.fish deleted file mode 100644 index f8c045f..0000000 --- a/fish/functions/pwnk.fish +++ /dev/null @@ -1,15 +0,0 @@ -function pwnk - set -l clipboard - if type -q wl-copy - set clipboard wl-copy - else if type -q pbcopy - set clipboard pbcopy - else if type -q xclip - set clipboard xclip - else - echo "No clipboard handler found!" - return 1 - end - - cryptopassphrase $argv | tr -d '\n' | $clipboard -end diff --git a/fish/functions/pws.fish b/fish/functions/pws.fish deleted file mode 100644 index cc0f8b6..0000000 --- a/fish/functions/pws.fish +++ /dev/null @@ -1,3 +0,0 @@ -function pws --wraps pwnk - pwnk -k ~/.cryptopassphrase-server.key $argv -end diff --git a/fish/functions/run.fish b/fish/functions/run.fish deleted file mode 100644 index 9add662..0000000 --- a/fish/functions/run.fish +++ /dev/null @@ -1,9 +0,0 @@ -function run - if test (count $argv) = 0 - echo "Usage: run command" - return 1 - end - - $argv & - disown -end diff --git a/fish/functions/tmux.fish b/fish/functions/tmux.fish deleted file mode 100644 index eec9527..0000000 --- a/fish/functions/tmux.fish +++ /dev/null @@ -1,3 +0,0 @@ -function tmux - command tmux -f $XDG_CONFIG_HOME/tmux/tmux.conf $argv -end diff --git a/fish/functions/uart.fish b/fish/functions/uart.fish deleted file mode 100644 index c711fdb..0000000 --- a/fish/functions/uart.fish +++ /dev/null @@ -1,13 +0,0 @@ -switch (uname -s) - case Linux - function uart - if not set -q argv[1] - set argv[1] 115200 - end - if not set -q argv[2] - set argv[2] 0 - end - screen /dev/ttyUSB"$argv[2]" "$argv[1]" - end - end -end diff --git a/fish/functions/url2pkg.fish b/fish/functions/url2pkg.fish deleted file mode 100644 index 805f8cd..0000000 --- a/fish/functions/url2pkg.fish +++ /dev/null @@ -1,5 +0,0 @@ -# pkgsrc does not like MAKEFLAGS being set -function url2pkg - set -lx MAKEFLAGS - command url2pkg $argv -end diff --git a/fish/functions/vi.fish b/fish/functions/vi.fish deleted file mode 100644 index 27b8033..0000000 --- a/fish/functions/vi.fish +++ /dev/null @@ -1,3 +0,0 @@ -function vi --wraps=vim - command vim $argv -end