| 6 Jul 2025 |
Alex | In reply to @collinarnett:matrix.org Does the hoogle server serve the haddocs as well? I'm not really sure what I'm looking for so I would like to browse the docs like I would on hackage. Note that how Hoogle serves Haddocks is affected by the --local flag.
(For most users, running with --local works better.)
See https://github.com/ndmitchell/hoogle/blob/e83646ee1b62eb724def6c838a34017b60fc519a/docs/Install.md#server | 00:14:08 |
woobilicious | Is there anyway to "export" a build plan for haskell apps based on the nixpkgs version? trying to think how to compile my code for windows, and cabal obvious isn't going to pull in the exact same versions without some hints. I guess I could look at cross compiling using mingw64 version of ghc in nixpkgs, but that might just be a huge headache. | 05:56:37 |
Alex | In reply to @woobilicious:matrix.org Is there anyway to "export" a build plan for haskell apps based on the nixpkgs version? trying to think how to compile my code for windows, and cabal obvious isn't going to pull in the exact same versions without some hints. I guess I could look at cross compiling using mingw64 version of ghc in nixpkgs, but that might just be a huge headache. Have you tried cabal freeze? | 06:23:48 |
woobilicious | oh thanks, I didn't realise that existed...kinda half forgot cabal added some modern features, as I used to use stack on windows and nixpkgs now. | 06:44:58 |
| 8 Jul 2025 |
@dmjio:matrix.org | is there a function to parse a flake lockfile into a set?
let sources = parseFlakeLock (builtins.readFile ./flake.lock);
something like this
| 16:07:35 |
ners | Yes, in fact flake-compat is based on this principle. See examples here: https://github.com/nix-community/flake-compat | 16:13:58 |
ners | * Yes, in fact flake-compat is based on this principle. See examples here: https://github.com/nix-community/flake-compat
Basically: builtins.fromJSON (builtins.readFile ./flake.lock);
| 16:14:48 |
@dmjio:matrix.org | so I'm just doing this rn
# fetch from flake.lock
with (builtins.fromJSON (builtins.readFile ../flake.lock));
fetchFromFlakeLock = args:
fetchFromGitHub {
inherit (args.locked) owner repo rev;
hash = args.locked.narHash;
};
servant = fetchFromFlake (nodes.servant);
| 19:50:58 |
@dmjio:matrix.org | does fetchFromFlakeLock already exist somewhere | 19:51:18 |