GitHub Action
Get OpenAPI updated package version
v1.0.2
Latest version
A GitHub Action for getting appropriate updated SemVer OpenAPI package version.
The following example workflow steps will generate a new version by previous tag and updated state from OpenAPITools/openapi-diff.
- name: "Find difference between OpenAPI specifications"
id: diff_state
uses: swimmwatch/openapi-diff-action@v1.0.2
with:
old-spec: "old_spec.json"
new-spec: "new_spec.json"
- name: "Get previous tag"
id: previous_tag
uses: WyriHaximus/github-action-get-previous-tag@v1
env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
- name: "Get appropriate new package version"
id: updated_version
uses: swimmwatch/openapi-diff-semver-bump@v1
with:
package-version: ${{steps.previous_tag.outputs.tag}}
updated-state: ${{steps.diff_state.outputs.state}}
The following input variables options can/must be configured:
Input variable | Necessity | Description | Default |
---|---|---|---|
package-version |
Required | Package SemVer version | |
updated-state |
Required | Output state from OpenAPITools/openapi-diff: no_changes , incompatible , compatible |
new-package-version
: New package SemVer version e.g.1.2.3
.
openapi-diff-semver-bump is licensed under the MIT License.