Thursday, April 22, 2021

New top story on Hacker News: Why did Microsoft remove the "Download ZIP" link from GitHub repository pages

Why did Microsoft remove the "Download ZIP" link from GitHub repository pages
6 by 1vuio0pswjnm7 | 2 comments on Hacker News.
Git is a relatively large program with numerous dependencies.^1 Source code published on github.com can be downloaded without using git. One way to do this is to download a .zip file of the source code using wget or similar from codeload.github.com. The github.com website used to include a download link for a .zip file on repository pages. If I am not mistaken, Microsoft has recently removed this link. Perhaps the reason for this has been discussed somewhere and I missed it. Meanwhile, the following solves the problem for me. cat > 1.sh << eof # usage: echo https://github.com/user/program|1.sh IFS=/; read x1 x2 x3 x4 x5 x6; case ${x1} in https:);;*)exit;esac; test ${#x2} -eq 0||exit; case ${x3} in github.com);;*)exit;esac; test ${#x4} -gt 0||exit; test ${#x5} -gt 0||exit; exec FTPUSERAGENT=git/2.9.5 ftp -4vvo ${x4}-${x5}.zip https://codeload.github.com/${x4}/${x5}/zip/master eof 1. For example, git from Void Linux 16 packages will be installed: gdbm-1.19_1 perl-5.32.1_2 perl-Digest-HMAC-1.03_4 perl-Authen-SASL-2.16_5 perl-Convert-BinHex-1.125_3 perl-IO-stringy-2.113_2 perl-TimeDate-2.33_2 perl-MailTools-2.21_2 perl-MIME-tools-5.509_3 perl-Net-SSLeay-1.90_2 perl-URI-5.07_1 perl-IO-Socket-SSL-2.070_1 perl-Net-SMTP-SSL-1.04_2 libpcre2-10.35_1 expat-2.3.0_1 git-2.31.1_1 Size required on disk: 109MB Space available on disk: 3560MB

No comments:

Post a Comment