Installing Cloud Code in VS Code

Trying to add the Cloud Code extension inside VS Code but getting errors when building. Looks like the extension has multiple files in the zip root, or something. How can I resolve this without upstream changes?

pkgs.vscode-utils.extensionsFromVscodeMarketplace [
      name = "cloudcode";
      publisher = "googlecloudtools";
      version = "2.0.0";
      sha256 = "PQisBibYm8boTCl5RXs4Pv90mNDjfKxtNxjf22gLhxw=";
nix log /nix/store/nx83zvy47a0m2g6vssr57c0bnb7dnfl3-vscode-extension-googlecloudtools-cloudcode-2.0.0.drv
@nix { "action": "setPhase", "phase": "unpackPhase" }
unpacking sources
unpacking source archive /nix/store/
unpacker produced multiple directories
1 Like

I was facing the same issue but I found a workaround, because the extension archive contains mutliple directories unlike most extensions we need to specify the root extension directory to use:

  "googlecloudtools"."cloudcode" =
    (vscode-utils.extensionFromVscodeMarketplace {
      name = "cloudcode";
      publisher = "googlecloudtools";
      version = "2.2.1";
      sha256 = "1s8b7knhsn4yqzjzf46bixi710a10gc4aa7h12n3iw3xqg2ss49x";
    .overrideAttrs (_: {sourceRoot = "extension";});

My syntax is slightly different because I use the nix4vscode tool.

1 Like