Skip to content

Commit ad476e5

Browse files
committed
chore: don't publish prelease versions to vscode market place, because it does not support prerelease tagged versions
1 parent 4cda8e7 commit ad476e5

File tree

1 file changed

+9
-8
lines changed

1 file changed

+9
-8
lines changed

scripts/publish.py

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -37,16 +37,17 @@ def main() -> None:
3737
if not dist_path.exists():
3838
raise FileNotFoundError(f"dist folder '{dist_path}' not exists")
3939

40-
current_version = get_version()
40+
version = get_version()
4141

42-
vsix_path = Path(dist_path, f"robotcode-{current_version}.vsix")
42+
vsix_path = Path(dist_path, f"robotcode-{version}.vsix")
4343

44-
run(
45-
"npx vsce publish",
46-
f"npx vsce publish -i {vsix_path}",
47-
shell=True,
48-
timeout=600,
49-
)
44+
if not version.prerelease:
45+
run(
46+
"npx vsce publish",
47+
f"npx vsce publish -i {vsix_path}",
48+
shell=True,
49+
timeout=600,
50+
)
5051
run(
5152
"npx ovsx publish",
5253
f"npx ovsx publish {vsix_path}",

0 commit comments

Comments
 (0)