I have just started using GitHub, and after making a few changes to some files in my repository, I downloaded the repository as a zip file. I get only the latest versions of all the files there. I can see the history online, however. Is there a way to get all the versions I contributed in a zip file?
Use git pull --unshallow and it will download the entire commit history.
To download from GitHub, you should navigate to the top level of the project (SDN in this case) and then a green "Code" download button will be visible on the right. Choose the Download ZIP option from the Code pull-down menu. That ZIP file will contain the entire repository content, including the area you wanted.
Git file History provides information about the commit history associated with a file. To use it: Go to your project's Repository > Files. In the upper right corner, select History.
On GitHub, you can see the commit history of a repository by: Navigating directly to the commits page of a repository. Clicking on a file, then clicking History, to get to the commit history for a specific file.
Github is a site that hosts git repositories. The download as ZIP feature isn't for getting a local copy of the repository, it just downloads the view of the repository that you are viewing at that time (the master branch, for example). This is more for getting a specific version of the software.
If you wish to contribute to the repository, you should instead be cloning using the git command line tool:
git clone https://github.com/someuser/some-repo.git
This gives you a copy of the repository. A complete copy, histroy and all. You would then interact with the repository on your local machine, and push and pull changes as allowed by the permissions on github.
Typically, you'll actually fork a repository to your account, and push and pull changes to that copy, and then send the original repo a pull request when you want your changes to be included in the primary version.
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