Git development
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: git@vger.kernel.org
Cc: しらいしななこ <nanako3@bluebottle.com>,
	"Johannes Schindelin" <Johannes.Schindelin@gmx.de>
Subject: [PATCH 0/2] git-stash last-minute fixes
Date: Fri, 27 Jul 2007 23:59:45 -0700	[thread overview]
Message-ID: <7vbqdxui72.fsf@assigned-by-dhcp.cox.net> (raw)

Here are a small patch series to git-stash.

 [1/2] Fix git-stash apply --index

 This fixes two rather embarrasing bugs in "apply --index".

 [2/2] git-stash apply --index: optimize postprocessing

 This builds on top of the previous one to avoid unnecessary
 index manipulations that is later wiped by a read-tree.

There also is a bugfix I received privately from Nana for the
breakage I introduced with 7ab3cc70.  I've already queued it for
'master'.

-- >8 --

From: しらいしななこ <nanako3@bluebottle.com>
Date: Sat, 28 Jul 2007 10:44:48 +0900
Subject: [PATCH] git-stash: Make sure reflog is created for refs/stash

Earlier commit 7ab3cc70 fixed "stash clear" but broke save_stash,
because it forgot to make sure the reflog file exists before saving.

Signed-off-by: Nanako Shiraishi <nanako3@bluebottle.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

diff --git a/git-stash.sh b/git-stash.sh
index f90dffd..0073e9d 100755
--- a/git-stash.sh
+++ b/git-stash.sh
@@ -36,6 +36,9 @@ save_stash () {
 	test -f "$GIT_DIR/logs/$ref_stash" ||
 		clear_stash || die "Cannot initialize stash"
 
+	# Make sure the reflog for stash is kept.
+	: >>"$GIT_DIR/logs/$ref_stash"
+
 	# state of the base commit
 	if b_commit=$(git rev-parse --verify HEAD)
 	then

             reply	other threads:[~2007-07-28  7:00 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-07-28  6:59 Junio C Hamano [this message]
2007-07-28  7:02 ` [PATCH 1/2] Fix git-stash apply --index Junio C Hamano
2007-07-28  7:02 ` [PATCH 2/2] git-stash apply --index: optimize postprocessing Junio C Hamano
2007-07-28  9:06 ` [PATCH 0/2] git-stash last-minute fixes しらいしななこ

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=7vbqdxui72.fsf@assigned-by-dhcp.cox.net \
    --to=gitster@pobox.com \
    --cc=Johannes.Schindelin@gmx.de \
    --cc=git@vger.kernel.org \
    --cc=nanako3@bluebottle.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