Skip to content

Commit

Permalink
js setup
Browse files Browse the repository at this point in the history
  • Loading branch information
kb-kerem committed Apr 24, 2024
1 parent cc0c359 commit c4ab48b
Show file tree
Hide file tree
Showing 2 changed files with 70 additions and 0 deletions.
35 changes: 35 additions & 0 deletions .github/workflows/js-build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: JS (build)

on:
push:
paths:
- 'visual-js/**'
- .github/workflows/js-build.yml
pull_request:
paths:
- 'visual-js/**'
- .github/workflows/js-build.yml

defaults:
run:
working-directory: visual-js

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Setup Node 18
uses: actions/setup-node@v4
with:
node-version: 18.x
- name: Build with lerna
run: |
corepack enable
yarn install
npx lerna run lint
npx lerna run build
npx lerna run test
env:
SAUCE_USERNAME: ${{ secrets.SAUCE_USERNAME }}
SAUCE_ACCESS_KEY: ${{ secrets.SAUCE_ACCESS_KEY }}
35 changes: 35 additions & 0 deletions .github/workflows/js-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: JS (release)

on:
workflow_dispatch: {}

defaults:
run:
working-directory: visual-js

jobs:
release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Setup Node 18
uses: actions/setup-node@v4
with:
node-version: 18.x
- name: Setup Git
if: ${{ steps.prep.outputs.tag_name == '' }}
run: |
git config --global user.name "sauce-visual-bot"
git config --global user.email "[email protected]"
- name: Build
run: |
corepack enable
yarn install
npx lerna run build
- name: upgrade & publish version(s)
run: |
npx changeset version
npx changeset publish
- name: Push to git
run: |
git push --follow-tags

0 comments on commit c4ab48b

Please sign in to comment.