Skip to content

Commit 138ccf1

Browse files
committed
chore: use Pantry action for publish-commit and add job dependencies
1 parent ec99c35 commit 138ccf1

File tree

1 file changed

+10
-12
lines changed

1 file changed

+10
-12
lines changed

.github/workflows/ci.yml

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -112,21 +112,16 @@ jobs:
112112
timeout-minutes: 2
113113

114114
publish-commit:
115+
needs: [lint, typecheck, test]
115116
runs-on: ubuntu-latest
116117

117118
steps:
118-
- uses: actions/checkout@v6.0.0
119-
120-
- name: Install Bun
121-
uses: oven-sh/setup-bun@v2.0.2
122-
123-
- name: Use cached node_modules
124-
uses: actions/cache@v4.3.0
119+
- uses: actions/checkout@v6
125120
with:
126-
path: node_modules
127-
key: node-modules-${{ hashFiles('**/bun.lock') }}
128-
restore-keys: |
129-
node-modules-
121+
fetch-depth: 0
122+
123+
- name: Setup Pantry
124+
uses: home-lang/pantry/packages/action@main
130125

131126
- name: Install Dependencies
132127
run: bun install
@@ -135,4 +130,7 @@ jobs:
135130
run: bun run build
136131

137132
- name: Publish Commit
138-
run: bunx pkg-pr-new publish './packages/action' './packages/bumpx'
133+
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
134+
run: pantry publish:commit './packages/action' './packages/bumpx'
135+
env:
136+
PANTRY_REGISTRY_TOKEN: ${{ secrets.PANTRY_TOKEN }}

0 commit comments

Comments
 (0)