mirror of
https://github.com/garronej/ts-ci.git
synced 2025-11-30 21:43:05 +00:00
update
This commit is contained in:
parent
9cac1d6196
commit
7140742418
1 changed files with 12 additions and 5 deletions
17
.github/workflows/ci.yaml
vendored
17
.github/workflows/ci.yaml
vendored
|
|
@ -64,12 +64,14 @@ jobs:
|
||||||
outputs:
|
outputs:
|
||||||
from_version: ${{ steps.step1.outputs.from_version }}
|
from_version: ${{ steps.step1.outputs.from_version }}
|
||||||
to_version: ${{ steps.step1.outputs.to_version }}
|
to_version: ${{ steps.step1.outputs.to_version }}
|
||||||
is_upgraded_version: ${{steps.step1.outputs.is_upgraded_version }}
|
is_upgraded_version: ${{ steps.step1.outputs.is_upgraded_version }}
|
||||||
|
is_release_beta: ${{steps.step1.outputs.is_release_beta }}
|
||||||
steps:
|
steps:
|
||||||
- uses: garronej/ts-ci@v1.1.0
|
- uses: garronej/ts-ci@v1.1.0
|
||||||
id: step1
|
id: step1
|
||||||
with:
|
with:
|
||||||
action_name: is_package_json_version_upgraded
|
action_name: is_package_json_version_upgraded
|
||||||
|
branch: ${{ github.head_ref }}
|
||||||
|
|
||||||
update_changelog:
|
update_changelog:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
@ -79,7 +81,7 @@ jobs:
|
||||||
- uses: garronej/ts-ci@v1.1.0
|
- uses: garronej/ts-ci@v1.1.0
|
||||||
with:
|
with:
|
||||||
action_name: update_changelog
|
action_name: update_changelog
|
||||||
branch: ${{ github.ref }}
|
branch: ${{ github.head_ref }}
|
||||||
|
|
||||||
create_github_release:
|
create_github_release:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
@ -105,10 +107,10 @@ jobs:
|
||||||
with:
|
with:
|
||||||
name: Release v${{ needs.check_if_version_upgraded.outputs.to_version }}
|
name: Release v${{ needs.check_if_version_upgraded.outputs.to_version }}
|
||||||
tag_name: v${{ needs.check_if_version_upgraded.outputs.to_version }}
|
tag_name: v${{ needs.check_if_version_upgraded.outputs.to_version }}
|
||||||
target_commitish: ${{ github.ref }}
|
target_commitish: ${{ github.head_ref }}
|
||||||
body: ${{ steps.step1.outputs.body }}
|
body: ${{ steps.step1.outputs.body }}
|
||||||
draft: false
|
draft: false
|
||||||
prerelease: ${{ needs.check_if_version_upgraded.outputs.to_version.is_release_beta == 'true' }}
|
prerelease: ${{ needs.check_if_version_upgraded.outputs.is_release_beta == 'true' }}
|
||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
|
|
@ -145,7 +147,12 @@ jobs:
|
||||||
echo "Can't publish on NPM, You must first create a secret called NPM_TOKEN that contains your NPM auth token. https://help.github.com/en/actions/automating-your-workflow-with-github-actions/creating-and-using-encrypted-secrets"
|
echo "Can't publish on NPM, You must first create a secret called NPM_TOKEN that contains your NPM auth token. https://help.github.com/en/actions/automating-your-workflow-with-github-actions/creating-and-using-encrypted-secrets"
|
||||||
false
|
false
|
||||||
fi
|
fi
|
||||||
npm publish
|
EXTRA_ARGS=""
|
||||||
|
if [ "$IS_BETA" = "true" ]; then
|
||||||
|
EXTRA_ARGS="--tag beta"
|
||||||
|
fi
|
||||||
|
npm publish $EXTRA_ARGS
|
||||||
env:
|
env:
|
||||||
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
|
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
|
||||||
VERSION: ${{ needs.check_if_version_upgraded.outputs.to_version }}
|
VERSION: ${{ needs.check_if_version_upgraded.outputs.to_version }}
|
||||||
|
IS_BETA: ${{ needs.check_if_version_upgraded.outputs.is_release_beta }}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue