diff --git a/modules/home-manager/profiles/dev.nix b/modules/home-manager/profiles/dev.nix index 1b85cf83..1eb29090 100644 --- a/modules/home-manager/profiles/dev.nix +++ b/modules/home-manager/profiles/dev.nix @@ -88,58 +88,6 @@ in { "ls" "nvim" ]; - bashrcExtra = '' - function f() { - dir=''${1:-$PWD} - dest=$(${pkgs.fd}/bin/fd --type directory --ignore-vcs --base-directory "$dir" \ - | ${pkgs.fzf}/bin/fzf --prompt "Go to directory ") - destPrime=$(${pkgs.coreutils}/bin/realpath --canonicalize-existing --logical "$dir/$dest") - - [ "$dest" ] && cd "$destPrime" - } - - function fh() { - dir=''${1:-$PWD} - dest=$(${pkgs.fd}/bin/fd --type directory --hidden --ignore-vcs --base-directory "$dir" \ - | ${pkgs.fzf}/bin/fzf --prompt "Go to directory ") - destPrime=$(${pkgs.coreutils}/bin/realpath --canonicalize-existing --logical "$dir/$dest") - - [ "$dest" ] && cd "$destPrime" - } - - function ff() { - dir=''${1:-$PWD} - dest=$(${pkgs.fd}/bin/fd --ignore-vcs --base-directory "$dir" \ - | ${pkgs.fzf}/bin/fzf --prompt "Open file ") - destPrime=$(${pkgs.coreutils}/bin/realpath --canonicalize-existing --logical "$dir/$dest") - - if [ -d "$destPrime" ]; then - [ "$dest" ] && cd "$destPrime"; - else - [ "$dest" ] && ${pkgs.xdg-utils}/bin/xdg-open "$destPrime"; - fi - } - - function ffh() { - dir=''${1:-$PWD} - dest=$(${pkgs.fd}/bin/fd --hidden --ignore-vcs --base-directory "$dir" \ - | ${pkgs.fzf}/bin/fzf --prompt "Open file ") - destPrime=$(${pkgs.coreutils}/bin/realpath --canonicalize-existing --logical "$dir/$dest") - - if [ -d "$destPrime" ]; then - [ "$dest" ] && cd "$destPrime"; - else - [ "$dest" ] && ${pkgs.xdg-utils}/bin/xdg-open "$destPrime"; - fi - } - - function fm() { - ${pkgs.man}/bin/man -k . \ - | ${pkgs.fzf}/bin/fzf --multi --prompt "Open manpage(s) " \ - | ${pkgs.gawk}/bin/awk '{ print $1 "." gensub(/[()]/, "", "g", $2) }' \ - | ${pkgs.findutils}/bin/xargs man - } - ''; }; # Supercharging your shell history. Just don't forget to flush them out