flake.nix

 1{
 2  description = "Zed is a minimal code editor crafted for speed and collaboration with humans and AI.";
 3
 4  inputs = {
 5    nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
 6    flake-parts.url = "github:hercules-ci/flake-parts";
 7    crane.url = "github:ipetkov/crane";
 8    rust-overlay = {
 9      url = "github:oxalica/rust-overlay";
10      inputs.nixpkgs.follows = "nixpkgs";
11    };
12  };
13
14  outputs =
15    inputs@{ flake-parts, ... }:
16    flake-parts.lib.mkFlake { inherit inputs; } {
17      systems = [
18        "x86_64-linux"
19        "x86_64-darwin"
20        "aarch64-linux"
21        "aarch64-darwin"
22      ];
23
24      imports = [
25        ./nix/modules/overlays.nix
26        ./nix/modules/packages.nix
27        ./nix/modules/partitions.nix
28      ];
29    };
30
31  nixConfig = {
32    extra-substituters = [
33      "https://zed.cachix.org"
34      "https://cache.garnix.io"
35    ];
36    extra-trusted-public-keys = [
37      "zed.cachix.org-1:/pHQ6dpMsAZk2DiP4WCL0p9YDNKWj2Q5FL20bNmw1cU="
38      "cache.garnix.io:CTFPyKSLcx5RMJKfLo5EEPUObbA78b0YQ2DTCJXqr9g="
39    ];
40  };
41}