action.version
GitHub Action for ContractSpec version management
appsappv5.0.4stableservernode
@lssm-tech/action.versionbun add @lssm-tech/action.versionManifest declarations describe the current workspace; they do not verify registry publication or runtime execution.
Package guide
Website: https://contractspec.io
GitHub Action for automated ContractSpec version management in CI.
What It Does
- Standalone action with no workspace dependencies
- Configured entirely via
action.yml; no TypeScript source
Usage
yaml
name: ContractSpec Version Manager
on: pull_request
jobs:
contractspec:
runs-on: ubuntu-latest
permissions:
contents: write
packages: read
pull-requests: write
steps:
- uses: actions/checkout@v6
- uses: lssm-tech/contractspec/packages/apps/action-version@main
with:
github-packages-token: ${{ secrets.CONTRACTSPEC_PACKAGES_TOKEN }}For affected private GitHub Packages dependencies, github-packages-token must be a GitHub token that can read the ContractSpec packages granted to the consuming repository, bot, or GitHub App.
Inputs
mode(default:analyze) — Action mode: analyze (check only) or bump (apply changes)auto-bump(default:false) — Whether to automatically applying bumps based on impact analysiscommit-message(default:chore(release): bump spec versions [skip ci]) — Commit message for version bumpscreate-pr(default:false) — Create a Pull Request instead of pushing directlypr-title(default:chore(release): version packages) — Title for the Pull Requestpr-branch(default:release/next-versions) — Branch name for the Pull Requestgithub-token(default:${{ github.token }}) — GitHub Token for creating PRsgithub-packages-token— Optional token used to configure private GitHub Packages auth before dependency installs
Outputs
has-changes— Whether changes were detected/appliedspecs-bumped— Number of specs bumped
Key Files
action.yml— GitHub Action definition (entry point)tests/action-version.test.ts— standalone host test (bun run test): runs theaction.ymlsteps locally with recordingbun/bunx/git/ghstubs; requiresjq
Recent Updates
- Replace eslint+prettier by biomejs to optimize speed
- PublishConfig not supported by bun
- Move automation into actions
Notes
- Do not change
action.ymlinputs/outputs without updating downstream workflow consumers - This is a standalone action — avoid adding workspace dependencies unless necessary
Relationships
THIS PACKAGEaction.version1 import paths
Arrows point from a package to its direct dependency. Counts are derived from captured workspace manifests.
1 declarations
@lssm-tech/lib.contracts-specworkspace:^
Read the package manual ↗
Declared capabilities
This manifest does not declare a capability catalogue. Use the guide, import map and source to assess the package.
Scripts
testbun test