aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/nix/flake.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/nix/flake.cc b/src/nix/flake.cc
index 133e6c7e0..17df29fdb 100644
--- a/src/nix/flake.cc
+++ b/src/nix/flake.cc
@@ -589,7 +589,7 @@ struct CmdFlakeInitCommon : virtual Args, EvalCommand
copyDir(templateDir, flakeDir);
if (pathExists(flakeDir + "/.git")) {
- Strings args = { "-C", flakeDir, "add", "--intent-to-add", "--" };
+ Strings args = { "-C", flakeDir, "add", "--intent-to-add", "--force", "--" };
for (auto & s : files) args.push_back(s);
runProgram("git", true, args);
}