From edf67597b3d71285094eb9cf6be8a120484d429e Mon Sep 17 00:00:00 2001 From: Mateusz Kowalczyk Date: Thu, 11 Jul 2024 15:55:03 +0900 Subject: [PATCH] vscode-extensions.rust-lang.rust-analyzer: 0.3.1850 -> 0.3.2029 I have removed the no-longer-necessary `echo y` in the script, along with the TODO. The other change is to `jq` command patching `package.json`: it appears the content has changed so I modify the script accordingly to keep patching the correct value with the new format. I have verified that it works locally, though it is just as broken as what's in current master until there's a fix for https://github.com/NixOS/nixpkgs/issues/326264 . --- .../rust-lang.rust-analyzer/build-deps/package.json | 2 +- .../extensions/rust-lang.rust-analyzer/default.nix | 10 ++++------ pkgs/development/node-packages/node-packages.nix | 2 +- 3 files changed, 6 insertions(+), 8 deletions(-) diff --git a/pkgs/applications/editors/vscode/extensions/rust-lang.rust-analyzer/build-deps/package.json b/pkgs/applications/editors/vscode/extensions/rust-lang.rust-analyzer/build-deps/package.json index c7fb097b2d77..3e7688f0e068 100644 --- a/pkgs/applications/editors/vscode/extensions/rust-lang.rust-analyzer/build-deps/package.json +++ b/pkgs/applications/editors/vscode/extensions/rust-lang.rust-analyzer/build-deps/package.json @@ -1,6 +1,6 @@ { "name": "rust-analyzer", - "version": "0.3.1850", + "version": "0.3.2029", "dependencies": { "@hpcc-js/wasm": "^2.13.0", "anser": "^2.1.1", diff --git a/pkgs/applications/editors/vscode/extensions/rust-lang.rust-analyzer/default.nix b/pkgs/applications/editors/vscode/extensions/rust-lang.rust-analyzer/default.nix index dcdbf3dd2cbf..a53fc7b8ca5b 100644 --- a/pkgs/applications/editors/vscode/extensions/rust-lang.rust-analyzer/default.nix +++ b/pkgs/applications/editors/vscode/extensions/rust-lang.rust-analyzer/default.nix @@ -21,13 +21,13 @@ let # Use the plugin version as in vscode marketplace, updated by update script. inherit (vsix) version; - releaseTag = "2024-02-19"; + releaseTag = "2024-07-08"; src = fetchFromGitHub { owner = "rust-lang"; repo = "rust-analyzer"; rev = releaseTag; - hash = "sha256-Oj/RPMridKpYt3eRqUIPg9YNrj6npG8THIGuWjsamnE="; + hash = "sha256-STmaV9Zu74QtkGGrbr9uMhskwagfCjJqOAYapXabiuk="; }; build-deps = @@ -67,9 +67,7 @@ let ' package.json | sponge package.json mkdir -p $vsix - # vsce ask for continue due to missing LICENSE.md - # Should be removed after https://github.com/rust-lang/rust-analyzer/commit/acd5c1f19bf7246107aaae7b6fe3f676a516c6d2 - echo y | npx vsce package -o $vsix/${pname}.zip + npx vsce package -o $vsix/${pname}.zip ''; }; in @@ -87,7 +85,7 @@ vscode-utils.buildVscodeExtension { ]; preInstall = lib.optionalString setDefaultServerPath '' - jq '.contributes.configuration.properties."rust-analyzer.server.path".default = $s' \ + jq '(.contributes.configuration[] | select(.title == "server") | .properties."rust-analyzer.server.path".default) = $s' \ --arg s "${rust-analyzer}/bin/rust-analyzer" \ package.json | sponge package.json ''; diff --git a/pkgs/development/node-packages/node-packages.nix b/pkgs/development/node-packages/node-packages.nix index d54cc8f11c93..b93a3a818d9b 100644 --- a/pkgs/development/node-packages/node-packages.nix +++ b/pkgs/development/node-packages/node-packages.nix @@ -85809,7 +85809,7 @@ in "rust-analyzer-build-deps-../../applications/editors/vscode/extensions/rust-lang.rust-analyzer/build-deps" = nodeEnv.buildNodePackage { name = "rust-analyzer"; packageName = "rust-analyzer"; - version = "0.3.1850"; + version = "0.3.2029"; src = ../../applications/editors/vscode/extensions/rust-lang.rust-analyzer/build-deps; dependencies = [ sources."@azure/abort-controller-1.1.0"