2022-12-21 16:04:57 +01:00
|
|
|
{
|
|
|
|
description = "A Nix-flake-based Purescript development environment";
|
|
|
|
|
|
|
|
inputs = {
|
2023-12-27 22:04:33 +01:00
|
|
|
nixpkgs.url = "https://flakehub.com/f/NixOS/nixpkgs/0.1.*.tar.gz";
|
2022-12-21 16:04:57 +01:00
|
|
|
easy-purescript-nix = {
|
|
|
|
url = "github:justinwoo/easy-purescript-nix";
|
|
|
|
flake = false;
|
|
|
|
};
|
|
|
|
};
|
2023-03-06 12:28:29 +01:00
|
|
|
|
2023-07-14 02:12:42 +02:00
|
|
|
outputs = { self, nixpkgs, easy-purescript-nix }:
|
2022-12-21 16:04:57 +01:00
|
|
|
let
|
2023-07-14 02:26:57 +02:00
|
|
|
supportedSystems = [ "x86_64-linux" "x86_64-darwin" "aarch64-darwin" ]; # "aarch64-linux" not supported
|
2023-07-14 02:12:42 +02:00
|
|
|
forEachSupportedSystem = f: nixpkgs.lib.genAttrs supportedSystems (system: f {
|
|
|
|
pkgs = import nixpkgs { inherit system; };
|
|
|
|
});
|
2022-12-21 16:04:57 +01:00
|
|
|
in
|
|
|
|
{
|
2023-07-14 02:12:42 +02:00
|
|
|
devShells = forEachSupportedSystem ({ pkgs }: {
|
|
|
|
default =
|
|
|
|
let
|
|
|
|
easy-ps = import easy-purescript-nix { inherit pkgs; };
|
|
|
|
in
|
|
|
|
pkgs.mkShell {
|
|
|
|
packages = (with pkgs; [ nodejs ]) ++ (with easy-ps; [
|
|
|
|
purs
|
|
|
|
spago
|
|
|
|
purescript-language-server
|
|
|
|
purs-tidy
|
|
|
|
]);
|
|
|
|
};
|
|
|
|
});
|
|
|
|
};
|
2022-12-21 16:04:57 +01:00
|
|
|
}
|