Skip to content

Release Gen2 Migration #8

Release Gen2 Migration

Release Gen2 Migration #8

name: Release Gen2 Migration
on:
workflow_dispatch: {}
jobs:
release:
runs-on: ubuntu-latest
environment: release-gen2-migration
steps:
- name: Checkout repository
uses: actions/checkout@v3
with:
ref: gen2-migration
- name: Setup Node.js
uses: actions/setup-node@v5
with:
node-version: 22.x
- name: Install
run: |
node --version
npm --version
yarn install
- name: Build
run: |
yarn build
- name: Release
run: |
cd packages/amplify-cli
package_name="@aws-amplify/cli-internal-gen2-migration-experimental-alpha"
latest_version=$(npm view ${package_name} version 2>/dev/null || echo "0.0.0")
new_version=$(npx semver --increment minor ${latest_version})
npm version ${new_version} --no-workspace-update --no-commit-hooks --no-git-tag-version --no-workspaces
npm pkg set name=${package_name}
npm pack
npm i -g npm@latest
npm --version
NPM_TRUSTED_PUBLISHER="true" npm run publish