Fix flake.nix definition to work with more recent nixpkgs snapshots (#266)

* Rework flake.nix

* Add devShell environment on flake.nix

* Update flake.lock
This commit is contained in:
Ruben Astudillo 2023-05-01 11:21:59 -04:00 committed by GitHub
parent ff2ea3b414
commit 7036f7aac8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 20 additions and 12 deletions

View File

@ -18,11 +18,11 @@
}, },
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1629366148, "lastModified": 1682554371,
"narHash": "sha256-CIfmrcptxXiCVH9UCKRq44IHcSW8WQ8yQQPTavOpUF8=", "narHash": "sha256-UYm0a60XOmBDBQqgySDRN8LUV5xWZn26OzjTCeVrYDs=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "b5c2212cdfceb727b072223e460eb7dcefbc4062", "rev": "dc9fe27b825a4196fe81a583eb3a174da847660e",
"type": "github" "type": "github"
}, },
"original": { "original": {

View File

@ -29,5 +29,13 @@
}; };
defaultPackage = packages.monomer; defaultPackage = packages.monomer;
defaultApp = apps.tutorial; defaultApp = apps.tutorial;
devShell = haskellPackages.shellFor {
packages = p: [ packages.monomer ];
withHoogle = true;
buildInputs = with haskellPackages; [
haskell-language-server
cabal-install
];
};
}); });
} }

View File

@ -16,7 +16,7 @@ with super.haskellPackages.extend (self: super:
rev = "283516a337c4d3606555728df0a39294e78a7cdf"; rev = "283516a337c4d3606555728df0a39294e78a7cdf";
sha256 = "1vggli76ijqmx633yix4yg5dv58a14p8561jnprjc061sjngphzv"; sha256 = "1vggli76ijqmx633yix4yg5dv58a14p8561jnprjc061sjngphzv";
}) "-fexamples -fstb_truetype" { }) "-fexamples -fstb_truetype" {
inherit GLEW glew libGL libGLU; inherit glew libGL libGLU;
inherit (xorg) libX11; inherit (xorg) libX11;
}); });
GLEW = glew; GLEW = glew;

View File

@ -92,14 +92,14 @@ in rec {
}; };
}; };
virtualisation = { # virtualisation = {
graphics = true; # graphics = true;
cores = 4; # cores = 4;
qemu.networkingOptions = [ # qemu.networkingOptions = [
"-device virtio-net-pci,netdev=user.0" # "-device virtio-net-pci,netdev=user.0"
"-netdev type=user,id=user.0\${QEMU_NET_OPTS:+,$QEMU_NET_OPTS}" # "-netdev type=user,id=user.0\${QEMU_NET_OPTS:+,$QEMU_NET_OPTS}"
]; # ];
}; # };
}; };
}).vm; }).vm;
}; };