J. Doe
J. Doe

Reputation: 125

How to create local git repository from git archive?

Is it possible to recreate a git repository locally from the extracted content of a Github repository archive ?

To add a little bit of context, my Android app downloads a git repository archive using DownloadManager and a Github repository archive link, then extracts it on the local storage of the device. I am looking to turn the content of this extracted archive into a local repository of the remote one and track its contents.

Upvotes: 0

Views: 124

Answers (1)

phd
phd

Reputation: 94445

It is not, alas. The result of git archive contains neither commits nor other metadata.

The only way to track a remote repository is to clone it.

Upvotes: 1

Related Questions