From: Francis Galiegue <fg@one2team.com>
To: Junio C Hamano <gitster@pobox.com>
Cc: Jakub Narebski <jnareb@gmail.com>, git@vger.kernel.org
Subject: Re: Init on push
Date: Sat, 8 Nov 2008 21:44:25 +0100 [thread overview]
Message-ID: <200811082144.25261.fg@one2team.com> (raw)
In-Reply-To: <7v3ai2c5sd.fsf@gitster.siamese.dyndns.org>
Le Saturday 08 November 2008 21:38:10 Junio C Hamano, vous avez écrit :
> Francis Galiegue <fg@one2team.com> writes:
> > Le Saturday 08 November 2008 21:06:01 Jakub Narebski, vous avez écrit :
> >> Junio C Hamano wrote:
> >> > - Teach "-D $there" option to "git init", which does an "mkdir -p $it
> >> > && chdird $it" before it does its work.
> >>
> >> Shouldn't it be "-C $there" (like make and tar)?
> >
> > I agree with that. It's pretty much a standard for quite a few "command
> > line people", insofar as I always look for such an option in case I want
> > to know whether a command has the ability to chdir() to a different
> > directory than the current one :p
>
> In this particular case, it is not "chdir() before starting" but "mkdir
> and then chdir() into it". Using -C would be counterproductive.
> --
> To unsubscribe from this list: send the line "unsubscribe git" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
I have missed the mkdir part, but then here this is mkdir _-p_...
I mean, what is the cost of mkdir -p the/dir and then git init -C the/dir? I
don't think it's that good an idea to have git create the directory in this
case...
Think of what would happen if you git -D a/b, and a is a symlink to, where,
somewhere (doesn't exist, exists but if you touch it you're {in trouble,good
for jail time, whatever}).
I personnaly think that the directory creation SHOULD be created to the
commands that are meant for it, just as git handles dir creation in its own
space (a git repository).
--
Francis Galiegue
ONE2TEAM
Ingénieur système
Mob : +33 (0) 6 83 87 78 75
Tel : +33 (0) 1 78 94 55 52
fge@one2team.com
40 avenue Raymond Poincaré
75116 Paris
next prev parent reply other threads:[~2008-11-08 20:48 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-11-08 16:08 Init on push Robin Rosenberg
2008-11-08 19:26 ` Junio C Hamano
2008-11-08 20:01 ` Alexander Gavrilov
2008-11-08 20:12 ` Junio C Hamano
2008-11-08 20:06 ` Jakub Narebski
2008-11-08 20:08 ` Francis Galiegue
2008-11-08 20:38 ` Junio C Hamano
2008-11-08 20:44 ` Francis Galiegue [this message]
2008-11-08 20:50 ` Francis Galiegue
2008-11-09 0:13 ` Junio C Hamano
2008-11-09 1:41 ` Francis Galiegue
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=200811082144.25261.fg@one2team.com \
--to=fg@one2team.com \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=jnareb@gmail.com \
/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