From fefa4d8c5938c4e74b6eb01c6fb8379548c20ab4 Mon Sep 17 00:00:00 2001 From: Timothy DeHerrera Date: Sat, 9 Jul 2022 09:09:37 -0700 Subject: [PATCH] nix flake: make the binary cache "just work" (#2999) --- book/src/install.md | 8 ++++++-- flake.nix | 5 +++++ 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/book/src/install.md b/book/src/install.md index 3006c389..ea46976f 100644 --- a/book/src/install.md +++ b/book/src/install.md @@ -22,8 +22,12 @@ the project root. The flake can also be used to spin up a reproducible developme shell for working on Helix with `nix develop`. Flake outputs are cached for each push to master using -[Cachix](https://www.cachix.org/). With Cachix -[installed](https://docs.cachix.org/installation), `cachix use helix` will +[Cachix](https://www.cachix.org/). The flake is configured to +automatically make use of this cache assuming the user accepts +the new settings on first use. + +If you are using a version of Nix without flakes enabled you can +[install Cachix cli](https://docs.cachix.org/installation); `cachix use helix` will configure Nix to use cached outputs when possible. ### Arch Linux diff --git a/flake.nix b/flake.nix index c8bd02aa..d0d454af 100644 --- a/flake.nix +++ b/flake.nix @@ -96,4 +96,9 @@ }; }; }; + + nixConfig = { + extra-substituters = ["https://helix.cachix.org"]; + extra-trusted-public-keys = ["helix.cachix.org-1:ejp9KQpR1FBI2onstMQ34yogDm4OgU2ru6lIwPvuCVs="]; + }; }