git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Chris Pettitt <cpettitt@gmail.com>
To: Simon Hausmann <simon@lst.de>, Git Mailing List <git@vger.kernel.org>
Cc: Chris Pettitt <cpettitt@gmail.com>
Subject: [PATCH] git-p4 support for perforce renames.
Date: Mon, 15 Oct 2007 21:35:45 -0700	[thread overview]
Message-ID: <1192509345-21340-1-git-send-email-cpettitt@gmail.com> (raw)

The current git-p4 implementation does support file renames. However, because
it does not use the "p4 integrate" command, the history for the renamed file is
not linked to the new file.

This changeset adds support for perforce renames with the integrate command.
Currently this feature is only enabled when calling git-p4 submit with the -M
option. This is intended to look and behave similar to the "detect renames"
feature of other git commands.

The following sequence is used for renamed files:

    p4 integrate -Dt x x'
    p4 edit x'
    rm x'
    git apply
    p4 delete x

By default, perforce will not allow an integration with a target file that has
been deleted. That is, if x' in the example above is the name of a previously
deleted file then perforce will fail the integrate. The -Dt option tells
perforce to allow the target of integrate to be a previously deleted file.

Signed-off-by: Chris Pettitt <cpettitt@gmail.com>

 contrib/fast-import/git-p4 |   12 +++++++++++-
 1 files changed, 11 insertions(+), 1 deletions(-)
-- 
1.5.3.4.206.g58ba4

             reply	other threads:[~2007-10-16  4:36 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-10-16  4:35 Chris Pettitt [this message]
  -- strict thread matches above, loose matches on Subject: below --
2007-10-16  4:37 [PATCH] git-p4 support for perforce renames Chris Pettitt
     [not found] <de47e4420710152214k1e74bf5eh5ecbf48d0507322@mail.gmail.com>
2007-10-16  5:15 ` Chris Pettitt

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=1192509345-21340-1-git-send-email-cpettitt@gmail.com \
    --to=cpettitt@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=simon@lst.de \
    /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).