Git development
 help / color / mirror / Atom feed
From: Johannes Schindelin <Johannes.Schindelin@gmx.de>
To: Denis Bueno <dbueno@gmail.com>
Cc: Git Mailing List <git@vger.kernel.org>
Subject: Re: git cherry-pick before archive
Date: Fri, 11 Jul 2008 16:51:03 +0100 (BST)	[thread overview]
Message-ID: <alpine.DEB.1.00.0807111649290.8950@racer> (raw)
In-Reply-To: <6dbd4d000807110846m2921ddb9r88eb3986762b8f81@mail.gmail.com>

Hi,

On Fri, 11 Jul 2008, Denis Bueno wrote:

> I'm trying to use git archive to create a kind of "release" tarball of
> my source.  I've got a patch (a commit) that I'd like to apply to the
> tree before I call git archive on HEAD.  Currently my command is:
> 
>     git archive --format=tar --prefix=pfx/ HEAD | gzip > prj.tgz
> 
> If I were to actually modify my tree & history, I'd change the command to:
> 
>     git cherry-pick 97a1235ce674f7cf4df3129cd0ab1ae0793db392
>     git archive --format=tar --prefix=pfx/ HEAD | gzip > prj.tgz
>     git reset --hard HEAD^
> 
> But I'd rather not modify my history, if it's possible.  (This will
> create a bunch of dangling commit objects over time, no?)

$ git cherry-pick -n <bla>
$ git archive --format=tar --prefix=pfx/ $(git write-tree) | gzip > prj.tgz
$ git reset

Hth,
Dscho

  reply	other threads:[~2008-07-11 15:52 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-07-11 15:46 git cherry-pick before archive Denis Bueno
2008-07-11 15:51 ` Johannes Schindelin [this message]
2008-07-11 16:09   ` Denis Bueno
2008-07-11 16:11     ` Miklos Vajna
2008-07-11 16:18       ` Denis Bueno
2008-07-11 18:25       ` Johannes Schindelin
2008-07-11 18:28         ` Denis Bueno
2008-07-11 18:46           ` Johannes Schindelin
2008-07-11 18:49             ` Denis Bueno
2008-07-11 18:53               ` Johannes Schindelin
2008-07-11 22:18   ` 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=alpine.DEB.1.00.0807111649290.8950@racer \
    --to=johannes.schindelin@gmx.de \
    --cc=dbueno@gmail.com \
    --cc=git@vger.kernel.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