Skip to content

updated unit testcase yml #28

updated unit testcase yml

updated unit testcase yml #28

name: Release CLI Core (v1 Beta)

Check failure on line 1 in .github/workflows/release-v1-beta-core.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/release-v1-beta-core.yml

Invalid workflow file

(Line: 6, Col: 3): Unexpected value 'paths', (Line: 7, Col: 5): A sequence was not expected
on:
push:
branches: [v1-beta]
paths:
- 'packages/contentstack/package.json'
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v4
with:
version: 10.28.0
- uses: actions/setup-node@v4
with:
node-version: '22.x'
- name: Enable Corepack
run: corepack enable
- name: Install pnpm
run: corepack prepare pnpm@10.28.0 --activate
- name: Install root dependencies
run: pnpm install
- name: Reading Configuration
id: release_config
uses: rgarcia-phi/json-to-variables@v1.1.0
with:
filename: .github/config/release.json
prefix: release
# Core CLI
- name: Installing dependencies of core
id: core-installation
if: ${{env.release_releaseAll == 'true' || env.release_plugins_core == 'true'}}
working-directory: ./packages/contentstack
run: npm install
- name: Compiling core
if: ${{ steps.core-installation.conclusion == 'success' }}
working-directory: ./packages/contentstack
run: npm run prepack
- name: Publishing core (Beta)
id: publish-core
uses: JS-DevTools/npm-publish@v3
if: ${{ steps.core-installation.conclusion == 'success' }}
with:
token: ${{ secrets.NPM_TOKEN }}
package: ./packages/contentstack/package.json
tag: beta
- name: Create Core Beta Release
if: ${{ steps.publish-core.conclusion == 'success' }}
id: create_release
env:
GITHUB_TOKEN: ${{ secrets.PKG_TOKEN }}
VERSION: ${{ steps.publish-core.outputs.version }}
run: |
TAG="core@v${VERSION}"
if gh release view "$TAG" &>/dev/null; then
echo "Release $TAG already exists — skipping."
else
gh release create "$TAG" \
--title "Core Beta $VERSION" \
--generate-notes \
--prerelease
fi