add shell.nix and default.nix
3 files changed, 25 insertions(+), 5 deletions(-)

M default.nix
A => release.nix
A => shell.nix
M default.nix +8 -5
@@ 1,10 1,13 @@ 
-with import <nixpkgs> { };
-with rustUnstable;
-with ncurses;
+{ pkgs ? import <nixpkgs> {},
+  rust ? pkgs.rustPlatform }:
 
-buildRustPackage {
+rust.buildRustPackage {
   name = "cursedlife";
   src = ./.;
-  buildInputs = [ ncurses ];
+  buildInputs = with pkgs; [
+    ncurses
+  ];
   depsSha256 = "";
+
+  meta.maintainers = [ "serverkorken@gmail.com" ];
 }

          
A => release.nix +7 -0
@@ 0,0 1,7 @@ 
+{ nixpkgs, system }:
+
+let
+  pkgs = import nixpkgs { inherit system; };
+in {
+  build = import ./default.nix { inherit pkgs; };
+}

          
A => shell.nix +10 -0
@@ 0,0 1,10 @@ 
+{ pkgs ? import <nixpkgs> {} }:
+
+pkgs.stdenv.mkDerivation {
+  name = "cursedlife-env";
+  buildInputs = with pkgs; [
+    ncurses
+  ];
+
+  RUST_BACKTRACE = 1;
+}