Skip to content

Commit

Permalink
Include also NPM Package Publish process in a single action with tag …
Browse files Browse the repository at this point in the history
…and release

Signed-off-by: Andrea Cosentino <[email protected]>
  • Loading branch information
oscerd authored and lordrip committed Jan 29, 2024
1 parent c6ae20b commit e0c88b9
Show file tree
Hide file tree
Showing 4 changed files with 58 additions and 144 deletions.
73 changes: 0 additions & 73 deletions .github/workflows/create-pre-release-pr.yml

This file was deleted.

41 changes: 0 additions & 41 deletions .github/workflows/publish-npm-package.yml

This file was deleted.

58 changes: 58 additions & 0 deletions .github/workflows/release-pipeline.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
name: Release Pipeline, create a tag/release for Kaoto Next and invoke publish NPM Package
on:
workflow_dispatch:
inputs:
tag_version:
type: The tag to release
description: The tag version we want to release
required: true

jobs:
build:
permissions:
contents: write
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Bump version and push tag
id: tag_version
uses: mathieudutour/[email protected]
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
custom_tag: ${{ github.event.inputs.tag_version }}
create_annotated_tag: true
tag_prefix: ""

- name: Create a GitHub release
uses: ncipollo/release-action@v1
with:
tag: ${{ steps.tag_version.outputs.new_tag }}
name: Release ${{ steps.tag_version.outputs.new_tag }}
body: ${{ steps.tag_version.outputs.changelog }}

- uses: actions/setup-node@v4
with:
node-version: '20.x'
registry-url: 'https://registry.npmjs.org'
scope: '@kaoto-next'
cache: 'yarn'

- uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '21'

- name: 🔧 Install dependencies
run: yarn

# Build lib
- name: Build @kaoto-next/ui package in lib mode
run: yarn workspace @kaoto-next/ui run build:lib

# Version and publish
- name: 'Version and publish'
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NODE_AUTH_TOKEN: ${{ secrets.KAOTO_NEXT_NPM_TOKEN }}
run: yarn publish
30 changes: 0 additions & 30 deletions .github/workflows/tag-and-release.yml

This file was deleted.

0 comments on commit e0c88b9

Please sign in to comment.