vscode-offline 0.1.5__tar.gz → 0.1.6__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {vscode_offline-0.1.5 → vscode_offline-0.1.6}/.vscode/extensions.json +2 -1
- {vscode_offline-0.1.5 → vscode_offline-0.1.6}/PKG-INFO +1 -1
- {vscode_offline-0.1.5 → vscode_offline-0.1.6}/src/vscode_offline/install.py +7 -2
- {vscode_offline-0.1.5 → vscode_offline-0.1.6}/.editorconfig +0 -0
- {vscode_offline-0.1.5 → vscode_offline-0.1.6}/.github/workflows/publish.yml +0 -0
- {vscode_offline-0.1.5 → vscode_offline-0.1.6}/.github/workflows/test.yml +0 -0
- {vscode_offline-0.1.5 → vscode_offline-0.1.6}/.gitignore +0 -0
- {vscode_offline-0.1.5 → vscode_offline-0.1.6}/.python-version +0 -0
- {vscode_offline-0.1.5 → vscode_offline-0.1.6}/.vscode/settings.json +0 -0
- {vscode_offline-0.1.5 → vscode_offline-0.1.6}/LICENSE +0 -0
- {vscode_offline-0.1.5 → vscode_offline-0.1.6}/README.md +0 -0
- {vscode_offline-0.1.5 → vscode_offline-0.1.6}/lefthook.yml +0 -0
- {vscode_offline-0.1.5 → vscode_offline-0.1.6}/pyproject.toml +0 -0
- {vscode_offline-0.1.5 → vscode_offline-0.1.6}/pyrightconfig.json +0 -0
- {vscode_offline-0.1.5 → vscode_offline-0.1.6}/src/vscode_offline/__init__.py +0 -0
- {vscode_offline-0.1.5 → vscode_offline-0.1.6}/src/vscode_offline/app.py +0 -0
- {vscode_offline-0.1.5 → vscode_offline-0.1.6}/src/vscode_offline/download.py +0 -0
- {vscode_offline-0.1.5 → vscode_offline-0.1.6}/src/vscode_offline/loggers.py +0 -0
- {vscode_offline-0.1.5 → vscode_offline-0.1.6}/src/vscode_offline/utils.py +0 -0
- {vscode_offline-0.1.5 → vscode_offline-0.1.6}/tests/test_install.py +0 -0
- {vscode_offline-0.1.5 → vscode_offline-0.1.6}/tests/test_utils.py +0 -0
- {vscode_offline-0.1.5 → vscode_offline-0.1.6}/uv.lock +0 -0
@@ -2,6 +2,7 @@ from __future__ import annotations
|
|
2
2
|
|
3
3
|
import os
|
4
4
|
import re
|
5
|
+
import shutil
|
5
6
|
import subprocess
|
6
7
|
from collections.abc import Set as AbstractSet
|
7
8
|
from pathlib import Path
|
@@ -44,11 +45,12 @@ def get_extension_target_platform(filename: str) -> str | None:
|
|
44
45
|
|
45
46
|
|
46
47
|
def install_vscode_extensions(
|
47
|
-
|
48
|
+
code: str | os.PathLike[str],
|
48
49
|
vsix_dir: str,
|
49
50
|
platform: str,
|
50
51
|
exclude: AbstractSet[str] = frozenset(),
|
51
52
|
) -> None:
|
53
|
+
code_executable = shutil.which(code)
|
52
54
|
for vsix_file in Path(vsix_dir).glob("*.vsix"):
|
53
55
|
extension_identifier = get_extension_identifier(vsix_file.name)
|
54
56
|
if extension_identifier in exclude:
|
@@ -65,7 +67,10 @@ def install_vscode_extensions(
|
|
65
67
|
)
|
66
68
|
continue
|
67
69
|
logger.info(f"Installing {vsix_file}")
|
68
|
-
subprocess.check_call(
|
70
|
+
subprocess.check_call(
|
71
|
+
[code, "--install-extension", vsix_file, "--force"],
|
72
|
+
executable=code_executable,
|
73
|
+
)
|
69
74
|
logger.info(f"Installed {vsix_file}")
|
70
75
|
|
71
76
|
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|