mirror of
https://github.com/tweag/gomod2nix.git
synced 2024-11-05 01:59:08 +00:00
22 lines
411 B
Nix
22 lines
411 B
Nix
{ pkgs ? (
|
|
let
|
|
inherit (builtins) fetchTree fromJSON readFile;
|
|
inherit ((fromJSON (readFile ./flake.lock)).nodes) nixpkgs gomod2nix;
|
|
in
|
|
import (fetchTree nixpkgs.locked) {
|
|
overlays = [
|
|
(import "${fetchTree gomod2nix.locked}/overlay.nix")
|
|
];
|
|
}
|
|
)
|
|
}:
|
|
|
|
let
|
|
goEnv = pkgs.mkGoEnv { pwd = ./.; };
|
|
in
|
|
pkgs.mkShell {
|
|
packages = [
|
|
goEnv
|
|
pkgs.gomod2nix
|
|
];
|
|
}
|