add purescript
This commit is contained in:
parent
b39ce859b4
commit
28812f5ae4
5 changed files with 142 additions and 24 deletions
1
purescript/.envrc
Normal file
1
purescript/.envrc
Normal file
|
@ -0,0 +1 @@
|
|||
use flake .
|
59
purescript/flake.lock
generated
Normal file
59
purescript/flake.lock
generated
Normal file
|
@ -0,0 +1,59 @@
|
|||
{
|
||||
"nodes": {
|
||||
"easy-purescript-nix": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1671011575,
|
||||
"narHash": "sha256-tESal32bcqqdZO+aKnBzc1GoL2mtnaDtj2y7ociCRGA=",
|
||||
"owner": "justinwoo",
|
||||
"repo": "easy-purescript-nix",
|
||||
"rev": "11d3bd58ce6e32703bf69cec04dc7c38eabe14ba",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "justinwoo",
|
||||
"repo": "easy-purescript-nix",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-utils": {
|
||||
"locked": {
|
||||
"lastModified": 1667395993,
|
||||
"narHash": "sha256-nuEHfE/LcWyuSWnS8t12N1wc105Qtau+/OdUAjtQ0rA=",
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"rev": "5aed5285a952e0b949eb3ba02c12fa4fcfef535f",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1671632759,
|
||||
"narHash": "sha256-xWpURFJXayfhGImTH8tPgf4hkGTCt0LTFvhKuKPmhvU=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "9f684b1517a9dc1a456134a26493df7874027dd9",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"root": {
|
||||
"inputs": {
|
||||
"easy-purescript-nix": "easy-purescript-nix",
|
||||
"flake-utils": "flake-utils",
|
||||
"nixpkgs": "nixpkgs"
|
||||
}
|
||||
}
|
||||
},
|
||||
"root": "root",
|
||||
"version": 7
|
||||
}
|
41
purescript/flake.nix
Normal file
41
purescript/flake.nix
Normal file
|
@ -0,0 +1,41 @@
|
|||
{
|
||||
description = "A Nix-flake-based Purescript development environment";
|
||||
|
||||
inputs = {
|
||||
flake-utils.url = "github:numtide/flake-utils";
|
||||
nixpkgs.url = "github:NixOS/nixpkgs";
|
||||
easy-purescript-nix = {
|
||||
url = "github:justinwoo/easy-purescript-nix";
|
||||
flake = false;
|
||||
};
|
||||
};
|
||||
outputs =
|
||||
{ self
|
||||
, nixpkgs
|
||||
, flake-utils
|
||||
, easy-purescript-nix
|
||||
}:
|
||||
flake-utils.lib.eachDefaultSystem (system:
|
||||
let
|
||||
pkgs = nixpkgs.legacyPackages.${system};
|
||||
easy-ps = import easy-purescript-nix { inherit pkgs; };
|
||||
in
|
||||
{
|
||||
devShells.default = pkgs.mkShell {
|
||||
buildInputs = [
|
||||
easy-ps.purs
|
||||
easy-ps.spago
|
||||
easy-ps.purescript-language-server
|
||||
easy-ps.purs-tidy
|
||||
pkgs.nodejs
|
||||
];
|
||||
shellHook = ''
|
||||
echo "Purs `${easy-ps.purs}/bin/purs --version`"
|
||||
echo "Spago `${easy-ps.spago}/bin/spago --version`"
|
||||
echo "Purescript Language Server `${easy-ps.purescript-language-server}/bin/purescript-language-server --version`"
|
||||
echo "Purs Tidy `${easy-ps.purs-tidy}/bin/purs-tidy --version`"
|
||||
echo "Node.js `${pkgs.nodejs}/bin/node --version`"
|
||||
'';
|
||||
};
|
||||
});
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue