Skip to content

Commit c4ab48b

Browse files
committed
js setup
1 parent cc0c359 commit c4ab48b

File tree

2 files changed

+70
-0
lines changed

2 files changed

+70
-0
lines changed

Diff for: .github/workflows/js-build.yml

+35
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: JS (build)
2+
3+
on:
4+
push:
5+
paths:
6+
- 'visual-js/**'
7+
- .github/workflows/js-build.yml
8+
pull_request:
9+
paths:
10+
- 'visual-js/**'
11+
- .github/workflows/js-build.yml
12+
13+
defaults:
14+
run:
15+
working-directory: visual-js
16+
17+
jobs:
18+
build:
19+
runs-on: ubuntu-latest
20+
steps:
21+
- uses: actions/checkout@v4
22+
- name: Setup Node 18
23+
uses: actions/setup-node@v4
24+
with:
25+
node-version: 18.x
26+
- name: Build with lerna
27+
run: |
28+
corepack enable
29+
yarn install
30+
npx lerna run lint
31+
npx lerna run build
32+
npx lerna run test
33+
env:
34+
SAUCE_USERNAME: ${{ secrets.SAUCE_USERNAME }}
35+
SAUCE_ACCESS_KEY: ${{ secrets.SAUCE_ACCESS_KEY }}

Diff for: .github/workflows/js-release.yml

+35
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: JS (release)
2+
3+
on:
4+
workflow_dispatch: {}
5+
6+
defaults:
7+
run:
8+
working-directory: visual-js
9+
10+
jobs:
11+
release:
12+
runs-on: ubuntu-latest
13+
steps:
14+
- uses: actions/checkout@v4
15+
- name: Setup Node 18
16+
uses: actions/setup-node@v4
17+
with:
18+
node-version: 18.x
19+
- name: Setup Git
20+
if: ${{ steps.prep.outputs.tag_name == '' }}
21+
run: |
22+
git config --global user.name "sauce-visual-bot"
23+
git config --global user.email "[email protected]"
24+
- name: Build
25+
run: |
26+
corepack enable
27+
yarn install
28+
npx lerna run build
29+
- name: upgrade & publish version(s)
30+
run: |
31+
npx changeset version
32+
npx changeset publish
33+
- name: Push to git
34+
run: |
35+
git push --follow-tags

0 commit comments

Comments
 (0)