Template repository for building VS Code extensions for WinCC OA, with a GitFlow-style branching model and a CI → prerelease → release pipeline.
Create a new repository from this template, then:
npm install
npm run compile
npm run test:unitRun locally in VS Code:
To launch this extension, press F5 in your VS Code instance to open an Extension Development Host.
When you create a new repository from this template, update these placeholders first.
Update values in package.json:
name,displayName,descriptionpublisher(VS Code Marketplace publisher ID) - Note: It's recommended to use the organization's publisher for easier trust and no need for individual VSCE tokens.icon(this repo includes a placeholder atresources/icon.png— replace it with your own 128x128 (or 256x256) PNG)repository.url,bugs.url,homepage(remove<your-repository>placeholders)activationEventsandcontributes.commands[].command
Example:
npm pkg set name='vscode-my-extension'
npm pkg set displayName='WinCC OA — My Extension'
# Optional: Set your own publisher if not using the organization's
# npm pkg set publisher='my-publisher' # Requires VSCE_PAT and user trustAdditionally, this template includes a dummy "Hello World" project. Search for and replace the following placeholders throughout the codebase:
'hello-world'→ your extension's identifier or name'<your-repository>'→ your repository name
Also, update src/const.ts with the appropriate values for EXTENSION_ID, EXTENSION_NAME, and EXTENSION_CONFIG_SECTION.
- Replace the placeholder icon in
resources/icon.png. - Replace all occurrences of
<your-repository>with your actual repository name. - Update the Marketplace identifiers (
publisher,name) before publishing. - Update links in
package.json(repository,bugs,homepage) so they point to your new repo.
These scripts exist in this template:
- Build:
npm run compile - Watch:
npm run watch - Lint:
npm run lintandnpm run lint:md - Format check:
npm run format:check - Unit tests:
npm run test:unit - Integration tests (WinCC OA container):
npm run ci:integration
developis the default branch (day-to-day work)mainis the stable branch (releases)feature/*/bugfix/*targetdeveloprelease/vX.Y.Zandhotfix/vX.Y.Ztargetmain
Automation overview:
- PR validation:
.github/workflows/gitflow-validation.yml - Upmerge
main→developvia PR:.github/workflows/gitflow.yml - Create release/hotfix branches + PR:
.github/workflows/create-release-branch.yml- Important: this workflow does not update
CHANGELOG.md.
- Important: this workflow does not update
More details:
docs/automation/GITFLOW_WORKFLOW.md
- CI pipeline:
.github/workflows/ci-cd.yml - WinCC OA integration tests:
.github/workflows/integration-winccoa.yml
More details:
docs/automation/CI-INTEGRATION.md
This template uses a tested-artifact flow:
- A prerelease workflow builds/tests and uploads a VSIX to a GitHub pre-release.
- The stable release workflow requires that prerelease artifact and republishes that tested VSIX.
Workflows:
.github/workflows/pre-release.yml(alpha prerelease on PRs tomain).github/workflows/release.yml+.github/workflows/release-reusable.yml(stable release frommain)
Marketplace publishing:
- Optional secret:
VSCE_PAT(if set, the release workflow publishes to the VS Code Marketplace).
- Fill out the vision document:
docs/dev/VISION.md. - Update placeholders in
package.json(name, publisher, repo URLs, command IDs). - Decide on your default branch strategy (this template assumes
developis default). - Configure secrets (as needed):
VSCE_PAT(optional) to publish to VS Code Marketplace during stable release.REPO_ADMIN_TOKEN(recommended) to let.github/workflows/apply-settings-and-rulesets.ymlapply.github/repository.settings.ymland.github/rulesets/*.DOCKER_USER+DOCKER_PASSWORD(optional) only if your WinCC OA image is private on Docker Hub.
- Run Actions once to verify everything:
CI/CD PipelinePR Labels(open a PR to see labels apply)Git Flow Validation(open a PR to see validation)Integration Tests - WinCC OA(optional; requires a working image)
This template can apply repository settings + rulesets from YAML:
- Source of truth:
.github/repository.settings.yml.github/rulesets/*.yml
- Workflow:
.github/workflows/apply-settings-and-rulesets.yml
To apply settings/rulesets, provide an admin-capable token:
- Secret:
REPO_ADMIN_TOKEN- Classic PAT: scope
repo(and authorize SSO if required) - Fine-grained PAT: repository access + Administration: Read and write
- Classic PAT: scope
- VS Code: 1.107.1 or higher
- WinCC OA: 3.19+ installed on your system
MIT License. See https://github.com/winccoa-tools-pack/.github/blob/main/LICENSE.
WinCC OA and Siemens are trademarks of Siemens AG. This project is not affiliated with, endorsed by, or sponsored by Siemens AG. This is a community-driven open source project created to enhance the development experience for WinCC OA developers.
Made with ❤️ for and by the WinCC OA community