aboutsummaryrefslogtreecommitdiff
path: root/flake.nix
diff options
context:
space:
mode:
authorAkshay Nair <phenax5@gmail.com>2024-12-13 16:35:10 +0530
committerAkshay Nair <phenax5@gmail.com>2024-12-13 16:35:10 +0530
commit7553b33b4d3caedd5650953acf7ae440f2154735 (patch)
tree9649b4061be6d40f42b6d9dc285a70b65b4b3575 /flake.nix
downloadchelleport-7553b33b4d3caedd5650953acf7ae440f2154735.tar.gz
chelleport-7553b33b4d3caedd5650953acf7ae440f2154735.zip
Init commit with hello world shit
Diffstat (limited to 'flake.nix')
-rw-r--r--flake.nix48
1 files changed, 48 insertions, 0 deletions
diff --git a/flake.nix b/flake.nix
new file mode 100644
index 0000000..ead8307
--- /dev/null
+++ b/flake.nix
@@ -0,0 +1,48 @@
+{
+ inputs = {
+ nixpkgs.url = "github:nixos/nixpkgs/nixpkgs-unstable";
+ flake-parts.url = "github:hercules-ci/flake-parts";
+ haskell-flake.url = "github:srid/haskell-flake";
+ };
+ outputs = inputs@{ self, nixpkgs, flake-parts, ... }:
+ flake-parts.lib.mkFlake { inherit inputs; } {
+ systems = nixpkgs.lib.systems.flakeExposed;
+ imports = [ inputs.haskell-flake.flakeModule ];
+
+ perSystem = { self', pkgs, lib, config, ... }: {
+ haskellProjects.default = {
+ projectRoot = builtins.toString (lib.fileset.toSource {
+ root = ./.;
+ fileset = lib.fileset.unions [
+ ./src
+ ./specs
+ ./chelleport.cabal
+ ];
+ });
+
+ packages = {};
+ settings = {};
+
+ devShell = {
+ # tools = hp: { fourmolu = hp.fourmolu; ghcid = null; };
+ hlsCheck.enable = pkgs.stdenv.isDarwin;
+ };
+
+ autoWire = [ "packages" "apps" "checks" ];
+ };
+
+ packages.default = self'.packages.chelleport;
+ apps.default = self'.apps.chelleport;
+
+ devShells.default = pkgs.mkShell {
+ inputsFrom = [
+ config.haskellProjects.default.outputs.devShell
+ ];
+ packages = with pkgs; [
+ just
+ haskellPackages.hspec-golden
+ ];
+ };
+ };
+ };
+}