From 55577615e283fdb425175c5e607df3feecc8d9c9 Mon Sep 17 00:00:00 2001 From: Noah Masur <7386960+nmasur@users.noreply.github.com> Date: Mon, 25 Apr 2022 20:34:33 -0400 Subject: [PATCH] ignore patterns in home-manager --- nixos/home.nix | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/nixos/home.nix b/nixos/home.nix index 34541cd..3d28bfa 100644 --- a/nixos/home.nix +++ b/nixos/home.nix @@ -9,6 +9,18 @@ let nixos_config = builtins.toString ./.; notes_path = "$HOME/dev/personal/notes"; + ignore_patterns = '' + !.env* + !.github/ + !.gitignore + !*.tfvars + .terraform/ + .target/ + /Library/ + keybase/ + kbfs/ + ''; + in { nixpkgs.config.allowUnfree = true; @@ -283,10 +295,13 @@ in { "direnvrc".text = "source $HOME/.nix-profile/share/nix-direnv/direnvrc"; "spectrwm/spectrwm.conf".source = ./spectrwm.conf; }; + home.file = { + ".rgignore".text = ignore_patterns; + ".fdignore".text = ignore_patterns; + }; programs.direnv = { enable = true; - enableFishIntegration = true; nix-direnv.enable = true; config = { whitelist = { prefix = [ "${dotfiles}/" ]; }; }; };