Skip to content

Commit

Permalink
test by changing trigger
Browse files Browse the repository at this point in the history
  • Loading branch information
varadarajan-tw committed Jul 5, 2024
1 parent 2b71367 commit 71fde77
Showing 1 changed file with 14 additions and 11 deletions.
25 changes: 14 additions & 11 deletions .github/workflows/version-packages.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,15 @@
# This workflow is triggered manually via the GitHub Actions page or API
name: Version Packages
on:
workflow_dispatch:
inputs:
branch:
description: 'Branch to create PR from'
required: true
default: 'release-actions'
# workflow_dispatch:
# inputs:
# branch:
# description: 'Branch to create PR from'
# required: true
# default: 'release-actions'
push:
branches:
- new-prod-release-workflow

jobs:
build-and-version-packages:
Expand All @@ -31,8 +34,8 @@ jobs:

- name: Checkout branch
run: |
git checkout -b ${{ github.event.inputs.branch }}
git push origin ${{ github.event.inputs.branch }}
git checkout -b release-test
git push origin release-test
- name: Install Dependencies
run: yarn install --frozen-lockfile --ignore-optional
Expand All @@ -46,17 +49,17 @@ jobs:
run: NODE_ENV=production yarn build

- name: Version Packages
run: yarn lerna version minor --allow-branch ${{ github.event.inputs.branch }} --no-git-tag-version --no-commit-hooks --no-private --yes
run: yarn lerna version minor --allow-branch release-test --no-git-tag-version --no-commit-hooks --no-private --yes

- name: Commit and push
run: |
git add .
packages_published=$(git status -s -uno| grep "package.json" |awk '{print $2}'| xargs jq -r '.name + "@" + .version' --argjson null {})
git commit -m "Publish" -m "$packages_published"
git push origin ${{ github.event.inputs.branch }}
git push origin release-test
- name: Create PR
run: |
gh pr create --base main --head ${{ github.event.inputs.branch }} --fill --draft
gh pr create --base main --head release-test --fill --draft
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit 71fde77

Please sign in to comment.