git/list[1] front-page[2] threads[3] people[4] search[5] about
 

fix t5600-clone-fail-cleanup.sh on windows

From
Alex Riesen <raa.lkml@gmail.com>
Date
Feb 23, 2006, 11:25 UTC
Message-ID
<81b0412b0602230325l309ab68fi900deb5fd3c77ffd@mail.gmail.com>

In windows you cannot remove current or opened directory, an opened file, a running program, a loaded library, etc...

--- I still wonder how they managed to survive...

>From nobody Mon Sep 17 00:00:00 2001
From: Alex Riesen <raa.lkml@gmail.com>
Date: Thu Feb 23 11:49:31 2006 +0100
Subject: [PATCH] fix t5600-clone-fail-cleanup.sh on windows
---
 git-clone.sh |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
3453c0df0d815580c5e7aaeb67bfc54b5b0954c6
diff --git a/git-clone.sh b/git-clone.sh
index dc0ad55..0c60e0b 100755
--- a/git-clone.sh
+++ b/git-clone.sh
@@ -118,7 +118,7 @@ dir="$2"
 [ -e "$dir" ] && echo "$dir already exists." && usage
 mkdir -p "$dir" &&
 D=$(cd "$dir" && pwd) &&
-trap 'err=$?; rm -r $D; exit $err' exit
+trap 'err=$?; cd ..; rm -r $D; exit $err' exit
 case "$bare" in
 yes) GIT_DIR="$D" ;;
 *) GIT_DIR="$D/.git" ;;
-- 
1.2.3.g6ae0e
Message 1 of 1 in “fix t5600-clone-fail-cleanup.sh on windows”
  1. Alex RiesenFeb 23, 2006

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.