Skip to content

Commit

Permalink
fix: 🐛 pub ci
Browse files Browse the repository at this point in the history
  • Loading branch information
xiaochao.yang committed Dec 11, 2024
1 parent 51060c8 commit 5d5eab2
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,15 @@ jobs:
registry-url: https://registry.npmjs.org/
- name: Publish to npm
run: |
npm install @changesets/cli -g
npx changeset publish
# 遍历 packages 目录下的每个子目录
for dir in packages/*; do
# 确保该项是一个目录
if [ -d "$dir" ]; then
echo "Publishing package in $dir"
# 切换到该目录并执行 npm publish
(cd "$dir" && npm publish)
fi
done
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_ACCESS_TOKEN }}

Expand Down

0 comments on commit 5d5eab2

Please sign in to comment.