git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Darxus@chaosreigns.com
To: git@vger.kernel.org
Subject: git clone --update ?
Date: Fri, 7 Jan 2011 17:54:05 -0500	[thread overview]
Message-ID: <20110107225405.GH20411@chaosreigns.com> (raw)

I'm working on a build script that pulls source from 12 git repos:
http://www.chaosreigns.com/wayland/wayland-build-ubuntu-all.sh

I would like to be able to do the equivalent of:

 rm -rf gtk+; git clone git://git.gnome.org/gtk+ --branch gdk-backend-wayland

Without re-downloading the entire thing.  Even if I made any kind of
modifications to the repo.

One suggestion I've gotten was;

  git checkout gdk-backend-wayland && git fetch git://git.gnome.org/gtk+ gdk-backend-wayland && git reset --hard FETCH_HEAD && git clean -fxd

Possibly replacing the branch name with HEAD if I want the default branch.

It would be nice if, instead, I could just run something like:

  git clone --update git://git.gnome.org/gtk+ --branch gdk-backend-wayland

Bonus points for working if I have not already cloned it.

             reply	other threads:[~2011-01-07 23:04 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-01-07 22:54 Darxus [this message]
2011-01-07 23:41 ` git clone --update ? Zenaan Harkness

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=20110107225405.GH20411@chaosreigns.com \
    --to=darxus@chaosreigns.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).