* [PATCH 1/2] Documentation: Remove deprecated --mixed option in git-reset synopsis
@ 2008-02-16 16:48 Pieter de Bie
2008-02-16 16:48 ` [PATCH 2/2] Documentation: Add a usage case of git-reset with path Pieter de Bie
2008-02-16 19:15 ` [PATCH 1/2] Documentation: Remove deprecated --mixed option in git-reset synopsis Junio C Hamano
0 siblings, 2 replies; 6+ messages in thread
From: Pieter de Bie @ 2008-02-16 16:48 UTC (permalink / raw)
To: gitster, git; +Cc: Pieter de Bie
And while we're at it, use the dashless git call
Signed-off-by: Pieter de Bie <pdebie@ai.rug.nl>
---
Documentation/git-reset.txt | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/Documentation/git-reset.txt b/Documentation/git-reset.txt
index a4e0a77..2b24641 100644
--- a/Documentation/git-reset.txt
+++ b/Documentation/git-reset.txt
@@ -8,8 +8,8 @@ git-reset - Reset current HEAD to the specified state
SYNOPSIS
--------
[verse]
-'git-reset' [--mixed | --soft | --hard] [-q] [<commit>]
-'git-reset' [--mixed] [-q] [<commit>] [--] <paths>...
+'git reset' [--mixed | --soft | --hard] [-q] [<commit>]
+'git reset' [-q] [<commit>] [--] <paths>...
DESCRIPTION
-----------
--
1.5.4.3.gb183
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [PATCH 2/2] Documentation: Add a usage case of git-reset with path
2008-02-16 16:48 [PATCH 1/2] Documentation: Remove deprecated --mixed option in git-reset synopsis Pieter de Bie
@ 2008-02-16 16:48 ` Pieter de Bie
2008-02-16 18:40 ` Junio C Hamano
2008-02-16 19:15 ` [PATCH 1/2] Documentation: Remove deprecated --mixed option in git-reset synopsis Junio C Hamano
1 sibling, 1 reply; 6+ messages in thread
From: Pieter de Bie @ 2008-02-16 16:48 UTC (permalink / raw)
To: gitster, git; +Cc: Pieter de Bie
Signed-off-by: Pieter de Bie <pdebie@ai.rug.nl>
---
Documentation/git-reset.txt | 17 +++++++++++++++++
1 files changed, 17 insertions(+), 0 deletions(-)
diff --git a/Documentation/git-reset.txt b/Documentation/git-reset.txt
index 2b24641..39a9d64 100644
--- a/Documentation/git-reset.txt
+++ b/Documentation/git-reset.txt
@@ -176,6 +176,23 @@ $ git reset <3>
committed as 'snapshot WIP'. This updates the index to show your
WIP files as uncommitted.
+Reset a single file in the index::
++
+Suppose you have added a file to your index, but later decide you do not
+want to add it to your commit. You can remove the file from the index
+while keeping your changes with git reset.
++
+------------
+$ git reset -- frotz.c <1>
+$ git commit -m "Commit files in index" <2>
+$ git add frotz.c <3>
+------------
++
+<1> This removes the file from the index while keeping it in the working
+ directory.
+<2> This commits all other changes in the index.
+<3> Adds the file to the index again.
+
Author
------
Written by Junio C Hamano <junkio@cox.net> and Linus Torvalds <torvalds@osdl.org>
--
1.5.4.3.gb183
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH 2/2] Documentation: Add a usage case of git-reset with path
2008-02-16 16:48 ` [PATCH 2/2] Documentation: Add a usage case of git-reset with path Pieter de Bie
@ 2008-02-16 18:40 ` Junio C Hamano
0 siblings, 0 replies; 6+ messages in thread
From: Junio C Hamano @ 2008-02-16 18:40 UTC (permalink / raw)
To: Pieter de Bie; +Cc: git
Pieter de Bie <pdebie@ai.rug.nl> writes:
> @@ -176,6 +176,23 @@ $ git reset <3>
> committed as 'snapshot WIP'. This updates the index to show your
> WIP files as uncommitted.
>
> +Reset a single file in the index::
Yeah, an example and description for this relatively new feature
has been lacking. Very mucuh appreciated.
By the way, I noticed a leftover from our ancient past.
-- >8 --
[PATCH] Documentation/git-reset:
Since 3368d11 (Remove unnecessary git-rm --cached reference from
status output), the status output marks the "Added but not yet
committed" section as "Changes to be committed".
Signed-off-by: Junio C Hamano <gitster@pobox.com>
---
Documentation/git-reset.txt | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/Documentation/git-reset.txt b/Documentation/git-reset.txt
index a4e0a77..b6bcf4d 100644
--- a/Documentation/git-reset.txt
+++ b/Documentation/git-reset.txt
@@ -37,7 +37,7 @@ OPTIONS
--soft::
Does not touch the index file nor the working tree at all, but
requires them to be in a good order. This leaves all your changed
- files "Added but not yet committed", as linkgit:git-status[1] would
+ files "Changes to be committed", as linkgit:git-status[1] would
put it.
--hard::
--
1.5.4.1.1350.g2b9ee
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH 1/2] Documentation: Remove deprecated --mixed option in git-reset synopsis
2008-02-16 16:48 [PATCH 1/2] Documentation: Remove deprecated --mixed option in git-reset synopsis Pieter de Bie
2008-02-16 16:48 ` [PATCH 2/2] Documentation: Add a usage case of git-reset with path Pieter de Bie
@ 2008-02-16 19:15 ` Junio C Hamano
2008-02-16 19:17 ` Pieter de Bie
1 sibling, 1 reply; 6+ messages in thread
From: Junio C Hamano @ 2008-02-16 19:15 UTC (permalink / raw)
To: Pieter de Bie; +Cc: git
Thanks, but the title should read "redundant, unnecessary", not
"deprecated", I think.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH 1/2] Documentation: Remove deprecated --mixed option in git-reset synopsis
2008-02-16 19:15 ` [PATCH 1/2] Documentation: Remove deprecated --mixed option in git-reset synopsis Junio C Hamano
@ 2008-02-16 19:17 ` Pieter de Bie
2008-02-16 20:10 ` Junio C Hamano
0 siblings, 1 reply; 6+ messages in thread
From: Pieter de Bie @ 2008-02-16 19:17 UTC (permalink / raw)
To: Junio C Hamano; +Cc: git
On Feb 16, 2008, at 8:15 PM, Junio C Hamano wrote:
> Thanks, but the title should read "redundant, unnecessary", not
> "deprecated", I think.
Well, if I run it:
bash-3.2$ git reset --mixed -- NEWS
warning: --mixed option is deprecated with paths.
I included deprecated because it says so in the warning
- Pieter
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH 1/2] Documentation: Remove deprecated --mixed option in git-reset synopsis
2008-02-16 19:17 ` Pieter de Bie
@ 2008-02-16 20:10 ` Junio C Hamano
0 siblings, 0 replies; 6+ messages in thread
From: Junio C Hamano @ 2008-02-16 20:10 UTC (permalink / raw)
To: Pieter de Bie; +Cc: git
Pieter de Bie <pdebie@ai.rug.nl> writes:
> Well, if I run it:
>
> bash-3.2$ git reset --mixed -- NEWS
> warning: --mixed option is deprecated with paths.
Yeah, you are right.
The patch is on 'maint' (but it will be quite a while before I
can push it out).
Thanks.
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2008-02-16 20:11 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-02-16 16:48 [PATCH 1/2] Documentation: Remove deprecated --mixed option in git-reset synopsis Pieter de Bie
2008-02-16 16:48 ` [PATCH 2/2] Documentation: Add a usage case of git-reset with path Pieter de Bie
2008-02-16 18:40 ` Junio C Hamano
2008-02-16 19:15 ` [PATCH 1/2] Documentation: Remove deprecated --mixed option in git-reset synopsis Junio C Hamano
2008-02-16 19:17 ` Pieter de Bie
2008-02-16 20:10 ` Junio C Hamano
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).