fish: which function
This commit is contained in:
parent
918c0c33db
commit
ff9cc5976f
@ -16,12 +16,6 @@ set -gx FZF_CTRL_R_OPTS "--preview 'echo {}' --preview-window down:3:hidden:wrap
|
|||||||
set -gx FZF_ALT_C_COMMAND "fd --type=directory --follow"
|
set -gx FZF_ALT_C_COMMAND "fd --type=directory --follow"
|
||||||
set -gx FZF_ALT_C_OPTS "--preview 'tree -CL 1 {}'"
|
set -gx FZF_ALT_C_OPTS "--preview 'tree -CL 1 {}'"
|
||||||
|
|
||||||
# Aliases
|
|
||||||
alias which='type --all --short'
|
|
||||||
function ..; cd ..; end
|
|
||||||
function ...; cd ../..; end
|
|
||||||
function ....; cd ../../..; end
|
|
||||||
|
|
||||||
# Nix package manager
|
# Nix package manager
|
||||||
if test -f ~/.nix-profile/etc/profile.d/nix.sh
|
if test -f ~/.nix-profile/etc/profile.d/nix.sh
|
||||||
for line in (bash -c 'source $0; for name in "${!NIX_@}"; do printf "%s=%s\n" "$name" "${!name}"; done' ~/.nix-profile/etc/profile.d/nix.sh)
|
for line in (bash -c 'source $0; for name in "${!NIX_@}"; do printf "%s=%s\n" "$name" "${!name}"; done' ~/.nix-profile/etc/profile.d/nix.sh)
|
||||||
|
3
fish/functions/which.fish
Normal file
3
fish/functions/which.fish
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
function which --wraps='type --all --short' --description 'alias which=type --all --short'
|
||||||
|
type --all --short $argv
|
||||||
|
end
|
Loading…
x
Reference in New Issue
Block a user