aboutsummaryrefslogtreecommitdiffstats
path: root/flake.nix
diff options
context:
space:
mode:
authorJamie Quigley <jamie@quigley.xyz>2024-06-13 12:10:44 +0100
committerGitHub <noreply@github.com>2024-06-13 12:10:44 +0100
commit4ee7db5c5465270ae173014adb4bf7739ff65d92 (patch)
treeefad5a519cc4ef7d18b96eb45208be12f3b5f79a /flake.nix
parentchore(build): compile protobufs with protox (#2122) (diff)
downloadatuin-4ee7db5c5465270ae173014adb4bf7739ff65d92.zip
chore(nix): De-couple atuin nix build from nixpkgs rustc version (#2123)
Diffstat (limited to 'flake.nix')
-rw-r--r--flake.nix17
1 files changed, 17 insertions, 0 deletions
diff --git a/flake.nix b/flake.nix
index 67833754..8384a2c2 100644
--- a/flake.nix
+++ b/flake.nix
@@ -6,11 +6,16 @@
url = "github:edolstra/flake-compat";
flake = false;
};
+ fenix = {
+ url = "github:nix-community/fenix";
+ inputs.nixpkgs.follows = "nixpkgs";
+ };
};
outputs = {
self,
nixpkgs,
flake-utils,
+ fenix,
...
}:
flake-utils.lib.eachDefaultSystem (system: let
@@ -18,6 +23,18 @@
in {
packages.atuin = pkgs.callPackage ./atuin.nix {
inherit (pkgs.darwin.apple_sdk.frameworks) Security SystemConfiguration AppKit;
+ rustPlatform = let
+ toolchain =
+ fenix.packages.${system}.fromToolchainFile
+ {
+ file = ./rust-toolchain.toml;
+ sha256 = "sha256-7QfkHty6hSrgNM0fspycYkRcB82eEqYa4CoAJ9qA3tU=";
+ };
+ in
+ pkgs.makeRustPlatform {
+ cargo = toolchain;
+ rustc = toolchain;
+ };
};
packages.default = self.outputs.packages.${system}.atuin;