From 7f8f39bf55c8e747998b9e50ff0925404324005e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Domen=20Ko=C5=BEar?= Date: Wed, 2 Oct 2019 16:34:58 +0200 Subject: [PATCH] build --- lib/main.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/main.js b/lib/main.js index cd5855e..bda2e4e 100644 --- a/lib/main.js +++ b/lib/main.js @@ -24,11 +24,13 @@ const fs_1 = require("fs"); function run() { return __awaiter(this, void 0, void 0, function* () { try { - // rest of the constants const home = os_1.homedir(); const { username } = os_1.userInfo(); const PATH = process.env.PATH; const CERTS_PATH = home + '/.nix-profile/etc/ssl/certs/ca-bundle.crt'; + // Workaround a segfault: https://github.com/NixOS/nix/issues/2733 + yield exec.exec("sudo", ["mkdir", "-p", "/etc/nix"]); + yield exec.exec("sudo", ["echo", "http2 = false", ">>", "/etc/nix/nix.conf"]); // TODO: retry due to all the things that go wrong const nixInstall = yield tc.downloadTool('https://nixos.org/nix/install'); yield exec.exec("sh", [nixInstall]);