-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
downloads: support 32-bit/64-bit windows links #571
Conversation
With the switch to the *MSYS2* backend for the *Git for Windows* project the opportunity arose to support both `32-bit` and `64-bit` builds. In additon to those `32-bit` and `64-bit` builds *Git for Windows* now ships with portable releases as well. So it makes sense to display all those links on the download page. Since this behavior differs from the `mac` platform would be best to introduce a new download page for the `windows` platform. The naming convention for *Git for Windows* builds changed too, so the `rake downloads` task had to be adapted. It now parses the *Git for Windows* release file properly and also extracts the `bitness` and the portable information of the release file. That `bitness` and the portable information is then appended to the platform when storing the release information in the database. To provide an automatic download for the latest *Git for Windows* release in the correct `bitness` parsing of the user agent in the download controller was added. The view was updated to show the current download and then list the other options as well. To associate the latest Windows release (which might have 4 digits) to the corresponding Git version, we look only at the first 3 digits (which match the Git version). Thanks to the order in which the GitHub API delivers the releases, this means that the last one wins, as it should be. Example: if 2.5.0 was uploaded, and later 2.5.0.2 was uploaded, then 2.5.0.2 is added as a `Download` *later* than 2.5.0, and associated with the Git version 2.5.0. So even if it might not be completely obvious from a quick glance, the logic is sound. [jes: rebased to current upstream; accounted for 3-digit versions, commented on the 4 -> 3 digits reduction to match up Git for Windows to Git versions] Signed-off-by: 마누엘 <[email protected]> Signed-off-by: Johannes Schindelin <[email protected]>
@dscho Is this ready to merge in your opinion? What's the timing like for releasing the new version of Git for Windows? |
@peff this is almost ready. I am re-building the installers because of one last-minute bug fix (git-for-windows/git#282). I have a fix, it should be up momentarily, and then we're good to go (I still have to write the announcement, though). Will keep you posted, expect news within 15 minutes. |
@peff Also, I would be really indebted if you could have another look at the Ruby code because my Ruby-fu is not as good as my C and Java-fu... |
Okay, the new installers are uploaded (and briefly tested before that). Ready to go. |
I am absolutely not the best person to be commenting on ruby code. |
Hmm, when I run it locally, going to |
Did you update the |
Ah, no, the problem was I didn't do the |
Ah, okay! |
downloads: support 32-bit/64-bit windows links
Thanks!!! |
Oh BTW is there any chance to run |
I believe that |
Okay, no problem, 1h is what I'll spend easily on writing that mail... |
Amazing. |
With the switch to the MSYS2 backend for the Git for Windows project
the opportunity arose to support both
32-bit
and64-bit
builds. Inadditon to those
32-bit
and64-bit
builds Git for Windows now shipswith portable releases as well. So it makes sense to display all those
links on the download page. Since this behavior differs from the
mac
platform would be best to introduce a new download page for the
windows
platform.
The naming convention for Git for Windows builds changed too, so the
rake downloads
task had to be adapted. It now parses the Git forWindows release file properly and also extracts the
bitness
and theportable information of the release file. That
bitness
and the portableinformation is then appended to the platform when storing the release
information in the database.
To provide an automatic download for the latest Git for Windows release
in the correct
bitness
parsing of the user agent in the downloadcontroller was added. The view was updated to show the current download
and then list the other options as well.
To associate the latest Windows release (which might have 4 digits) to the
corresponding Git version, we look only at the first 3 digits (which match
the Git version). Thanks to the order in which the GitHub API delivers the
releases, this means that the last one wins, as it should be. Example: if
2.5.0 was uploaded, and later 2.5.0.2 was uploaded, then 2.5.0.2 is added
as a
Download
later than 2.5.0, and associated with the Git version2.5.0. So even if it might not be completely obvious from a quick glance,
the logic is sound.
[jes: rebased to current upstream; accounted for 3-digit versions,
commented on the 4 -> 3 digits reduction to match up Git for Windows to
Git versions]
Signed-off-by: 마누엘 [email protected]
Signed-off-by: Johannes Schindelin [email protected]