From 41e6afa642285b12066551fde156fae2bb9f22ee Mon Sep 17 00:00:00 2001 From: Gabe Venberg Date: Fri, 17 May 2024 12:00:39 -0500 Subject: [PATCH] added cheatsheet function for zsh. --- modules/home-manager/terminal/zsh.nix | 10 ++++++++++ roles/home-manager/minimal-terminal.nix | 5 ----- roles/home-manager/terminal.nix | 9 --------- 3 files changed, 10 insertions(+), 14 deletions(-) diff --git a/modules/home-manager/terminal/zsh.nix b/modules/home-manager/terminal/zsh.nix index 808c122..68e9aa6 100644 --- a/modules/home-manager/terminal/zsh.nix +++ b/modules/home-manager/terminal/zsh.nix @@ -12,6 +12,9 @@ programs.kitty.shellIntegration.enableZshIntegration = true; services.gpg-agent.enableZshIntegration = true; programs.carapace.enableZshIntegration = false; + home.packages = with pkgs; [ + curl + ]; programs.zsh = { enable = true; enableCompletion = true; @@ -38,6 +41,13 @@ #allow backspacing beyond the point you entered insert mode: bindkey -v '^?' backward-delete-char bindkey "^W" backward-kill-word + + #cheat.sh is a wonderful tool, the less typing needed the better. + cheat(){ + for i in $*; do; + curl cheat.sh/$i + done + } '' (lib.mkIf (!config.programs.starship.enable) '' autoload -U promptinit diff --git a/roles/home-manager/minimal-terminal.nix b/roles/home-manager/minimal-terminal.nix index 02619db..b9b51e1 100644 --- a/roles/home-manager/minimal-terminal.nix +++ b/roles/home-manager/minimal-terminal.nix @@ -20,11 +20,6 @@ curl ]; - # Home Manager is pretty good at managing dotfiles. The primary way to manage - # plain files is through 'home.file'. - home.file = { - }; - home.sessionVariables = { PIPENV_VENV_IN_PROJECT = 1; POETRY_VIRTUALENVS_IN_PROJECT = 1; diff --git a/roles/home-manager/terminal.nix b/roles/home-manager/terminal.nix index 8ffbb16..cdcf81e 100644 --- a/roles/home-manager/terminal.nix +++ b/roles/home-manager/terminal.nix @@ -17,20 +17,11 @@ hyperfine ]; - # Home Manager is pretty good at managing dotfiles. The primary way to manage - # plain files is through 'home.file'. - home.file = { - }; - home.sessionVariables = { PIPENV_VENV_IN_PROJECT = 1; POETRY_VIRTUALENVS_IN_PROJECT = 1; }; - home.shellAliases = { - # doc2pdf = "loffice --convert-to-pdf --headless *.docx"; - }; - programs = { zoxide.enable = true; tealdeer.enable = true;