git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Luke Diamand <luke@diamand.org>
To: git@vger.kernel.org
Cc: "SZEDER Gábor" <szeder.dev@gmail.com>,
	"Chen Bin" <chenbin.sh@gmail.com>,
	"Miguel Torroja" <miguel.torroja@gmail.com>,
	"George Vanburgh" <gvanburgh@bloomberg.net>,
	"Merland Romain" <merlorom@yahoo.fr>,
	"Vinicius Kursancew" <viniciusalexandre@gmail.com>,
	larsxschneider@gmail.com, "Lex Spoon" <lex@lexspoon.org>,
	"Luke Diamand" <luke@diamand.org>
Subject: [PATCHv1 0/3] git-p4: improved unshelving
Date: Fri, 12 Oct 2018 06:28:30 +0100	[thread overview]
Message-ID: <20181012052833.6945-1-luke@diamand.org> (raw)

This patch series teaches the git-p4 unshelve command to handle
intervening changes to the Perforce files.

At the moment if you try to unshelve a file, and that file has been
modified since the shelving, git-p4 refuses. That is so that it
doesn't end up generating a commit containing deltas from several P4
changes.

This gets to be more annoying as time goes on and the files you are
interested in get updated by other people.

However, what we can do is to create a parent commit matching the
state of the tree when the shelve happened, which then lets git-p4
create a git commit containing just the changes that are wanted.

It's still impossible to determine the true state of the complete
tree when the P4 shelve was created, since this information is not
recorded by Perforce. Manual intervention is required to fix that.

There are also a few other smaller fixes, the main one being
that it no longer unshelves into refs/remotes/p4/master/unshelved, but
instead into refs/remotes/p4-unshelved.

That's because the git-p4 branch detection gets confused by branches
appearing in refs/remotes/p4.


Luke Diamand (3):
  git-p4: do not fail in verbose mode for missing 'fileSize' key
  git-p4: unshelve into refs/remotes/p4-unshelved, not
    refs/remotes/p4/unshelved
  git-p4: fully support unshelving changelists

 Documentation/git-p4.txt | 10 ++---
 git-p4.py                | 90 +++++++++++++++++++++++-----------------
 t/t9832-unshelve.sh      | 75 ++++++++++++++++++++++++++-------
 3 files changed, 117 insertions(+), 58 deletions(-)

-- 
2.19.1.272.gf84b9b09d4


             reply	other threads:[~2018-10-12  5:28 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-10-12  5:28 Luke Diamand [this message]
2018-10-12  5:28 ` [PATCHv1 1/3] git-p4: do not fail in verbose mode for missing 'fileSize' key Luke Diamand
2018-10-12  5:28 ` [PATCHv1 2/3] git-p4: unshelve into refs/remotes/p4-unshelved, not refs/remotes/p4/unshelved Luke Diamand
2018-10-12 13:45   ` Junio C Hamano
2018-10-12 18:19     ` Luke Diamand
2018-10-15 11:03       ` Luke Diamand
2018-10-12  5:28 ` [PATCHv1 3/3] git-p4: fully support unshelving changelists Luke Diamand

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

  List information: http://vger.kernel.org/majordomo-info.html

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

  git send-email \
    --in-reply-to=20181012052833.6945-1-luke@diamand.org \
    --to=luke@diamand.org \
    --cc=chenbin.sh@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gvanburgh@bloomberg.net \
    --cc=larsxschneider@gmail.com \
    --cc=lex@lexspoon.org \
    --cc=merlorom@yahoo.fr \
    --cc=miguel.torroja@gmail.com \
    --cc=szeder.dev@gmail.com \
    --cc=viniciusalexandre@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.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).