From b2a0986ca61f8557f51b36f2cdc045143788ae12 Mon Sep 17 00:00:00 2001 From: Jamie Quigley Date: Wed, 15 Feb 2023 09:04:07 +0000 Subject: Add nix files and install instructions (#477) --- flake.nix | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 flake.nix (limited to 'flake.nix') diff --git a/flake.nix b/flake.nix new file mode 100644 index 00000000..8a1f2a14 --- /dev/null +++ b/flake.nix @@ -0,0 +1,31 @@ +{ + inputs = { + nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; + flake-utils.url = "github:numtide/flake-utils"; + }; + outputs = { + self, + nixpkgs, + flake-utils, + ... + }: + flake-utils.lib.eachDefaultSystem (system: let + pkgs = nixpkgs.outputs.legacyPackages.${system}; + in { + packages.atuin = pkgs.callPackage ./atuin.nix { + inherit (pkgs.darwin.apple_sdk.frameworks) Security SystemConfiguration; + }; + packages.default = self.outputs.packages.${system}.atuin; + + devShells.default = self.packages.${system}.default.overrideAttrs (super: { + nativeBuildInputs = with pkgs; + super.nativeBuildInputs + ++ [ + cargo-edit + clippy + rustfmt + ]; + RUST_SRC_PATH = "${pkgs.rustPlatform.rustLibSrc}"; + }); + }); +} -- cgit v1.3.1