From 422f247cb321659b0490e11907d67ebb1b81eb15 Mon Sep 17 00:00:00 2001 From: Dominik Picheta Date: Sun, 22 Dec 2013 23:30:06 +0000 Subject: [PATCH] Git checkout is now forced. This has been done to fix an issue on Windows. The issue is that Git may think that line endings have been changed straight after a clone and thus disallow the checkout because "local changes are present". --- download.nim | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/download.nim b/download.nim index 5022035..98b6ff8 100644 --- a/download.nim +++ b/download.nim @@ -20,7 +20,10 @@ proc doCheckout(meth: TDownloadMethod, downloadDir, branch: string) = case meth of TDownloadMethod.Git: cd downloadDir: - doCmd("git checkout " & branch) + # Force is used here because local changes may appear straight after a + # clone has happened. Like in the case of git on Windows where it + # messes up the damn line endings. + doCmd("git checkout --force " & branch) of TDownloadMethod.Hg: cd downloadDir: doCmd("hg checkout " & branch)