Skip to content

Commit

Permalink
Merge pull request #36 from evoactivity/commit-version-to-package.json
Browse files Browse the repository at this point in the history
CI: Commit package.json after version bump
  • Loading branch information
lifeart committed Jul 15, 2023
2 parents 44b722d + d63312b commit 96b316b
Showing 1 changed file with 12 additions and 12 deletions.
24 changes: 12 additions & 12 deletions .github/workflows/workflow.yaml
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
on:
push:
branches:
- 'feature/**' # match an pushes on feature/* and feature/<any sub branch>/*
- "feature/**" # match an pushes on feature/* and feature/<any sub branch>/*
- master
paths-ignore: # dont run when changes made to these folders
- '.vscode/**'
- ".vscode/**"

jobs:
cicd:
Expand All @@ -21,15 +21,15 @@ jobs:
- name: install gitversion tool
uses: gittools/actions/gitversion/setup@v0.9
with:
versionSpec: '6.0.0-beta.3'
versionSpec: "6.0.0-beta.3"
env:
ACTIONS_ALLOW_UNSECURE_COMMANDS: 'true'
ACTIONS_ALLOW_UNSECURE_COMMANDS: "true"

- name: execute gitversion
id: gitversion # step id used as reference for output values
uses: gittools/actions/gitversion/execute@v0.9.3
env:
ACTIONS_ALLOW_UNSECURE_COMMANDS: 'true'
ACTIONS_ALLOW_UNSECURE_COMMANDS: "true"

- name: print gitversion
run: |
Expand All @@ -48,16 +48,17 @@ jobs:
- name: update metadata in package.json
uses: onlyutkarsh/patch-files-action@v1.0.1
with:
files: '${{github.workspace}}/package.json'
files: "${{github.workspace}}/package.json"
patch-syntax: |
= /version => "${{ steps.gitversion.outputs.majorMinorPatch }}"
- name: add version in CHANGELOG.md
uses: cschleiden/replace-tokens@v1.0
- name: add and commit package.json
uses: EndBug/add-and-commit@v9
with:
files: '${{github.workspace}}/CHANGELOG.md'
env:
VERSION: "${{ steps.gitversion.outputs.majorMinorPatch }}"
add: "package.json"
default_author: github_actions
message: "chore: update package.json version to ${{ steps.gitversion.outputs.majorMinorPatch }}"
tag: "v${{ steps.gitversion.outputs.majorMinorPatch }}"

- name: compile for node
run: yarn node:package
Expand Down Expand Up @@ -86,7 +87,6 @@ jobs:
OPEN_VSX_STORE_TOKEN: ${{ secrets.OPEN_VSX_STORE_TOKEN }} # This token is provided by Actions, you do not need to create your own token
run: yarn ov:publish:ci


- name: create a release
if: github.ref == 'refs/heads/master'
uses: actions/create-release@v1
Expand Down

0 comments on commit 96b316b

Please sign in to comment.