add package path
This commit is contained in:
parent
7a4281f48a
commit
0d48f86180
@ -8,6 +8,9 @@ on:
|
|||||||
branch:
|
branch:
|
||||||
required: true
|
required: true
|
||||||
type: string
|
type: string
|
||||||
|
packagePath:
|
||||||
|
required: false
|
||||||
|
type: string
|
||||||
jobs:
|
jobs:
|
||||||
SetVersion:
|
SetVersion:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
@ -19,7 +22,14 @@ jobs:
|
|||||||
git pull origin HEAD:${{ inputs.branch }}
|
git pull origin HEAD:${{ inputs.branch }}
|
||||||
|
|
||||||
echo "Setting Version to ${{ inputs.version }}"
|
echo "Setting Version to ${{ inputs.version }}"
|
||||||
|
|
||||||
|
git_path=pwd
|
||||||
|
if [ "${{ inputs.packagePath }}" != "null" ]; then
|
||||||
|
cd ${{ inputs.packagePath }}
|
||||||
|
fi
|
||||||
|
|
||||||
npm version --no-git-tag-version ${{ inputs.version }}
|
npm version --no-git-tag-version ${{ inputs.version }}
|
||||||
|
cd $git_path
|
||||||
- name: Commit version change
|
- name: Commit version change
|
||||||
run: |
|
run: |
|
||||||
if git diff --quiet && git diff --cached --quiet; then
|
if git diff --quiet && git diff --cached --quiet; then
|
||||||
|
Loading…
Reference in New Issue
Block a user