-
-
Notifications
You must be signed in to change notification settings - Fork 148
Expand file tree
/
Copy pathpublish-javascript-packages.yml
More file actions
43 lines (35 loc) · 945 Bytes
/
publish-javascript-packages.yml
File metadata and controls
43 lines (35 loc) · 945 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
name: Release JavaScript packages
on:
push:
tags:
- "v*"
jobs:
release:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup Bun
uses: oven-sh/setup-bun@v2
- name: Setup Node for npm publishing
uses: actions/setup-node@v4
with:
node-version: current
- name: Install dependencies
run: bun install
- name: Run tests
run: bun run test
- name: Build packages
run: bun run build
- name: Publish packages
env:
NPM_CONFIG_TOKEN: ${{ secrets.NPM_TOKEN }}
run: |
for package in packages/*; do
if [ -d "$package" ] && [ -f "$package/package.json" ]; then
cd "$package"
echo "Publishing package in $package"
bun publish --access public
cd ../..
fi
done