mcp-chrome-bridger 1.0.7 → 1.0.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mcp-chrome-bridger",
3
- "version": "1.0.7",
3
+ "version": "1.0.8",
4
4
  "description": "Chrome Native-Messaging host (Node) - Fork with Chrome Web Store support",
5
5
  "main": "dist/index.js",
6
6
  "bin": {
@@ -19,7 +19,8 @@
19
19
  "postinstall": "node scripts/postinstall-check.js"
20
20
  },
21
21
  "files": [
22
- "dist"
22
+ "dist",
23
+ "scripts"
23
24
  ],
24
25
  "engines": {
25
26
  "node": ">=14.0.0"
@@ -0,0 +1,21 @@
1
+ #!/usr/bin/env node
2
+
3
+ /**
4
+ * Postinstall wrapper script
5
+ * Checks if the compiled postinstall.js exists before running it.
6
+ * This handles CI environments where dist/ doesn't exist yet during pnpm install.
7
+ */
8
+
9
+ const fs = require('fs');
10
+ const path = require('path');
11
+
12
+ const postinstallPath = path.join(__dirname, '..', 'dist', 'scripts', 'postinstall.js');
13
+
14
+ if (fs.existsSync(postinstallPath)) {
15
+ // dist/ exists, run the actual postinstall script
16
+ require(postinstallPath);
17
+ } else {
18
+ // dist/ doesn't exist yet (CI build or fresh clone)
19
+ // This is expected - the postinstall will run when users install the published package
20
+ console.log('Skipping postinstall: dist/ not built yet (CI/development environment)');
21
+ }