From c896e02bf16f760ca0eaa05677406ed95011d3ea Mon Sep 17 00:00:00 2001 From: Julian Mutter Date: Thu, 22 Jan 2026 06:56:06 +0100 Subject: [PATCH] Allow unfree packages with "run" and "shell" commands --- homes/julian/features/fish/default.nix | 4 ++-- homes/julian/global/default.nix | 5 +++++ 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/homes/julian/features/fish/default.nix b/homes/julian/features/fish/default.nix index 226bc74..63fe542 100644 --- a/homes/julian/features/fish/default.nix +++ b/homes/julian/features/fish/default.nix @@ -43,14 +43,14 @@ with lib; { cd $argv ''; run = '' - nix run nixpkgs#"$argv[1]" -- $argv[2..-1] + nix run --impure nixpkgs#"$argv[1]" -- $argv[2..-1] ''; shell = '' set args for arg in $argv set args $args nixpkgs#$arg end - nix shell $args + nix shell --impure $args ''; fish_user_key_bindings = '' bind ctrl-space 'zi; commandline -f repaint' diff --git a/homes/julian/global/default.nix b/homes/julian/global/default.nix index ea41ebd..642edb0 100644 --- a/homes/julian/global/default.nix +++ b/homes/julian/global/default.nix @@ -24,6 +24,11 @@ }; }; + # To allow unfree with 'nix run' + xdg.configFile."nixpkgs/config.nix".text = '' + { allowUnfree = true; } + ''; + colorscheme.name = "catppuccin-mocha"; # systemd.user.startServices = "sd-switch"; # TODO: what is this