Skip to content

Commit 13d68b4

Browse files
committed
Publish latest VSIX from CI
1 parent 307cd41 commit 13d68b4

5 files changed

Lines changed: 74 additions & 6 deletions

File tree

‎.github/workflows/check.yml‎

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,3 +72,54 @@ jobs:
7272
7373
- name: Run the repository verification matrix
7474
run: cargo xtask check
75+
76+
vscode-release:
77+
name: Publish latest VS Code extension
78+
needs: repository
79+
if: github.event_name == 'push' && github.ref == 'refs/heads/master'
80+
runs-on: ubuntu-latest
81+
permissions:
82+
contents: write
83+
84+
steps:
85+
- name: Check out the repository
86+
uses: actions/checkout@v7
87+
88+
- name: Install Rust
89+
uses: dtolnay/rust-toolchain@stable
90+
with:
91+
targets: wasm32-unknown-unknown
92+
93+
- name: Install Node.js
94+
uses: actions/setup-node@v7
95+
with:
96+
node-version: 24
97+
cache: npm
98+
cache-dependency-path: editors/vscode/package-lock.json
99+
100+
- name: Install extension dependencies
101+
working-directory: editors/vscode
102+
run: npm ci
103+
104+
- name: Package the extension
105+
working-directory: editors/vscode
106+
run: npm run package:vsix -- --out splitscript-latest.vsix
107+
108+
- name: Publish the latest release
109+
shell: bash
110+
env:
111+
GH_TOKEN: ${{ github.token }}
112+
run: |
113+
asset="editors/vscode/splitscript-latest.vsix"
114+
title="Latest SplitScript VS Code Extension"
115+
notes="Continuously updated from the latest verified commit on master. This early build may introduce breaking language changes."
116+
117+
git tag --force latest "$GITHUB_SHA"
118+
git push --force origin refs/tags/latest
119+
120+
if gh release view latest >/dev/null 2>&1; then
121+
gh release edit latest --title "$title" --notes "$notes" --latest
122+
gh release upload latest "$asset" --clobber
123+
else
124+
gh release create latest "$asset" --verify-tag --title "$title" --notes "$notes" --latest
125+
fi

‎README.md‎

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -40,10 +40,12 @@ documentation catalog, formatter, diagnostics, and language service.
4040

4141
### Visual Studio Code authors
4242

43-
Install a supplied `splitscript-*.vsix`, open a saved `.split` file, and run
44-
**SplitScript: Open Documentation**. The bundled **Getting started** guide is a
45-
self-contained, compiler-checked path through attachment, settings, state
46-
snapshots, builds, diagnostics, and host loading.
43+
Install the [latest SplitScript VSIX][latest-vsix], open a saved `.split` file,
44+
and run **SplitScript: Open Documentation**. The bundled **Getting started**
45+
guide is a self-contained, compiler-checked path through attachment, settings,
46+
state snapshots, builds, diagnostics, and host loading. The package is rebuilt
47+
from every verified push to `master`, so it is an early moving build rather than
48+
a stable release.
4749

4850
Use **SplitScript: Start Debug Watch** while editing and **SplitScript: Build
4951
Release** for the final module. Both write a neighboring `.wasm` file. The
@@ -131,3 +133,5 @@ instantiate it.
131133
The repository also contains ports and deterministic runtime fixtures used as
132134
implementation evidence. They are not the user guide, are not compatibility
133135
promises, and should not be treated as templates for new scripts.
136+
137+
[latest-vsix]: https://github.com/CryZe/SplitScript/releases/download/latest/splitscript-latest.vsix

‎TODO.md‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -837,6 +837,10 @@ debug watch without external executables. Native `splitc` and `splitls` remain
837837
separate first-class products. The architecture experiment is complete; the
838838
remaining work is product hardening and distribution.
839839

840+
- [x] Publish a platform-neutral VSIX from every verified `master` push. CI
841+
moves the stable `latest` tag and replaces `splitscript-latest.vsix` on one
842+
durable GitHub release; pull requests and other branches remain read-only.
843+
840844
- [x] Add cooperative cancellation points to expensive compiler stages so a
841845
superseded editor build can stop work rather than merely have its completed
842846
response discarded. The shared compiler and service distinguish typed

‎editors/vscode/DEVELOPMENT.md‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,12 @@ npm run package:vsix
3434
The production build runs automatically and writes
3535
`splitscript-<version>.vsix` in this directory.
3636

37+
After the complete verification job succeeds for a push to `master`, CI runs
38+
the same production packaging path with the stable asset name
39+
`splitscript-latest.vsix`. It moves the `latest` tag to that verified commit and
40+
replaces the asset on the existing **Latest SplitScript VS Code Extension**
41+
release. Pull requests and pushes to other branches never publish a package.
42+
3743
## Worker architecture
3844

3945
The language client gives the language server its own worker and Wasm instance.

‎editors/vscode/README.md‎

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,9 @@ separate native executable.
77

88
## Start a script
99

10-
1. Install the supplied `splitscript-*.vsix` with **Extensions: Install from
11-
VSIX**.
10+
1. Download the [latest SplitScript VSIX][latest-vsix] and install it with
11+
**Extensions: Install from VSIX**. This early package follows every verified
12+
push to `master` and may contain breaking language changes.
1213
2. Open a folder and create a saved file ending in `.split`.
1314
3. Run **SplitScript: Open Documentation** and open **Getting started**. That
1415
compiler-checked guide introduces process attachment, a typed setting, one
@@ -83,3 +84,5 @@ reported without losing the failing state.
8384
If a build targets the wrong file, make sure the intended `.split` editor is
8485
active when starting the command. Untitled files prompt for a save location;
8586
the resulting saved document is the one compiled.
87+
88+
[latest-vsix]: https://github.com/CryZe/SplitScript/releases/download/latest/splitscript-latest.vsix

0 commit comments

Comments
 (0)