test naive templates

This commit is contained in:
jsz4n
2023-10-24 17:36:04 +02:00
parent 594c311117
commit 9aada69d8f
7 changed files with 131 additions and 0 deletions

19
rust/flake.nix Normal file
View File

@@ -0,0 +1,19 @@
{
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
};
outputs = { self, nixpkgs }:
let
supportedSystems = [ "x86_64-linux" "x86_64-darwin" "aarch64-linux" "aarch64-darwin" ];
forAllSystems = nixpkgs.lib.genAttrs supportedSystems;
pkgs = forAllSystems (system: nixpkgs.legacyPackages.${system});
in
{
devShells = forAllSystems (system :{
default = pkgs.${system}.callPackage ./shell.nix {};
});
};
}

10
rust/shell.nix Normal file
View File

@@ -0,0 +1,10 @@
{pkgs ? import <nixpkgs> {}}:
pkgs.mkShell {
buildInputs = with pkgs; [
cargo
rustc
pkg-config
openssl
];
}