• HTTP Cloning

    defunkt 18 Jun 2008

    You can now clone public repositories hosted on GitHub over HTTP. This is very slow and should only be used if the git port (9418) is blocked due to a firewall or other tomfoolery.

    Try it out:

    git clone http://github.com/defunkt/facebox.git

    If you’re a Ruby on Rails user, you can now install plugins without Git installed on your machine. This means your loyal blog readers stuck in the past don’t need Git to benefit from your Ruby wizardry.

    Try it out:

    ./script/plugin install http://github.com/defunkt/cache_fu.git

  • Comments

    pjhyett Wed Jun 18 18:56:12 -0700 2008

    Spectacular, especially like the plugin part.

    zerok Thu Jun 19 00:07:28 -0700 2008

    Thank you very much :D Now I can finally also clone repos from at home.

    aunderwo Thu Jun 19 01:49:27 -0700 2008

    I get an error with this. Any ideas?

    git clone http://github.com/jandot/sprolog.git Initialized empty Git repository in /tmp/sprolog/.git/ Getting alternates list for http://github.com/jandot/sprolog.git Getting pack list for http://github.com/jandot/sprolog.git error: The requested URL returned error: 500 error: Unable to find 18e12606451c23e03d1d117181db047230ed59bc under http://github.com/jandot/sprolog.git Cannot obtain needed object 18e12606451c23e03d1d117181db047230ed59bc

    defunkt Thu Jun 19 08:24:20 -0700 2008

    @aunderwo I just tried it and it worked for me. Are you still having problems?

    gaffo Thu Jun 19 09:02:44 -0700 2008

    The suited masses thank you.

    scudco Thu Jun 19 14:50:50 -0700 2008

    Thank you thank you thank you!

    myabc Fri Jun 20 07:20:39 -0700 2008

    Are there plans to add this to the UI?

    lgs Fri Jun 20 14:00:13 -0700 2008

    I’m having the same problem as aunderwo. Just work for defunkt examples (facebox and cache_fu) but not for “mephisto”, “hobo” and other plugins. Here some outputs : http://pastie.org/219140

    jonbrenner Thu Jun 26 20:46:10 -0700 2008

    Hooray! <3

    andreasW Tue Jul 01 12:04:08 -0700 2008

    Does not work for me. Around here (as I am sure many other places) we have an HTTP proxy server to keep out YouTube, Facebook, Sports sites and worse….

    I assume that that is why the above still won’t work for me. Any relief in sight for that? Every widely used on-line protocol has support for firewalls and proxies, without you could not become or stay widely used.

    Andreas

    kornysietsma Mon Jul 21 20:02:12 -0700 2008

    It works for me, behind an authenticating http proxy, as long as I set a “http_proxy” environment variable, and make sure ‘curl’ is installed.

    However script/plugin does not work – it fails with an error: shallow over http or ftp not supported (git version 1.5.4.3 on Ubuntu 8.04)

    pbhogan Wed Aug 13 09:10:59 -0700 2008

    Works with facebox, but not on my mine. This is the error I get: $ git clone http://github.com/pbhogan/datagrid.git Initialized empty Git repository in /Library/WebServer/Documents/datagrid/.git/ Cannot get remote repository information. Perhaps git-update-server-info needs to be run there? … Any ideas?

    paynerc Tue Sep 23 11:17:14 -0700 2008

    To alleviate the “shallow over http or ftp not supported” error, do this instead:

    ./script/plugin install git://github.com/defunkt/cache_fu.git

    jamesarosen Wed Sep 24 08:36:56 -0700 2008

    I’m getting what seems to be the same problem as @aunderwo and @lgs. The commonality seems to be “Cannot obtain needed _____” (“tree,” “blob,” “object,” etc.).

    I’m also behind a proxy, and I have http_proxy set. c:\…> echo HTT_PROXY http://proxy:80

    lgs Mon Dec 08 13:32:03 -0800 2008

    Hi there, I get a “git clone http error”, trying to clone http://github.com/emk/mephisto.git :

    error: Unable to find e9fc1471b8f368184b9197dd1d37599a4efa4c22 under http://github.com/emk/mephisto.git Cannot obtain needed object e9fc1471b8f368184b9197dd1d37599a4efa4c22

    ( see the full trace: http://gist.github.com/33623 )

    Does anybody know what’s the matter with that ? Any suggestion will be appreciate, thanks in advance luca

    nimms Tue Dec 16 17:08:33 -0800 2008

    If you’re stuck behind an ISA proxy server using ntlm auth, use ntlmaps to set up a proxy which git will understand. (http://ntlmaps.sourceforge.net/). You need python to run it.

    then set git config -global http.proxy http://127.0.0.1:5865 http cloning then works like a charm

    gaving Mon Jan 05 10:22:31 -0800 2009

    Same errors as the few people above. Not even behind a proxy.

    On some repos just getting hit with:

    seth:~/Sandbox% git clone http://github.com/vimmpc/dotfiles.git Initialized empty Git repository in /Users/gavin/Sandbox/vimmpc/.git/ fatal: http://github.com/gaving/vimmpc.git/info/refs download error – The requested URL returned error: 500

    On others it gets so far then just dies:

    error: Unable to find abbb806fe93318f7ecccf9def8905f88cb6c27bc under http://github.com/gaving/dotfiles.git Cannot obtain needed tree abbb806fe93318f7ecccf9def8905f88cb6c27bc while processing commit 2ab6e523adc2e01e807a99979d328ec9ef5e883b. fatal: Fetch failed.

    :(

    tiefox Tue Jan 27 08:04:48 -0800 2009

    I’m also getting this “Cannot obtain needed blob” error, even withou any proxy…

    gpampara Tue Feb 17 01:06:18 -0800 2009

    I know that this is a current issue that is being addressed, but any update on the status of this?

    rdp Wed Feb 25 14:43:36 -0800 2009

    seems to still be broken [though does work for the example in the post]

    C:\dev\downloads>git clone http://github.com/oneclick/rubyinstaller.git Initialized empty Git repository in C:/dev/downloads/rubyinstaller/.git/ fatal: http://github.com/oneclick/rubyinstaller.git/info/refs download error – The requested URL returned error: 500

    tvisher Thu Feb 26 14:11:24 -0800 2009

    Any updates on this?

    ankopainting Wed Jun 03 20:17:53 -0700 2009
    script/plugin install http://github.com/xgamerx/conditions_fu.git
    Initialized empty Git repository in /home/sysnjk/rails/lists/vendor/plugins/conditions_fu/.git/ 
    warning: Option "depth" is ignored for http://github.com/xgamerx/conditions_fu.git
    
    fatal: http://github.com/xgamerx/conditions_fu.git/info/refs not found: did you run git update-server-info on the server?
    

    any ideas?

    georgechemy Mon Sep 14 23:12:25 -0700 2009

    Three things must be done. First, you must discover how Ubuntu refers to the hard disks. Second, you must install ddrescue and then use it to clone the disk. Third, once ddrescue has finished, you must use the Gparted utility to expand the disk partition(s) (assuming that the new disk is bigger than the old one, which is almost certainly going to be the reason for upgrading in the first place) search engine marketing.

    It's not a good idea to clone a hard disk that's in use (any more than it's a good idea to repair a car while it's being driven), so you must use your Ubuntu install CD's live distro mode. To carry out the following instructions, boot from your Ubuntu install CD, and select Try Ubuntu from the boot menu.

    Note that all the following stages are carried out using the Ubuntu install CD's live distro mode. At no point in the process do you need to boot into your standard Ubuntu installation, apart from to test the cloned disk at the end.
    Preparing to clone

    Before starting, it's a good idea to do three things in preparation. First, back up all valuable personal files to CD/DVD-R/RW disc, a USB keystick, or an external hard disk. The instructions that follow involve drastic fundamental disk management and the possibility of data loss.

    Second, it's a good idea to check the filesystem of the original hard disk for errors and possibly enact repairs. Ideally, you should check the Windows filesystem for errors too.

    Third, remove any USB memory sticks, card readers, or other kinds of attachable storage, such as MP3 players or mobile phones. This will avoid confusion when partitioning domain names.

    After all this, open a terminal window, and type the command sudo fdisk -l, which will scan the hard disks and list their partitions. Here are the results from my test system:

    Two hard disks are listed in the results: look for the headings Disk /dev/sda and Disk /dev/sdb. Beneath each heading is technical information about the disk, and beneath that the partitions on that disk are listed.

    It should be obvious that, on my test computer, /dev/sdb is the new hard disk because it has no partitions (it "doesn't contain a valid partition table"), while /dev/sda has the standard partition layout of an Ubuntu system. Yours will probably be similar, if not identical.

    Look for the reference to your new hard disk and make a note of it. In my case, I make a note of /dev/sdb. Then type sudo cfdisk -z /dev/sdb to start the cfdisk partitioning program, which we'll use to write an initial partition table to the disk. If necessary, replace /dev/sdb with the details of the new hard disk you discovered earlier. When cfdisk starts, type W (note that's Shift+w) and then type yes to write a blank partition table website design. Then press q to quit cfdisk. You can ignore the handful of minor errors that are reported.
    Cloning the disk

    Now that we have this information, we can install ddrescue and use it to clone the disk. This needs to be installed because it isn't a default system tool. Although the computer is running the Ubuntu install CD live distro mode, it's still possible to install additional software from the online repositories. However, before doing this, it's necessary to enable the Universe software repository (of course, you will need to use NetworkManager to get online too, if you haven't already). Click System -> Administration -> Software Sources, and put a check in the box alongside Community-maintained Open Source software (universe). Then click the Close button, and agree to refresh the list of software when asked.

    After this, type sudo apt-get install gddrescue at the prompt to install ddrescue.

    Use ddrescue by first specifying the old hard disk, then the new hard disk. Add the -v command option to provide a status report as the command progresses:

    EddyJhon Thu Sep 24 05:52:12 -0700 2009

    Look for the reference to your new hard disk and make a note of it. In my case, I make a note of /dev/sdb. Then type sudo cfdisk -z /dev/sdb to start the cfdisk partitioning program, which we'll use to write an initial partition table to the disk.
    Master Degree | fire degree | Education degree

    EddyJhon Thu Sep 24 05:53:07 -0700 2009

    Now that we have this information, we can install ddrescue and use it to clone the disk. This needs to be installed because it isn't a default system tool.
    management school | Law schools

    victor11 Wed Sep 30 01:18:06 -0700 2009

    Now i can very easily clone the repos at home, thanks for sharing.
    Wedding Dresses
    Wedding Flowers

    biladam Wed Oct 07 03:28:25 -0700 2009

    My git port (9418) is not blocked but there is still problem and i am unable to find any solution. I am working for a website design company and have installed a web server and this may be a cause of this. Is it?

    TonyParker Thu Oct 08 08:57:11 -0700 2009

    Use ddrescue by first specifying the old hard disk, then the new hard disk. Add the -v command option to provide a status report as the command progresses: Cialis online

    tomfeinberg Tue Oct 13 05:51:17 -0700 2009

    Thanks for the links, really interesting!
    Geometry Online

    jamaicawillson Wed Oct 21 23:46:20 -0700 2009

    That's really a fantastic post ! I have been reading your blog last couple of weeks and enjoy every bit. Thanks Mini blinds

    AJHEELS Thu Oct 29 14:33:31 -0700 2009

    For information and products relating to height increase or footcare please visit HEELSNCLEAVAGE
    Thats great, Ive messed around with Zookeeper a few times
    HEEL PADS
    SHOE INSOLE
    INCREASE MY HEIGHT
    INCREASE YOUR HEIGHT

    MelisaP Tue Nov 03 03:38:54 -0800 2009

    Great post!! free games

    jamaicawillson Wed Nov 04 00:14:11 -0800 2009

    i tried it ,but got some error here.
    Gourmet gift baskets

    hasan145303 Fri Nov 06 01:25:15 -0800 2009

    The suited masses thank you.free online games

    Please log in to comment.