Skip to content

Commit 92c8631

Browse files
committed
feat: use nested commands for the default devShell
1 parent 2d66d10 commit 92c8631

1 file changed

Lines changed: 25 additions & 1 deletion

File tree

flake.nix

Lines changed: 25 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,31 @@
3838
};
3939
};
4040

41-
devShells.default = devshell.fromTOML ./devshell.toml;
41+
devShells = {
42+
default = devshell.mkShell {
43+
commands = {
44+
packages = [
45+
"diffutils" # used by golangci-lint
46+
"goreleaser"
47+
];
48+
scripts = [
49+
{
50+
prefix = "nix run .#";
51+
inherit packages;
52+
}
53+
{
54+
name = "nix fmt";
55+
help = "format Nix files";
56+
}
57+
];
58+
utilites = [
59+
[ "GitHub utility" "gitAndTools.hub" ]
60+
[ "golang linter" "golangci-lint" ]
61+
];
62+
};
63+
};
64+
toml = devshell.fromTOML ./devshell.toml;
65+
};
4266

4367
legacyPackages = import inputs.self {
4468
inherit system;

0 commit comments

Comments
 (0)