git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "ryenus ◇" <ryenus@gmail.com>
To: Junio C Hamano <gitster@pobox.com>
Cc: "Nguyen Thai Ngoc Duy" <pclouds@gmail.com>,
	"René Scharfe" <rene.scharfe@lsrfire.ath.cx>,
	git@vger.kernel.org
Subject: Re: [PATCH] repack: find -> /usr/bin/find, as for cygwin
Date: Sun, 20 Mar 2011 08:31:38 +0800	[thread overview]
Message-ID: <AANLkTinPCeg3NU2bRvk8rwWSWnu4b0PHwya9+PWAc3DB@mail.gmail.com> (raw)
In-Reply-To: <7vsjujq8kf.fsf@alter.siamese.dyndns.org>

I'm not sure if there's a set of tests for Cygwin/MinGW among all the
test cases in GIT, here is a simple one:

#!/bin/sh
echo $(uname -s)
case $(uname -s) in
*MINGW*|*CYGWIN*)
  echo "detected MinGW/Cygwin"
  ;;
*MinGW*)
  echo "detected MinGW"
  ;;
*Cygwin*)
  echo "detected Cygwin"
  ;;
esac

Run with dash, the output is

CYGWIN_NT-6.1
detected MinGW/Cygwin

While I don't have MinGW, so someone has it please give it a shot.

Thanks

2011/3/20 Junio C Hamano <gitster@pobox.com>:
> ryenus ◇ <ryenus@gmail.com> writes:
>
>> Thank you, Duy, you're almost right, I just checked git-sh-setup.sh,
>> in the bottom, sort and find are defined as functions like what you
>> pointed out, but only for MinGW, therefore a better fix is to check
>> for cygwin as well:
>>
>> ---
>>  git-sh-setup.sh |    2 +-
>>  1 files changed, 1 insertions(+), 1 deletions(-)
>>
>> diff --git a/git-sh-setup.sh b/git-sh-setup.sh
>> index aa16b83..5c52ae4 100644
>> --- a/git-sh-setup.sh
>> +++ b/git-sh-setup.sh
>> @@ -227,7 +227,7 @@ fi
>>
>>  # Fix some commands on Windows
>>  case $(uname -s) in
>> -*MINGW*)
>> +*MINGW*|*CYGWIN*)
>
> This looks like a more sensible alternative than forbidding the use of
> "find", privided if the new pattern is an appropriate one to catch cygwin.
>
> I don't have any Windows boxes, so I cannot verify, but the patch smells
> correct.
>
>
>

  reply	other threads:[~2011-03-20  0:32 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-03-19 12:08 [PATCH] repack: find -> /usr/bin/find, as for cygwin ryenus ◇
2011-03-19 12:18 ` Nguyen Thai Ngoc Duy
2011-03-19 15:50   ` René Scharfe
2011-03-19 16:07     ` Nguyen Thai Ngoc Duy
2011-03-19 16:15       ` Nguyen Thai Ngoc Duy
2011-03-19 16:32   ` ryenus ◇
2011-03-19 16:43     ` ryenus ◇
2011-03-19 16:47       ` Nguyen Thai Ngoc Duy
2011-03-19 18:17     ` Junio C Hamano
2011-03-20  0:31       ` ryenus ◇ [this message]
2011-03-20  0:35         ` ryenus ◇
2011-03-20  7:48           ` Matthieu Moy
2011-03-20  8:42             ` ryenus ◇
2011-03-21  9:36           ` Erik Faye-Lund

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=AANLkTinPCeg3NU2bRvk8rwWSWnu4b0PHwya9+PWAc3DB@mail.gmail.com \
    --to=ryenus@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=pclouds@gmail.com \
    --cc=rene.scharfe@lsrfire.ath.cx \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).