From d7faff39013cd7fef6ef22a2dfb759db0dddd90e Mon Sep 17 00:00:00 2001 From: pazpi Date: Fri, 13 Sep 2024 13:32:21 +0200 Subject: [PATCH] New modules for Home Manager --- modules/home/default.nix | 9 ++++++ modules/home/direnv.nix | 8 ++++++ modules/home/git.nix | 7 +++++ modules/home/kitty.nix | 37 ++++++++++++++++++++++++ modules/home/packages.nix | 59 +++++++++++++++++++++++++++++++++++++++ modules/home/starship.nix | 13 +++++++++ 6 files changed, 133 insertions(+) create mode 100644 modules/home/default.nix create mode 100644 modules/home/direnv.nix create mode 100644 modules/home/git.nix create mode 100644 modules/home/kitty.nix create mode 100644 modules/home/packages.nix create mode 100644 modules/home/starship.nix diff --git a/modules/home/default.nix b/modules/home/default.nix new file mode 100644 index 0000000..3f52cf2 --- /dev/null +++ b/modules/home/default.nix @@ -0,0 +1,9 @@ +{ + imports = [ + ./direnv.nix + ./git.nix + ./kitty.nix + ./packages.nix + ./starship.nix + ]; +} diff --git a/modules/home/direnv.nix b/modules/home/direnv.nix new file mode 100644 index 0000000..6571e48 --- /dev/null +++ b/modules/home/direnv.nix @@ -0,0 +1,8 @@ +{ ... }: +{ + programs.direnv = { + enable = true; + nix-direnv.enable = true; + }; + +} diff --git a/modules/home/git.nix b/modules/home/git.nix new file mode 100644 index 0000000..b87c057 --- /dev/null +++ b/modules/home/git.nix @@ -0,0 +1,7 @@ +{ ... }: +{ + programs.git = { + enable = true; + delta.enable = true; + }; +} diff --git a/modules/home/kitty.nix b/modules/home/kitty.nix new file mode 100644 index 0000000..77c86bc --- /dev/null +++ b/modules/home/kitty.nix @@ -0,0 +1,37 @@ +{ ... }: +{ + programs.kitty = { + + enable = true; + font.name = "Iosevka"; + + keybindings = { + "alt+c" = "copy_to_clipboard"; + "alt+v" = "paste_from_clipboard"; + "kitty_mod+enter" = "new_window_with_cwd"; + "kitty_mod+left" = "previous_window"; + "kitty_mod+right" = "next_window"; + "kitty_mod+shift+left" = "next_tab"; + "kitty_mod+shift+right" = "previous_tab"; + "kitty_mod+shift+r" = "new_window ranger"; + "kitty_mod+shift+t" = "set_tab_title"; + "kitty_mod+q" = "close_tab"; + "kitty_mod+t" = "new_tab"; + }; + + settings = { + # kitty_mod = "ctrl+shift"; + kitty_mod = "alt"; + scrollback_lines = 10000; + enable_audio_bell = false; + update_check_interval = 0; + copy_on_select = true; + draw_minimal_borders = true; + }; + + shellIntegration.enableZshIntegration = true; + + theme = "Catppuccin-Macchiato"; + + }; +} diff --git a/modules/home/packages.nix b/modules/home/packages.nix new file mode 100644 index 0000000..b3cbcc2 --- /dev/null +++ b/modules/home/packages.nix @@ -0,0 +1,59 @@ +{ pkgs, ... }: +{ + + # Packages that should be installed to the user profile. + home.packages = with pkgs; [ + + superfile # terminal file manager + + # archives + peazip + + # utils + ripgrep # recursively searches directories for a regex pattern + jq # A lightweight and flexible command-line JSON processor + eza # A modern replacement for ‘ls’ + fzf # A command-line fuzzy finder + + # networking tools + iperf3 + dnsutils # `dig` + `nslookup` + ldns # replacement of `dig`, it provide the command `drill` + aria2 # A lightweight multi-protocol & multi-source command-line download utility + nmap # A utility for network discovery and security auditing + ipcalc # it is a calculator for the IPv4/v6 addresses + + # misc + file + which + tree + gnused + gnutar + gawk + zstd + gnupg + + # nix related + # + # it provides the command `nom` works just like `nix` + # with more details log output + nix-output-monitor + + btop # replacement of htop/nmon + iotop # io monitoring + iftop # network monitoring + + # system call monitoring + strace # system call monitoring + ltrace # library call monitoring + lsof # list open files + + # system tools + sysstat + lm_sensors # for `sensors` command + ethtool + pciutils # lspci + usbutils # lsusb + ]; + +} diff --git a/modules/home/starship.nix b/modules/home/starship.nix new file mode 100644 index 0000000..85edc3f --- /dev/null +++ b/modules/home/starship.nix @@ -0,0 +1,13 @@ +{ ... }: +{ + programs.starship = { + enable = true; + # custom settings + settings = { + add_newline = false; + aws.disabled = true; + gcloud.disabled = true; + line_break.disabled = true; + }; + }; +}