git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Imre Deak" <imre.deak@gmail.com>
To: git@vger.kernel.org
Subject: git-am: can't apply to an empty repository
Date: Wed, 8 Oct 2008 16:24:27 +0300	[thread overview]
Message-ID: <500f3d130810080624g23b4ed1ckde5d63082dca9040@mail.gmail.com> (raw)

When trying to build a repository from mbox format patches I have the
following problem:

Creating a hypothetical mbox patch:

$ echo "From: imre deak <imre.deak@gmail.com>" > 1.patch
$ touch a
$ git diff --no-index /dev/null a >> 1.patch
$ cat 1.patch
From: imre deak <imre.deak@gmail.com>
diff --git a/a b/a
new file mode 100644
index 0000000..e69de29

Apply it to a newly created repository:

$ git init
Initialized empty Git repository in /home/imde/conv/git/.git/
$ git am 1.patch
fatal: HEAD: not a valid SHA1
fatal: bad revision 'HEAD'

Is this supposed to work at all?

--Imre

                 reply	other threads:[~2008-10-08 13:25 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=500f3d130810080624g23b4ed1ckde5d63082dca9040@mail.gmail.com \
    --to=imre.deak@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;
as well as URLs for NNTP newsgroup(s).