Introduction
github is the great platform for distributed version control. In this post we do not talk about using github and working with git, but instead about downloading a tarball or ZIP package and especially a particular version.
Downloading the lastest version of the source code
If on the main project page, we can find a button labeled “Download ZIP” on the right. Here we can download a https://github.com/xxxx/yyyy/archive/master.zip.
Most of the time this is what we want: getting the latest and hopefully greatest version.
There is no button Download tar.gz or else, but we can manually go to
https://github.com/xxxx/yyyy/archive/master.tar.gz
and download a packed tarball.
Downloading a specific version of the source code
Why ?
Perhaps there is a certain instruction manual which works with this version only, or you just want to be sure that you get the exact same result as the author of the instruction some months or even years ago.
How ?
If you are an instruction manual writer who wants to create a link to a specific version
♦ On the top of the commit list there is a link “latest commit 1234567”.
♦ Click on this link
♦ Press button “Browse code”
→
The “Download ZIP” button now references an URL of
https://github.com/xxxx/yyyy/archive/1234567890abcdef0987654321.zip
This is your “specific version download link”. Or use the corresponding
https://github.com/xxxx/yyyy/archive/1234567890abcdef0987654321.tar.gz
If you want to download a specific version
We assume that you do not have the “cryptic version URL” described above, but instead only an approximate idea of the date of the version you want to download.
♦ On the top of the commit list there is the commit tab (“123 commits“). Click on it.
♦ Find your date
♦ Click on the “< >” button on the right
→
Same as above: use “Download ZIP button” or build the corresponding xxxx.tar.gz
URL