Skip to content

Commit

Permalink
Initial nix flake with package build
Browse files Browse the repository at this point in the history
  • Loading branch information
camelpunch authored and sax committed Oct 23, 2023
1 parent c604ebc commit a331757
Show file tree
Hide file tree
Showing 3 changed files with 47 additions and 0 deletions.
6 changes: 6 additions & 0 deletions default.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{ rustPlatform }:
rustPlatform.buildRustPackage {
name = "dyd";
src = ./.;
cargoHash = "sha256-VduByUoO4aeGQfSpNcVxmJlYrpmGF6XLdC040YsDuO4=";
}
25 changes: 25 additions & 0 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

16 changes: 16 additions & 0 deletions flake.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
outputs = { self, nixpkgs }:
let
forAllSystems = generate:
nixpkgs.lib.genAttrs [
"aarch64-darwin"
"x86_64-linux"
]
(system: generate nixpkgs.legacyPackages.${system});
in
{
packages = forAllSystems (pkgs: {
default = pkgs.callPackage ./default.nix { };
});
};
}

0 comments on commit a331757

Please sign in to comment.