From a1f2292470ef3200d4bbeb394b27a3d456267304 Mon Sep 17 00:00:00 2001 From: notohh Date: Sun, 19 Mar 2023 19:31:25 -0400 Subject: [PATCH] feat: init zoxide, add aliases --- home/default.nix | 7 ++++++- home/nushell/config.nu | 19 +++++++++++-------- home/nushell/env.nu | 1 + 3 files changed, 18 insertions(+), 9 deletions(-) diff --git a/home/default.nix b/home/default.nix index a1e7265..36cc0cf 100644 --- a/home/default.nix +++ b/home/default.nix @@ -1,5 +1,6 @@ { default, + pkgs, ... }: { imports = [ @@ -10,5 +11,9 @@ ./git ./lazygit ]; - + + home.packages = with pkgs; [ + bat + zoxide + ]; } \ No newline at end of file diff --git a/home/nushell/config.nu b/home/nushell/config.nu index ac74dc9..8ef706c 100755 --- a/home/nushell/config.nu +++ b/home/nushell/config.nu @@ -1,5 +1,14 @@ # Nushell Config File +source ~/.cache/starship/init.nu +source ~/.zoxide.nu + +alias zj = zellij +alias zjd = zellij --layout ../.config/zellij/snowflake.kdl +alias zjs = zellij --layout ./config/zellij/ssh.kdl +alias lg = lazygit +alias cat = bat + module completions { # Custom completions for external commands (those outside of Nushell) # Each completions has two parts: the form of the external command, including its flags and parameters @@ -264,7 +273,7 @@ let-env config = { } } history: { - max_size: 1000 # Session has to be reloaded for this to take effect + max_size: 10000 # Session has to be reloaded for this to take effect sync_on_enter: true # Enable to share history between multiple sessions, else you have to close the session to write history to file file_format: "plaintext" # "sqlite" or "plaintext" } @@ -534,10 +543,4 @@ let-env config = { ] -} - -source ~/.cache/starship/init.nu - -alias ze = zellij -alias zed = zellij --layout ../.config/zellij/snowflake.kdl -alias zes = zellij --layout ./config/zellij/ssh.kdl +} \ No newline at end of file diff --git a/home/nushell/env.nu b/home/nushell/env.nu index f814424..9dc648b 100755 --- a/home/nushell/env.nu +++ b/home/nushell/env.nu @@ -60,6 +60,7 @@ let-env NU_PLUGIN_DIRS = [ mkdir ~/.cache/starship starship init nu | save -f ~/.cache/starship/init.nu +zoxide init nushell | save -f ~/.zoxide.nu # To add entries to PATH (on Windows you might use Path), you can use the following pattern: # let-env PATH = ($env.PATH | split row (char esep) | prepend '/some/path')