Skip to content

Commit 89fa672

Browse files
committed
When using Nix, depend on git.
Partially addresses #2287, as git is used in stack internally to fetch package index and LTS.
1 parent c67b7f9 commit 89fa672

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

ChangeLog.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,8 @@ Behavior changes:
1919

2020
Other enhancements:
2121

22+
* When using Nix, nix-shell now depends always on git to prevent runtime errors
23+
while fetching metadata
2224
* Internal cleanup: configuration types are now based much more on lenses
2325
* `stack build` and related commands now allow the user to disable debug symbol stripping
2426
with new `--no-strip`, `--no-library-stripping`, and `--no-executable-shipping` flags,

src/Stack/Nix.hs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ runShellAndExit mprojectRoot getCompilerVersion getCmdArgs = do
8383
inContainer <- getInContainer
8484
let pkgsInConfig = nixPackages (configNix config)
8585
ghc = nixCompiler compilerVersion
86-
pkgs = pkgsInConfig ++ [ghc]
86+
pkgs = pkgsInConfig ++ [ghc, "git"]
8787
pkgsStr = "[" <> T.intercalate " " pkgs <> "]"
8888
pureShell = nixPureShell (configNix config)
8989
addGCRoots = nixAddGCRoots (configNix config)

0 commit comments

Comments
 (0)