init
This commit is contained in:
30
.gitea/workflows/setPackageVersion.yaml
Normal file
30
.gitea/workflows/setPackageVersion.yaml
Normal file
@@ -0,0 +1,30 @@
|
||||
name: Set Package Version
|
||||
on:
|
||||
workflow_call:
|
||||
inputs:
|
||||
version:
|
||||
required: true
|
||||
type: string
|
||||
branch:
|
||||
required: true
|
||||
type: string
|
||||
jobs:
|
||||
SetVersion:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Check out repository code
|
||||
uses: actions/checkout@v4
|
||||
- name: Set
|
||||
run: |
|
||||
echo "Setting Version to ${{ inputs.version }}"
|
||||
npm version --no-git-tag-version ${{ inputs.version }}
|
||||
- name: Commit version change
|
||||
run: |
|
||||
git config user.name "${{ vars.GIT_DEPLOY_NAME }}"
|
||||
git config user.email "${{ vars.GIT_DEPLOY_MAIL }}"
|
||||
git add package.json
|
||||
git commit -m "Update package.json version to $TAG_VERSION"
|
||||
|
||||
- name: Push changes back to repository
|
||||
run: |
|
||||
git push origin HEAD:${{ inputs.branch }}
|
||||
Reference in New Issue
Block a user