Fix nix developement shell (#3257)

Upgrade a few packages which needed upgrade and avoid building hiedb in
nix as it has a dependency on a package in this repository (hie-compat).
This commit is contained in:
Akshay Mankar 2022-10-07 15:19:53 +02:00 committed by GitHub
parent 8fd2b89a01
commit 73b02ef3f7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 91 additions and 18 deletions

View File

@ -53,6 +53,18 @@
"url": "https://hackage.haskell.org/package/constraints-extras-0.3.2.1/constraints-extras-0.3.2.1.tar.gz" "url": "https://hackage.haskell.org/package/constraints-extras-0.3.2.1/constraints-extras-0.3.2.1.tar.gz"
} }
}, },
"entropy": {
"flake": false,
"locked": {
"narHash": "sha256-Oj0vftbS7Pau7OzdMrzRPghqwEiimwQbt0w59cMcH98=",
"type": "tarball",
"url": "https://hackage.haskell.org/package/entropy-0.4.1.10/entropy-0.4.1.10.tar.gz"
},
"original": {
"type": "tarball",
"url": "https://hackage.haskell.org/package/entropy-0.4.1.10/entropy-0.4.1.10.tar.gz"
}
},
"flake-compat": { "flake-compat": {
"flake": false, "flake": false,
"locked": { "locked": {
@ -108,6 +120,18 @@
"url": "https://hackage.haskell.org/package/fourmolu-0.3.0.0/fourmolu-0.3.0.0.tar.gz" "url": "https://hackage.haskell.org/package/fourmolu-0.3.0.0/fourmolu-0.3.0.0.tar.gz"
} }
}, },
"ghc-check": {
"flake": false,
"locked": {
"narHash": "sha256-pmmQMrk6X00+zbsstV49w/Es9+V9gssrXzJoub2ReEs=",
"type": "tarball",
"url": "https://hackage.haskell.org/package/ghc-check-0.5.0.8/ghc-check-0.5.0.8.tar.gz"
},
"original": {
"type": "tarball",
"url": "https://hackage.haskell.org/package/ghc-check-0.5.0.8/ghc-check-0.5.0.8.tar.gz"
}
},
"ghc-exactprint": { "ghc-exactprint": {
"flake": false, "flake": false,
"locked": { "locked": {
@ -160,6 +184,18 @@
"url": "https://hackage.haskell.org/package/hie-bios-0.11.0/hie-bios-0.11.0.tar.gz" "url": "https://hackage.haskell.org/package/hie-bios-0.11.0/hie-bios-0.11.0.tar.gz"
} }
}, },
"hiedb": {
"flake": false,
"locked": {
"narHash": "sha256-Ny9Ya7Y8GGdBh8r2cryQfK4XZj2dIrYQpaB8dTNQ3KI=",
"type": "tarball",
"url": "https://hackage.haskell.org/package/hiedb-0.4.2.0/hiedb-0.4.2.0.tar.gz"
},
"original": {
"type": "tarball",
"url": "https://hackage.haskell.org/package/hiedb-0.4.2.0/hiedb-0.4.2.0.tar.gz"
}
},
"hlint": { "hlint": {
"flake": false, "flake": false,
"locked": { "locked": {
@ -199,30 +235,37 @@
"lsp": { "lsp": {
"flake": false, "flake": false,
"locked": { "locked": {
"lastModified": 1662291729, "narHash": "sha256-g5R34SVz0kRD5zpODNsaaaIJOHty10cTS6ZDPi4s8pc=",
"narHash": "sha256-KlL38v/75G9zrW7+IiUeiCxFfLJGm/EdFeWQRUikab8=", "type": "tarball",
"owner": "haskell", "url": "https://hackage.haskell.org/package/lsp-1.6.0.0/lsp-1.6.0.0.tar.gz"
"repo": "lsp",
"rev": "b0f8596887088b8ab65fc1015c773f45b47234ae",
"type": "github"
}, },
"original": { "original": {
"owner": "haskell", "type": "tarball",
"repo": "lsp", "url": "https://hackage.haskell.org/package/lsp-1.6.0.0/lsp-1.6.0.0.tar.gz"
"rev": "b0f8596887088b8ab65fc1015c773f45b47234ae",
"type": "github"
} }
}, },
"lsp-test": { "lsp-test": {
"flake": false, "flake": false,
"locked": { "locked": {
"narHash": "sha256-TXRy/VT94Cn0BPtiL65c7UqahyJZgUtBQQgESZacrdY=", "narHash": "sha256-HhFAdNvmnnnCzsKfTWbqUyTFrCfq1n6pGKfk2R0fcUc=",
"type": "tarball", "type": "tarball",
"url": "https://hackage.haskell.org/package/lsp-test-0.14.0.3/lsp-test-0.14.0.3.tar.gz" "url": "https://hackage.haskell.org/package/lsp-test-0.14.1.0/lsp-test-0.14.1.0.tar.gz"
}, },
"original": { "original": {
"type": "tarball", "type": "tarball",
"url": "https://hackage.haskell.org/package/lsp-test-0.14.0.3/lsp-test-0.14.0.3.tar.gz" "url": "https://hackage.haskell.org/package/lsp-test-0.14.1.0/lsp-test-0.14.1.0.tar.gz"
}
},
"lsp-types": {
"flake": false,
"locked": {
"narHash": "sha256-QSixsrCvsWlckG/LLF1z8LsHhqaXxVAxOPIA1NxjVT4=",
"type": "tarball",
"url": "https://hackage.haskell.org/package/lsp-types-1.6.0.0/lsp-types-1.6.0.0.tar.gz"
},
"original": {
"type": "tarball",
"url": "https://hackage.haskell.org/package/lsp-types-1.6.0.0/lsp-types-1.6.0.0.tar.gz"
} }
}, },
"nixpkgs": { "nixpkgs": {
@ -271,19 +314,23 @@
"all-cabal-hashes-unpacked": "all-cabal-hashes-unpacked", "all-cabal-hashes-unpacked": "all-cabal-hashes-unpacked",
"brittany-01312": "brittany-01312", "brittany-01312": "brittany-01312",
"constraints-extras": "constraints-extras", "constraints-extras": "constraints-extras",
"entropy": "entropy",
"flake-compat": "flake-compat", "flake-compat": "flake-compat",
"flake-utils": "flake-utils", "flake-utils": "flake-utils",
"fourmolu": "fourmolu", "fourmolu": "fourmolu",
"fourmolu-0300": "fourmolu-0300", "fourmolu-0300": "fourmolu-0300",
"ghc-check": "ghc-check",
"ghc-exactprint": "ghc-exactprint", "ghc-exactprint": "ghc-exactprint",
"ghc-exactprint-150": "ghc-exactprint-150", "ghc-exactprint-150": "ghc-exactprint-150",
"gitignore": "gitignore", "gitignore": "gitignore",
"hie-bios": "hie-bios", "hie-bios": "hie-bios",
"hiedb": "hiedb",
"hlint": "hlint", "hlint": "hlint",
"hlint-34": "hlint-34", "hlint-34": "hlint-34",
"implicit-hie-cradle": "implicit-hie-cradle", "implicit-hie-cradle": "implicit-hie-cradle",
"lsp": "lsp", "lsp": "lsp",
"lsp-test": "lsp-test", "lsp-test": "lsp-test",
"lsp-types": "lsp-types",
"nixpkgs": "nixpkgs", "nixpkgs": "nixpkgs",
"ptr-poker": "ptr-poker", "ptr-poker": "ptr-poker",
"retrie": "retrie", "retrie": "retrie",

View File

@ -28,11 +28,15 @@
# List of hackage dependencies # List of hackage dependencies
lsp = { lsp = {
url = "github:haskell/lsp/b0f8596887088b8ab65fc1015c773f45b47234ae"; url = "https://hackage.haskell.org/package/lsp-1.6.0.0/lsp-1.6.0.0.tar.gz";
flake = false;
};
lsp-types = {
url = "https://hackage.haskell.org/package/lsp-types-1.6.0.0/lsp-types-1.6.0.0.tar.gz";
flake = false; flake = false;
}; };
lsp-test = { lsp-test = {
url = "https://hackage.haskell.org/package/lsp-test-0.14.0.3/lsp-test-0.14.0.3.tar.gz"; url = "https://hackage.haskell.org/package/lsp-test-0.14.1.0/lsp-test-0.14.1.0.tar.gz";
flake = false; flake = false;
}; };
ghc-exactprint-150 = { ghc-exactprint-150 = {
@ -43,6 +47,10 @@
url = "https://hackage.haskell.org/package/ghc-exactprint-1.4.1/ghc-exactprint-1.4.1.tar.gz"; url = "https://hackage.haskell.org/package/ghc-exactprint-1.4.1/ghc-exactprint-1.4.1.tar.gz";
flake = false; flake = false;
}; };
ghc-check = {
url = "https://hackage.haskell.org/package/ghc-check-0.5.0.8/ghc-check-0.5.0.8.tar.gz";
flake = false;
};
constraints-extras = { constraints-extras = {
url = "https://hackage.haskell.org/package/constraints-extras-0.3.2.1/constraints-extras-0.3.2.1.tar.gz"; url = "https://hackage.haskell.org/package/constraints-extras-0.3.2.1/constraints-extras-0.3.2.1.tar.gz";
flake = false; flake = false;
@ -91,6 +99,14 @@
url = "https://hackage.haskell.org/package/hie-bios-0.11.0/hie-bios-0.11.0.tar.gz"; url = "https://hackage.haskell.org/package/hie-bios-0.11.0/hie-bios-0.11.0.tar.gz";
flake = false; flake = false;
}; };
entropy = {
url = "https://hackage.haskell.org/package/entropy-0.4.1.10/entropy-0.4.1.10.tar.gz";
flake = false;
};
hiedb = {
url = "https://hackage.haskell.org/package/hiedb-0.4.2.0/hiedb-0.4.2.0.tar.gz";
flake = false;
};
}; };
outputs = outputs =
inputs@{ self, nixpkgs, flake-compat, flake-utils, gitignore, all-cabal-hashes-unpacked, ... }: inputs@{ self, nixpkgs, flake-compat, flake-utils, gitignore, all-cabal-hashes-unpacked, ... }:
@ -138,6 +154,13 @@
hls-plugin-api = ./hls-plugin-api; hls-plugin-api = ./hls-plugin-api;
hls-test-utils = ./hls-test-utils; hls-test-utils = ./hls-test-utils;
ghcide-test-utils = ./ghcide/test; ghcide-test-utils = ./ghcide/test;
# hiedb depends on hie-compact, which is part of this repository. If
# cabal inside the nix development shell tries to use the hiedb
# compiled inside nix, it thinks that this package is broken and
# does nothing. Adding this here ensures that hiedb compiled in nix
# is not available to cabal and then cabal downloads hiedb from
# hackage and compiles it.
hiedb = inputs.hiedb;
} // pluginSourceDirs; } // pluginSourceDirs;
# Tweak our packages # Tweak our packages
@ -149,12 +172,15 @@
# GHCIDE requires hie-bios ^>=0.9.1 # GHCIDE requires hie-bios ^>=0.9.1
hie-bios = hself.callCabal2nix "hie-bios" inputs.hie-bios {}; hie-bios = hself.callCabal2nix "hie-bios" inputs.hie-bios {};
lsp = hsuper.callCabal2nix "lsp" "${inputs.lsp}/lsp" {}; lsp = hsuper.callCabal2nix "lsp" inputs.lsp {};
lsp-types = hsuper.callCabal2nix "lsp-types" "${inputs.lsp}/lsp-types" {}; lsp-types = hsuper.callCabal2nix "lsp-types" inputs.lsp-types {};
lsp-test = hsuper.callCabal2nix "lsp-test" inputs.lsp-test {}; lsp-test = hsuper.callCabal2nix "lsp-test" inputs.lsp-test {};
implicit-hie-cradle = hself.callCabal2nix "implicit-hie-cradle" inputs.implicit-hie-cradle {}; entropy = hsuper.callCabal2nix "entropy" inputs.entropy {};
hiedb = hsuper.callCabal2nix "hiedb" inputs.hiedb {};
implicit-hie-cradle = hself.callCabal2nix "implicit-hie-cradle" inputs.implicit-hie-cradle {};
ghc-check = hself.callCabal2nix "ghc-check" inputs.ghc-check {};
# https://github.com/NixOS/nixpkgs/issues/140774 # https://github.com/NixOS/nixpkgs/issues/140774
ormolu = ormolu =
if final.system == "aarch64-darwin" if final.system == "aarch64-darwin"