From fed6a145002b1b2dd22bea630b026c72335348a8 Mon Sep 17 00:00:00 2001 From: nekowinston Date: Fri, 1 Dec 2023 01:10:45 +0100 Subject: [PATCH] build(nix): optimize build speed (#234) --- nix/default.nix | 4 ++-- nix/shell.nix | 17 ++++------------- 2 files changed, 6 insertions(+), 15 deletions(-) diff --git a/nix/default.nix b/nix/default.nix index 15f848d1..9e84de82 100644 --- a/nix/default.nix +++ b/nix/default.nix @@ -46,7 +46,7 @@ extension = pkgs.stdenvNoCC.mkDerivation { inherit name version pname src; - buildInputs = [pkgs.nodejs pkgs.vsce pkgs.yarn]; + buildInputs = [pkgs.nodejs pkgs.vsce]; # check in the ./themes/.flag so it doesn't prompt for initial rebuilds patchPhase = '' @@ -63,7 +63,7 @@ cp -r ${builder}/* dist/ touch ./themes/.flag node dist/hooks/generateThemes.js - vsce package --yarn + vsce package --no-dependencies runHook postBuild ''; diff --git a/nix/shell.nix b/nix/shell.nix index 0e99368a..b57d8c68 100644 --- a/nix/shell.nix +++ b/nix/shell.nix @@ -1,13 +1,4 @@ -{pkgs ? import {}}: let - nodejs = pkgs.nodejs_18; -in - pkgs.mkShell { - buildInputs = with pkgs; [ - alejandra - nil - - nodejs - corepack - (yarn.override {inherit nodejs;}) - ]; - } +{pkgs ? import {}}: +pkgs.mkShell { + buildInputs = with pkgs; [alejandra nil nodejs_18 corepack]; +}