Git development
 help / color / mirror / Atom feed
From: "Shawn O. Pearce" <spearce@spearce.org>
To: Mark Struberg <struberg@yahoo.de>
Cc: git@vger.kernel.org
Subject: Re: does anything like cvs export exist in git?
Date: Thu, 14 Aug 2008 14:26:54 -0700	[thread overview]
Message-ID: <20080814212654.GS3782@spearce.org> (raw)
In-Reply-To: <977100.98240.qm@web27803.mail.ukl.yahoo.com>

Mark Struberg <struberg@yahoo.de> wrote:
> I'm the initial author of the Apache maven-scm-providers-git and
> I need to update our SCM-Matrix.
> 
> This is just for making sure I did not oversee anything.
> 
> I didn't came across anything like 'cvs export' and I do not
> think git really needs this, since it doesn't pollute the working
> directories with lots of waste like CVS and SVN does.
> 
> But I just want to make sure to not build workarounds in our
> scm-provider (checkout + afterwards blasting the GIT_DIR) for things
> that do exist natively in git.

You can use:

  git archive --tar HEAD | (mkdir ../dest;cd ../dest;tar xf -)

Or you can do something even more bizzare like:

  export GIT_INDEX_FILE=/tmp/$$.index;
  export GIT_WORK_TREE=../dest;
  export GIT_DIR=.git;
  git read-tree HEAD &&
  git checkout-index --force --all &&
  rm $GIT_INDEX_FILE

-- 
Shawn.

  parent reply	other threads:[~2008-08-14 21:27 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-08-14 21:20 does anything like cvs export exist in git? Mark Struberg
2008-08-14 21:23 ` Matthieu Moy
2008-08-14 21:46   ` Mark Struberg
2008-08-14 21:26 ` Shawn O. Pearce [this message]
2008-08-14 22:09   ` Mark Struberg
2008-08-14 22:12     ` Shawn O. Pearce
2008-08-14 22:44       ` Mark Struberg
2008-08-14 22:11 ` Petr Baudis
2008-08-14 22:31   ` Mark Struberg

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=20080814212654.GS3782@spearce.org \
    --to=spearce@spearce.org \
    --cc=git@vger.kernel.org \
    --cc=struberg@yahoo.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