vscode-extensions.charliermarsh.ruff: replace the bundled ruff binary (#384869)
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
stdenvNoCC,
|
||||
lib,
|
||||
vscode-utils,
|
||||
ruff,
|
||||
}:
|
||||
|
||||
vscode-utils.buildVscodeMarketplaceExtension {
|
||||
@@ -33,6 +34,15 @@ vscode-utils.buildVscodeMarketplaceExtension {
|
||||
}
|
||||
// sources.${stdenvNoCC.system} or (throw "Unsupported system ${stdenvNoCC.system}");
|
||||
|
||||
postInstall = ''
|
||||
test -x "$out/$installPrefix/bundled/libs/bin/ruff" || {
|
||||
echo "Replacing the bundled ruff binary failed, because 'bundled/libs/bin/ruff' is missing."
|
||||
echo "Update the package to the match the new path/behavior."
|
||||
exit 1
|
||||
}
|
||||
ln -sf ${lib.getExe ruff} "$out/$installPrefix/bundled/libs/bin/ruff"
|
||||
'';
|
||||
|
||||
meta = {
|
||||
license = lib.licenses.mit;
|
||||
changelog = "https://marketplace.visualstudio.com/items/charliermarsh.ruff/changelog";
|
||||
|
||||
Reference in New Issue
Block a user