Merge pull request #914 from 4gray/codex/fix-linux-window-identity

fix(linux): align packaged app identity
This commit is contained in:
4gray authored and GitHub committed 2026-05-09 20:11:07 +02:00
commit eb0da5951f
4 files changed
+51 -1

No files matched your search

+8
View File
@@ -24,6 +24,8 @@
"**/*.dylib"
],
"extraMetadata": {
"name": "iptvnator",
"productName": "IPTVnator",
"main": "electron-backend/main.js"
},
"extraResources": ["dist/apps/electron-backend/workers"],
@@ -43,6 +45,12 @@
},
"linux": {
"category": "Video",
"executableName": "iptvnator",
"desktop": {
"entry": {
"StartupWMClass": "iptvnator"
}
},
"target": [
{
"target": "AppImage",
+1 -1
View File
@@ -32,7 +32,7 @@
"test:frontend": "nx test web",
"test:backend": "nx test electron-backend",
"test:unit:all": "nx run-many --target=test --all --parallel=3",
"test:unit:ci": "nx run-many --target=test --projects=electron-backend,web,services,m3u-state,portal-stalker-data-access,portal-shared-util,playlist-shared-ui,portal-xtream-data-access,portal-xtream-feature,workspace-dashboard-data-access,components,@iptvnator/pipes --parallel=3 --output-style=static",
"test:unit:ci": "nx run-many --target=test --projects=electron-backend,web,services,m3u-state,portal-stalker-data-access,portal-shared-util,playlist-shared-ui,portal-xtream-data-access,portal-xtream-feature,workspace-dashboard-data-access,components,@iptvnator/pipes,packaging --parallel=3 --output-style=static",
"typecheck:web": "tsc -p apps/web/tsconfig.app.json --noEmit",
"typecheck:backend": "tsc -p apps/electron-backend/tsconfig.app.json --noEmit",
"typecheck:ci": "pnpm run typecheck:web && pnpm run typecheck:backend",
@@ -0,0 +1,24 @@
import assert from 'node:assert/strict';
import fs from 'node:fs';
import { dirname, join } from 'node:path';
import test from 'node:test';
import { fileURLToPath } from 'node:url';
const currentDir = dirname(fileURLToPath(import.meta.url));
const electronBuilderConfig = JSON.parse(
fs.readFileSync(
join(currentDir, '..', '..', 'electron-builder.json'),
'utf8'
)
);
test('Linux package identity does not expose the internal Electron backend project name', () => {
assert.equal(electronBuilderConfig.productName, 'IPTVnator');
assert.equal(electronBuilderConfig.extraMetadata?.name, 'iptvnator');
assert.equal(electronBuilderConfig.extraMetadata?.productName, 'IPTVnator');
assert.equal(electronBuilderConfig.linux?.executableName, 'iptvnator');
assert.equal(
electronBuilderConfig.linux?.desktop?.entry?.StartupWMClass,
'iptvnator'
);
});
+18
View File
@@ -0,0 +1,18 @@
{
"$schema": "../../node_modules/nx/schemas/project-schema.json",
"name": "packaging",
"projectType": "library",
"sourceRoot": "tools/packaging",
"targets": {
"test": {
"executor": "nx:run-commands",
"cache": true,
"inputs": ["default", "{workspaceRoot}/electron-builder.json"],
"options": {
"command": "node --test tools/packaging/electron-package-identity.test.mjs",
"cwd": "{workspaceRoot}"
}
}
},
"tags": ["scope:tools", "type:tool"]
}