From 319863e67b35620bababe1c97f00004c6ee17356 Mon Sep 17 00:00:00 2001 From: Marcono1234 Date: Mon, 11 Oct 2021 03:29:14 +0200 Subject: [PATCH] Recommend `git reset` when cloning repository on Windows fails `git restore --source=HEAD :/` which is currently suggested by Git does not work, it is unable to restore the files, see https://github.com/git-for-windows/git/issues/3411. --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 9236c82fe7..c77adccfa1 100644 --- a/README.md +++ b/README.md @@ -55,7 +55,7 @@ On Windows this might fail with "Filename too long". To solve this, run the following commands in the cloned Git repository: 1. `git config core.longpaths true` -2. `git restore --source=HEAD :/` +2. `git reset --hard` You can read more about this in the [Git for Windows wiki](https://github.com/git-for-windows/git/wiki/Git-cannot-create-a-file-or-directory-with-a-long-path).