From 276ccdace2195b8fe83c8c525269fb06590fd0ad Mon Sep 17 00:00:00 2001 From: Maximilian Bosch Date: Tue, 2 Nov 2021 22:45:33 +0100 Subject: [PATCH] generateNix: force using https URLs This is because GitHub has deprecated the unsecured `git://` access[1]. By regenerating our internal `yarn.nix` I confirmed that there are no hash-changes, so this should be fully backwards-compatible. [1] https://github.blog/2021-09-01-improving-git-protocol-security-github/ --- lib/generateNix.js | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/generateNix.js b/lib/generateNix.js index 1cb4933..51e58b3 100644 --- a/lib/generateNix.js +++ b/lib/generateNix.js @@ -42,6 +42,7 @@ function prefetchgit(url, rev) { } function fetchgit(fileName, url, rev, branch, builtinFetchGit, actualName) { + url = url.replace(/^git:\/\/github/, 'https://github') const prefetched = prefetchgit(url, rev) const packageJSON = JSON.parse( fs.readFileSync(`${prefetched.path}/package.json`),