Add 'hey search' command

Shortcut for nix search nixpkgs $@
This commit is contained in:
Henrik Lissner 2020-10-11 23:51:23 -04:00
parent 56f545279f
commit b3fee313d0
No known key found for this signature in database
GPG key ID: 5F6C0EA160557395
2 changed files with 5 additions and 2 deletions

View file

@ -10,6 +10,7 @@
# dots u|update -> nix flake update --recreate-lock-file $DOTFILES
# dots re|rebuild -> nixos-rebuild --flake $DOTFILES#$HOSTNAME ${1:-build}
# dots rollback -> dots rebuild --rollback switch
# dots s|search -> nix search nixpkgs $@
# dots vm -> dots rebuild vm
# dots up|upgrade -> dots update && dots rebuild switch
# dots gc -> GC user profile, optimise nix store
@ -92,6 +93,7 @@ function main {
u|update) _update "$@" ;;
up|upgrade) _update && _rebuild switch ;;
s|search) nix search nixpkgs "$@" ;;
gc) _gc "$@" ;;
push)

View file

@ -26,6 +26,7 @@ _hey () {
b|build) _hey_dispatch nix-build ;;
ch|check) _hey_dispatch nix flake check ;;
sh|show) _hey_dispatch nix flake show ;;
s|search) _hey_dispatch nix search nixpkgs ;;
-*) _hey_dispatch nix-env ;;
*) _message "Command not found: ${words[2]}" ;;
esac