From 87bddba9924045e39e988d9704714db90abd5619 Mon Sep 17 00:00:00 2001 From: Johannes Sixt Date: Fri, 30 Nov 2007 22:06:30 +0100 Subject: [PATCH 1/1] Windows: Work around incompatible sort and find. If the PATH lists the Windows system directories before the MSYS directories, Windows's own incompatible sort and find commands would be picked up. We implement these commands as functions and call the real tools by absolute path. Signed-off-by: Johannes Sixt --- git-sh-setup.sh | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/git-sh-setup.sh b/git-sh-setup.sh index a44b1c74a3..9cceb21a82 100755 --- a/git-sh-setup.sh +++ b/git-sh-setup.sh @@ -142,3 +142,16 @@ then } : ${GIT_OBJECT_DIRECTORY="$GIT_DIR/objects"} fi + +# Fix some commands on Windows +case $(uname -s) in +*MINGW*) + # Windows has its own (incompatible) sort and find + sort () { + /usr/bin/sort "$@" + } + find () { + /usr/bin/find "$@" + } + ;; +esac -- 2.47.1