diff --git a/.gitignore b/.gitignore index 906e747..4393459 100644 --- a/.gitignore +++ b/.gitignore @@ -12,3 +12,4 @@ local/ cabal.sandbox.config cabal.project.local .ghc.environment.* +result \ No newline at end of file diff --git a/README.md b/README.md index d42d085..da9675b 100644 --- a/README.md +++ b/README.md @@ -94,6 +94,12 @@ log the size of the input, but _not_ the full input/output of requests.) aura -A brittany ~~~~ +- via `nix`: + ~~~.sh + nix build # or 'nix-build' + nix-env -i ./result + ~~~ + # Editor Integration #### Sublime text diff --git a/default.nix b/default.nix new file mode 100644 index 0000000..5c0ccfe --- /dev/null +++ b/default.nix @@ -0,0 +1,13 @@ +{ pkgs ? import (fetchGit (import ./pkgs.nix)) {} +, compiler ? "ghc822" +}: + +pkgs.haskell.packages.${compiler}.developPackage { + root = ./.; + name = "brittany"; + overrides = with pkgs.haskell.lib; self: super: { + }; + source-overrides = { + ghc-exactprint = "0.5.8.0"; + }; +} diff --git a/pkgs.nix b/pkgs.nix new file mode 100644 index 0000000..76cbbb8 --- /dev/null +++ b/pkgs.nix @@ -0,0 +1,5 @@ +{ + url = "https://github.com/nixos/nixpkgs.git"; + ref = "release-18.09"; + rev = "b9fa31cea0e119ecf1867af4944ddc2f7633aacd"; +}