Skip to content

Workflow file for this run

name: Typescript.Build CI/CD
on:
push:
branches:
- "**"
pull_request:
types: [closed]
jobs:
build:
name: Continuous Integration
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Setup node v16
uses: actions/setup-node@v3
with:
node-version: 16.x
registry-url: "https://registry.npmjs.org"
- name: Setup Bun
uses: oven-sh/setup-bun@v1
with:
bun-version: latest
- run: bun install
name: Install dependencies
- run: bun run ci
name: Build, Lint and Test
- name: Establish context
id: context
uses: woksin-org/establish-context-action@v2
- name: Increment version
id: increment-version
if: ${{ steps.context.outputs.should-publish == 'true' }}
uses: woksin-org/increment-version-action@v2
with:
version: ${{ steps.context.outputs.current-version }}
release-type: ${{ steps.context.outputs.release-type }}
- name: Release JavaScript
if: ${{ steps.context.outputs.should-publish == 'true' }}
uses: woksin-org/release-typescript-lib-action@v1
with:
version: ${{ steps.increment-version.outputs.next-version }}
root: "."
user-email: sindrewilting@gmail.com
user-name: woksin
env:
NODE_AUTH_TOKEN: ${{ secrets.TOKEN_NPM }}
- name: Prepend to Changelog
if: ${{ steps.context.outputs.should-publish == 'true' && steps.context.outputs.release-type != 'prerelease' }}
uses: woksin-org/add-to-changelog-action@v2
with:
version: ${{ steps.increment-version.outputs.next-version }}
body: ${{ steps.context.outputs.pr-body }}
pr-url: ${{ steps.context.outputs.pr-url }}
changelog-path: CHANGELOG.md
user-email: sindrewilting@gmail.com
user-name: woksin
- name: Create GitHub Release
if: ${{ steps.context.outputs.should-publish == 'true' }}
uses: woksin-org/github-release-action@v2
with:
token: ${{ secrets.BUILD_PAT }}
version: ${{ steps.increment-version.outputs.next-version }}
body: ${{ steps.context.outputs.pr-body }}