38 lines
1 KiB
Nix
38 lines
1 KiB
Nix
{
|
|
description = "Dev Setup";
|
|
|
|
inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
|
|
inputs.flake-utils.url = "github:numtide/flake-utils";
|
|
|
|
outputs = {nixpkgs, flake-utils, ...}:
|
|
flake-utils.lib.eachDefaultSystem (system:
|
|
let
|
|
pkgs = import nixpkgs { inherit system; };
|
|
ghcOverrides = hself: hsuper: rec {
|
|
berlin-scraper = hself.callPackage ./berlin-scraper {};
|
|
};
|
|
haskellPackages = pkgs.haskellPackages.override {
|
|
overrides = ghcOverrides;
|
|
};
|
|
in rec {
|
|
packages = rec {
|
|
dev-env = haskellPackages.shellFor {
|
|
packages = p: [ p.berlin-scraper ];
|
|
buildInputs = [
|
|
pkgs.haskellPackages.cabal-install
|
|
pkgs.haskell-language-server
|
|
pkgs.cabal2nix
|
|
|
|
# For cabal
|
|
pkgs.pkg-config
|
|
pkgs.binutils
|
|
pkgs.xq
|
|
pkgs.htmlq
|
|
pkgs.dasel
|
|
];
|
|
};
|
|
};
|
|
defaultPackage = packages.dev-env;
|
|
});
|
|
}
|