From 7b8e76860c5b9ec70612907c0d8818b14e8dab22 Mon Sep 17 00:00:00 2001 From: Michael Mandl Date: Wed, 10 Jul 2024 08:28:44 +0200 Subject: [PATCH] refactor: extract common config files --- horsch/bat.nix => bat.nix | 0 horsch/carapace.nix => carapace.nix | 0 horsch/direnv.nix => direnv.nix | 0 horsch/eza.nix => eza.nix | 0 private/fzf.nix => fzf.nix | 0 horsch/fzf.nix | 10 ---------- horsch/home.nix | 16 ++++++++-------- private/bat.nix | 13 ------------- private/carapace.nix | 8 -------- private/direnv.nix | 11 ----------- private/home.nix | 16 ++++++++-------- private/starship.nix | 11 ----------- private/zoxide.nix | 9 --------- horsch/ripgrep.nix => ripgrep.nix | 0 horsch/starship.nix => starship.nix | 0 horsch/zoxide.nix => zoxide.nix | 0 16 files changed, 16 insertions(+), 78 deletions(-) rename horsch/bat.nix => bat.nix (100%) rename horsch/carapace.nix => carapace.nix (100%) rename horsch/direnv.nix => direnv.nix (100%) rename horsch/eza.nix => eza.nix (100%) rename private/fzf.nix => fzf.nix (100%) delete mode 100644 horsch/fzf.nix delete mode 100644 private/bat.nix delete mode 100644 private/carapace.nix delete mode 100644 private/direnv.nix delete mode 100644 private/starship.nix delete mode 100644 private/zoxide.nix rename horsch/ripgrep.nix => ripgrep.nix (100%) rename horsch/starship.nix => starship.nix (100%) rename horsch/zoxide.nix => zoxide.nix (100%) diff --git a/horsch/bat.nix b/bat.nix similarity index 100% rename from horsch/bat.nix rename to bat.nix diff --git a/horsch/carapace.nix b/carapace.nix similarity index 100% rename from horsch/carapace.nix rename to carapace.nix diff --git a/horsch/direnv.nix b/direnv.nix similarity index 100% rename from horsch/direnv.nix rename to direnv.nix diff --git a/horsch/eza.nix b/eza.nix similarity index 100% rename from horsch/eza.nix rename to eza.nix diff --git a/private/fzf.nix b/fzf.nix similarity index 100% rename from private/fzf.nix rename to fzf.nix diff --git a/horsch/fzf.nix b/horsch/fzf.nix deleted file mode 100644 index 0e83315..0000000 --- a/horsch/fzf.nix +++ /dev/null @@ -1,10 +0,0 @@ -{ config, lib, pkgs, user, ... }: - -{ - programs = { - fzf = { - enable = true; - enableZshIntegration = true; - }; - }; -} diff --git a/horsch/home.nix b/horsch/home.nix index 1364f46..0af011e 100644 --- a/horsch/home.nix +++ b/horsch/home.nix @@ -18,23 +18,23 @@ ]; imports = [ - ./bat.nix - ./carapace.nix - ./direnv.nix - ./eza.nix - ./fzf.nix + ../bat.nix + ../carapace.nix + ../direnv.nix + ../eza.nix + ../fzf.nix + ../ripgrep.nix + ../starship.nix + ../zoxide.nix ./git.nix ./gpg ./neovim ./picocom.nix ./podman.nix - ./ripgrep.nix ./rsync.nix ./shell_aliases.nix ./ssh.nix - ./starship.nix ./tree.nix - ./zoxide.nix ./zsh.nix ]; } diff --git a/private/bat.nix b/private/bat.nix deleted file mode 100644 index 6583e65..0000000 --- a/private/bat.nix +++ /dev/null @@ -1,13 +0,0 @@ -{ theme, ... }: - -let - theme_name = "Solarized (${theme})"; -in -{ - programs = { - bat = { - enable = true; - config.theme = theme_name; - }; - }; -} diff --git a/private/carapace.nix b/private/carapace.nix deleted file mode 100644 index 2705a18..0000000 --- a/private/carapace.nix +++ /dev/null @@ -1,8 +0,0 @@ -{ ... }: -{ - programs.carapace = { - enable = true; - enableZshIntegration = true; - }; -} - diff --git a/private/direnv.nix b/private/direnv.nix deleted file mode 100644 index 005868d..0000000 --- a/private/direnv.nix +++ /dev/null @@ -1,11 +0,0 @@ -{ ... }: - -{ - programs = { - direnv = { - enable = true; - enableZshIntegration = true; - nix-direnv.enable = true; - }; - }; -} diff --git a/private/home.nix b/private/home.nix index 45080d4..cbef863 100644 --- a/private/home.nix +++ b/private/home.nix @@ -7,10 +7,8 @@ home.stateVersion = "24.05"; # Please read the comment before changing. home.packages = with pkgs; [ - eza jq htop - ripgrep pavucontrol gnumake unzip @@ -57,19 +55,21 @@ programs.home-manager.enable = true; imports = [ - ./bat.nix - ./carapace.nix - ./direnv.nix + ../bat.nix + ../carapace.nix + ../direnv.nix + ../eza.nix + ../fzf.nix + ../ripgrep.nix + ../starship.nix + ../zoxide.nix ./firefox.nix - ./fzf.nix ./git.nix ./gpg ./kitty.nix ./neovim ./nextcloud.nix - ./starship.nix ./sway - ./zoxide.nix ./zsh.nix ]; } diff --git a/private/starship.nix b/private/starship.nix deleted file mode 100644 index 4cdc31f..0000000 --- a/private/starship.nix +++ /dev/null @@ -1,11 +0,0 @@ -{ lib, ... }: - -{ - programs.starship = { - enable = true; - settings = { - format = lib.concatStrings [ "$all" "$directory" "$character" ]; - hostname.format = "[$ssh_symbol$hostname]($style) "; - }; - }; -} diff --git a/private/zoxide.nix b/private/zoxide.nix deleted file mode 100644 index 435b381..0000000 --- a/private/zoxide.nix +++ /dev/null @@ -1,9 +0,0 @@ -{ ... }: - -{ - programs.zoxide = { - enable = true; - enableZshIntegration = true; - }; -} - diff --git a/horsch/ripgrep.nix b/ripgrep.nix similarity index 100% rename from horsch/ripgrep.nix rename to ripgrep.nix diff --git a/horsch/starship.nix b/starship.nix similarity index 100% rename from horsch/starship.nix rename to starship.nix diff --git a/horsch/zoxide.nix b/zoxide.nix similarity index 100% rename from horsch/zoxide.nix rename to zoxide.nix