Skip to content

Commit 9a5629b

Browse files
Fix Firefox manifest warning for version_name property
- Only inject version_name into Chrome manifest (Firefox warns about unknown properties at runtime) - Enable strict linting with --warnings-as-errors - Update strict_min_version to 142.0 (required for data_collection_permissions) - Update BUILD.md to document version_name is Chrome-only Fixes #8 Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
1 parent 3bc0856 commit 9a5629b

4 files changed

Lines changed: 9 additions & 5 deletions

File tree

BUILD.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ This extension maintains **separate manifest files** due to incompatible Manifes
5555
"browser_specific_settings": {
5656
"gecko": {
5757
"id": "github-bookmarked-issues@extensions",
58-
"strict_min_version": "128.0",
58+
"strict_min_version": "142.0",
5959
"data_collection_permissions": {"required": ["none"]}
6060
}
6161
}
@@ -168,7 +168,8 @@ The script outputs a `GITHUB_AUTH_STATE` value to add to `.env`. Sessions expire
168168

169169
### Version Tracking
170170

171-
Dev builds include git commit info in `version_name` (visible in `chrome://extensions` or `about:addons`):
171+
Dev builds include git commit info in `version_name` (Chrome only, visible in `chrome://extensions`).
172+
Firefox does not support `version_name`; it warns about unknown manifest properties at runtime.
172173

173174
| Build Type | version_name Example |
174175
|----------------------------|-------------------------------------------|

extension/manifest-firefox.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"browser_specific_settings": {
88
"gecko": {
99
"id": "github-bookmarked-issues@extensions",
10-
"strict_min_version": "128.0",
10+
"strict_min_version": "142.0",
1111
"data_collection_permissions": {
1212
"required": ["none"]
1313
}

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
"build": "npm run build:chrome && npm run build:firefox",
1212
"postbuild": "npm run lint",
1313
"dev:watch": "node scripts/dev-watch.js",
14-
"lint": "web-ext lint --source-dir=build/firefox --artifacts-dir=build",
14+
"lint": "web-ext lint --source-dir=build/firefox --artifacts-dir=build --warnings-as-errors",
1515
"test": "playwright test",
1616
"test:chrome": "playwright test --project=chromium",
1717
"test:visual": "playwright test --grep @visual",

scripts/copy.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,10 @@ async function build() {
9494

9595
const versionName = getVersionName(manifest.version);
9696
if (versionName !== manifest.version) {
97-
manifest.version_name = versionName;
97+
// version_name is Chrome-specific; Firefox warns about unknown properties
98+
if (browser === 'chrome') {
99+
manifest.version_name = versionName;
100+
}
98101
console.log(` Version: ${versionName}`);
99102
}
100103

0 commit comments

Comments
 (0)