Skip to content

Set up VS Code extension publishing pipeline (vsce + webpack + CI) #45

@michaeldistel

Description

@michaeldistel

The vscode-extension/ added in #41 has no publishing pipeline. Before it can ship to the VS Code Marketplace it needs:

Problems

1. package.json files field is wrong
Lists "runtime/" but the C++ runtime lives at src/runtime/. npm publish would ship a package missing its runtime headers entirely.
Fix: change to "src/runtime/".

2. No bundler configured for the extension
The extension uses tsc only. For marketplace distribution the client and server must be bundled into single files so node_modules is not shipped. vscode:prepublish is undefined.

3. strucpp dependency is file:..
Works locally but breaks vsce package — the file-protocol dep won't resolve in a packaged VSIX. Needs either a published npm version or the compiler bundled into the extension via webpack/esbuild.

4. No publisher field in vscode-extension/package.json
Required by vsce for packaging and publishing.

5. No vsce devDependency
@vscode/vsce is not listed — vsce package and vsce publish commands are unavailable.

6. No CI publishing step
No workflow step to run vsce package on tag push or produce a .vsix artifact.

Suggested fix

In vscode-extension/:

  1. Add webpack + ts-loader + @vscode/vsce to devDependencies
  2. Add webpack.config.js with client + server bundle configs (externalize vscode)
  3. Set "vscode:prepublish": "webpack --mode production"
  4. Add publisher field
  5. Fix strucpp dep — bundle the compiler into the extension or wait until strucpp is published to npm
  6. Update .vscodeignore to exclude src/, node_modules/, keep dist/ and runtime data
  7. Add vsce package step to release workflow that produces a .vsix artifact on tag push

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions