Skip to content

Commit 36ef885

Browse files
committed
fix: trust @ast-grep/napi in CI to enable native module install scripts
1 parent 909ce37 commit 36ef885

File tree

2 files changed

+26
-3
lines changed

2 files changed

+26
-3
lines changed

.github/workflows/publish.yml

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,9 +49,31 @@ jobs:
4949

5050
- name: Install dependencies
5151
run: bun install
52+
env:
53+
BUN_INSTALL_ALLOW_SCRIPTS: "@ast-grep/napi"
54+
55+
- name: Debug environment
56+
run: |
57+
echo "=== Bun version ==="
58+
bun --version
59+
echo "=== Node version ==="
60+
node --version
61+
echo "=== Current directory ==="
62+
pwd
63+
echo "=== List src/ ==="
64+
ls -la src/
65+
echo "=== package.json scripts ==="
66+
cat package.json | jq '.scripts'
5267
5368
- name: Build
54-
run: bun run build
69+
run: |
70+
echo "=== Running bun build ==="
71+
bun build src/index.ts --outdir dist --target bun --format esm --external @ast-grep/napi
72+
echo "=== bun build exit code: $? ==="
73+
echo "=== Running tsc ==="
74+
tsc --emitDeclarationOnly
75+
echo "=== Running build:schema ==="
76+
bun run build:schema
5577
5678
- name: Verify build output
5779
run: |

package.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "oh-my-opencode",
3-
"version": "0.1.5",
3+
"version": "0.1.6",
44
"description": "OpenCode plugin - custom agents (oracle, librarian) and enhanced features",
55
"main": "dist/index.js",
66
"types": "dist/index.d.ts",
@@ -57,6 +57,7 @@
5757
"bun": ">=1.0.0"
5858
},
5959
"trustedDependencies": [
60-
"@ast-grep/cli"
60+
"@ast-grep/cli",
61+
"@ast-grep/napi"
6162
]
6263
}

0 commit comments

Comments
 (0)