From: "J. Bakshi" <joydeep@infoservices.in>
To: "Carlos Martín Nieto" <cmn@elego.de>
Cc: git@vger.kernel.org
Subject: Re: git with detached worktrees , push has no effect
Date: Fri, 15 Jul 2011 10:55:40 +0530 [thread overview]
Message-ID: <20110715105540.314304d1@shiva.selfip.org> (raw)
In-Reply-To: <1310647767.6041.73.camel@centaur.lab.cmartin.tk>
On Thu, 14 Jul 2011 14:49:27 +0200
Carlos Martín Nieto <cmn@elego.de> wrote:
> On Thu, 2011-07-14 at 18:10 +0530, J. Bakshi wrote:
> [...] snip snip snip
> > warning: You appear to have cloned an empty repository.
> >
> > touch A
> > git add A
> >
> > git commit -m "add A"
> >
> > [master (root-commit) 7662edd] add A
> > 0 files changed, 0 insertions(+), 0 deletions(-)
> > create mode 100644 A
> >
> > git push
> > Username:
> > Password:
> > Everything up-to-date
> >
> >
> > Why reports [Everything up-to-date] rather than modify the remote git ?
>
> That's because your remote repository has no branches and per default
> git-push will only push matching branches; as no branches match, there
> is nothing to do. This is what "warning: You appear to have cloned an
> empty repository." is trying to tell you (the message could certainly be
> made much more friendly). Your master branch in this case doesn't exist
> in the server, so you have to tell git to push it explicitly.
>
> git push origin master
>
> will do the trick.
>
GRAET !!
Working like a charm and the hook is also working fine. Can we make the
empty master branch at the server, so that client can continue with plain "git push" ?
Thanks
next prev parent reply other threads:[~2011-07-15 5:25 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-07-14 12:40 git with detached worktrees , push has no effect J. Bakshi
2011-07-14 12:49 ` Carlos Martín Nieto
2011-07-15 5:25 ` J. Bakshi [this message]
2011-07-15 5:26 ` J. Bakshi
2011-07-15 19:24 ` Carlos Martín Nieto
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=20110715105540.314304d1@shiva.selfip.org \
--to=joydeep@infoservices.in \
--cc=cmn@elego.de \
--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).