From: Johnny Stenback <jst@jstenback.com>
To: Linus Torvalds <torvalds@osdl.org>
Cc: git@vger.kernel.org
Subject: Re: git commit (or git-commit-script) question
Date: Fri, 19 Aug 2005 10:44:52 -0700 [thread overview]
Message-ID: <43061A94.9030002@jstenback.com> (raw)
In-Reply-To: <Pine.LNX.4.58.0508191028190.3412@g5.osdl.org>
Ah, that explains it. I had already marked all my changes for update,
that's what threw me off here. Thanks!
Linus Torvalds wrote:
>
> On Fri, 19 Aug 2005, Johnny Stenback wrote:
>> That made me assume that if I do:
>>
>> git-commit-script somedir
>>
>> it would *only* commit the changes I've made in "somedir", but it
>> appears to commit *all* files that have changed (and shows all files in
>> the list of changed files in the commit message it displays in the
>> editor), as if it's completely ignoring the <path> argument.
>>
>> Known problem? I got this using git that I pulled from kernel.org
>> earlier this morning.
>
> It works for me. You _should_ see something like
>
> #
> # Updated but not checked in:
> # (will commit)
> #
> # modified: somedir/somefile
> #
> #
> # Changed but not updated:
> # (use git-update-cache to mark for commit)
> #
> # modified: otherdir/anotherfile
> #
>
> which basically means that it will commit "somedir/somefile", but _not_
> commit "otherdir/anotherfile".
>
> However, one thing to look out for is that if you've marked any files for
> update (with git-update-cache) those will always be committed regardless
> of what arguments you give to "git commit". You can reset the index with
> "git reset" if you decided that you don't want to commit after all.
>
> (For example, if you do a "git commit --all", but decide not to commit
> after all by writing an empty commit message, that will already have
> marked all the files to be committed, so next time, even if you then use
> "git commit somedir", all the files in all the _other_ dirs have already
> been marked for update, so you'll see everything being committed).
>
> Linus
> -
> 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
>
--
jst
next prev parent reply other threads:[~2005-08-19 17:45 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-08-19 17:06 git commit (or git-commit-script) question Johnny Stenback
2005-08-19 17:36 ` Linus Torvalds
2005-08-19 17:44 ` Johnny Stenback [this message]
2005-08-19 19:52 ` Junio C Hamano
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=43061A94.9030002@jstenback.com \
--to=jst@jstenback.com \
--cc=git@vger.kernel.org \
--cc=torvalds@osdl.org \
/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).