I want to clone a git repository whose git://
server is down.
Fortunately its gitweb interface is still working and all the data required to reconstruct the git repository is available from there.
So, is there any git command or other tool able to clone a git repository from gitweb?
(I could write a bot myself, but don't want to waste my time doing it if there is another way)
To Git clone a repository navigate to your preferred repository hosting service like GitHub, select the repository you want to clone, copy the repository URL via HTTPS or SSH, type git clone in the command line, paste the URL, and hit enter .
From your web browser, open the team project for your Azure DevOps organization, and then choose Repos > Files to open the Files view. In the Files view, choose Clone to launch the Clone Repository popup. Copy the clone URL from the Clone Repository popup.
gitweb is just a perl script (gitweb.perl
):
If enabled in the gitweb.conf
, gitweb can serve "snapshots" (in zip or tag.gz format), but this isn't the full history of the repository: it is only a compressed archive of any tree or commit, as produced by git-archive
.
http://<gitweburl>/gitweb.cgi?p=<repo>.git;a=snapshot;h=HEAD
If there is any command, it needs to be executed on the server.
For instance, you can ask for a bundle (git bundle):
cd /path/to/bare/repo
git bundle create ../repo.bundle --all
That will create one file, that you can sftp back to your local station, and which acts as a git repository (read only, clone/pull only, no push):
cd /path/to/repo.bundle
git clone repo.bundle
cd repo
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With