36 lines
965 B
Nix
36 lines
965 B
Nix
{
|
|
inputs.nixpkgs.url = "nixpkgs";
|
|
inputs.nixpkgs-unstable.url = "github:NixOS/nixpkgs?branch=nixpkgs-unstable";
|
|
inputs.flake-utils.url = "github:numtide/flake-utils";
|
|
inputs.gomod2nix = {
|
|
url = "github:nix-community/gomod2nix";
|
|
inputs.nixpkgs.follows = "nixpkgs-unstable";
|
|
inputs.flake-utils.follows = "flake-utils";
|
|
};
|
|
|
|
outputs = inputs:
|
|
(inputs.flake-utils.lib.eachDefaultSystem (system:
|
|
let
|
|
pkgs = inputs.nixpkgs.legacyPackages.${system};
|
|
pkgsU = inputs.nixpkgs-unstable.legacyPackages.${system};
|
|
pkgsG = inputs.gomod2nix.legacyPackages.${system};
|
|
in {
|
|
devShells.default =
|
|
let goEnv = pkgsG.mkGoEnv { pwd = ./.; };
|
|
in pkgs.mkShell {
|
|
packages = with pkgs; [
|
|
gnumake
|
|
entr
|
|
fd
|
|
(sqlite.override { interactive = true; })
|
|
pkgsU.go_1_23
|
|
pkgsU.gopls
|
|
# TODO: re-enable this once it works with go 1.23
|
|
# goEnv
|
|
# pkgsG.gomod2nix
|
|
];
|
|
};
|
|
}
|
|
));
|
|
}
|