From af531ba974d6878f1aea047981946e81856f7c66 Mon Sep 17 00:00:00 2001 From: Michal Sojka Date: Fri, 31 Mar 2023 15:07:58 +0200 Subject: [PATCH] Configure the Cachix binary cache in flake.nix With this, Flake users will be automatically asked whether they want to use the binary cache and its key. If they answer yes, the cache will be automatically used without any needed configuration. Additionally, the users will be asked whether they want to mark this settings as permanent. In that case the cache will be used automatically in the future without any interaction. This means that when anybody runs a command like this: nix shell github:lopsided98/nix-ros-overlay#humble.rviz2 they will automatically get the packages from the binary cache. --- flake.nix | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/flake.nix b/flake.nix index c5da70d076..d8ed2e4bbb 100644 --- a/flake.nix +++ b/flake.nix @@ -27,4 +27,10 @@ "'nix-ros-overlay.nixosModule' is deprecated, use 'nix-ros-overlay.nixosModules.default' instead" self.nixosModules.default; }; + + nixConfig = { + extra-substituters = [ "https://ros.cachix.org" ]; + extra-trusted-public-keys = [ "ros.cachix.org-1:dSyZxI8geDCJrwgvCOHDoAfOm5sV1wCPjBkKL+38Rvo=" ]; + }; + }