From bb9f0b54ca7091d424ee4564e9095c544b92a946 Mon Sep 17 00:00:00 2001 From: nixbitcoin Date: Thu, 30 Dec 2021 12:55:10 +0000 Subject: [PATCH] spark-wallet: use HTTPS instead of SSH for Github --- pkgs/spark-wallet/generate.sh | 11 ++++++++++- pkgs/spark-wallet/node-packages.nix | 12 ++++++------ 2 files changed, 16 insertions(+), 7 deletions(-) diff --git a/pkgs/spark-wallet/generate.sh b/pkgs/spark-wallet/generate.sh index d869c2c..88dfffc 100755 --- a/pkgs/spark-wallet/generate.sh +++ b/pkgs/spark-wallet/generate.sh @@ -46,4 +46,13 @@ fetchurl { hash = "$hash"; }; EOF -sed -i "s|src = .*/src;|src = ${fetchurl//$'\n'/\\n}|" node-packages.nix + +sed -i " + # Use the verified package src + s|src = .*/src;|src = ${fetchurl//$'\n'/\\n}| + + # github: use HTTPS instead of SSH, which requires user authentication + s|git+ssh://git@|https://| + s|ssh://git@|https://| + s|\.git#|#| +" node-packages.nix diff --git a/pkgs/spark-wallet/node-packages.nix b/pkgs/spark-wallet/node-packages.nix index ab8975a..ff61324 100644 --- a/pkgs/spark-wallet/node-packages.nix +++ b/pkgs/spark-wallet/node-packages.nix @@ -1579,12 +1579,12 @@ let sha512 = "t/7RxHXPH6cJtP0pRG6smSr9QJidhB+3kXu0KgXnbGYMgzEnUxRQ4/LDdfOwZEMyIh3/xHb8PX3t+lfL9z+YVQ=="; }; }; - "proxy-agent-git+ssh://git@github.com/shesek/node-proxy-agent.git#0d916427f586e41a1a4485db88509218017f9696" = { + "proxy-agent-https://github.com/shesek/node-proxy-agent#0d916427f586e41a1a4485db88509218017f9696" = { name = "proxy-agent"; packageName = "proxy-agent"; version = "3.1.1"; src = fetchgit { - url = "ssh://git@github.com/shesek/node-proxy-agent.git"; + url = "https://github.com/shesek/node-proxy-agent.git"; rev = "0d916427f586e41a1a4485db88509218017f9696"; sha256 = "9582aafb90887f3a600806240c0f71fd09ef2b8805a37281894b56e717a35d98"; }; @@ -2030,12 +2030,12 @@ let sha512 = "OUDHEssirmplo3F+1HWKUrUjvnQuA+nZI6i/JJBdXb5eq9IyEQwPyPpqND+SSsxf6TygpBEkUjISVRN4/VOpeg=="; }; }; - "superagent-proxy-git+ssh://git@github.com/shesek/superagent-proxy.git#b512f8bbcf1baa196058922ee3b6cfe45375ebc9" = { + "superagent-proxy-https://github.com/shesek/superagent-proxy#b512f8bbcf1baa196058922ee3b6cfe45375ebc9" = { name = "superagent-proxy"; packageName = "superagent-proxy"; version = "2.0.0"; src = fetchgit { - url = "ssh://git@github.com/shesek/superagent-proxy.git"; + url = "https://github.com/shesek/superagent-proxy.git"; rev = "b512f8bbcf1baa196058922ee3b6cfe45375ebc9"; sha256 = "ca984f1f2dc7cfed2aa301de1daf4305c359e89276d897fffa92e7c80850d03c"; }; @@ -2459,7 +2459,7 @@ let sources."prelude-ls-1.1.2" sources."process-nextick-args-2.0.1" sources."proxy-addr-2.0.5" - (sources."proxy-agent-git+ssh://git@github.com/shesek/node-proxy-agent.git#0d916427f586e41a1a4485db88509218017f9696" // { + (sources."proxy-agent-https://github.com/shesek/node-proxy-agent#0d916427f586e41a1a4485db88509218017f9696" // { dependencies = [ sources."debug-4.1.1" sources."ms-2.1.2" @@ -2533,7 +2533,7 @@ let sources."semver-7.3.2" ]; }) - (sources."superagent-proxy-git+ssh://git@github.com/shesek/superagent-proxy.git#b512f8bbcf1baa196058922ee3b6cfe45375ebc9" // { + (sources."superagent-proxy-https://github.com/shesek/superagent-proxy#b512f8bbcf1baa196058922ee3b6cfe45375ebc9" // { dependencies = [ sources."debug-3.2.6" sources."ms-2.1.2"