electron-builder icon indicating copy to clipboard operation
electron-builder copied to clipboard

`FlatpakOptions.files` has inconsistent type

Open rotu opened this issue 1 year ago • 5 comments

  • Electron-Builder Version: 8e36be113489c1afa6ce5ee6cdda73049bc619a6
  • Node Version: N/A
  • Electron Version: N/A
  • Electron Type (current, beta, nightly): N/A
  • Target: Linux

Type FlatpakOptions is incompatible with PlatformSpecificBuildOptions due to conflicting types of the files property.

PlatformSpecificBuildOptions: https://github.com/electron-userland/electron-builder/blob/8e36be113489c1afa6ce5ee6cdda73049bc619a6/packages/app-builder-lib/src/options/PlatformSpecificBuildOptions.ts#L53

whereas FlatpakOptions: https://github.com/electron-userland/electron-builder/blob/8e36be113489c1afa6ce5ee6cdda73049bc619a6/packages/app-builder-lib/src/options/linuxOptions.ts#L219-L224

These two objects are merged together in FlatpakTarget but the type incompatibility is obscured behind an as any cast.

https://github.com/electron-userland/electron-builder/blob/8e36be113489c1afa6ce5ee6cdda73049bc619a6/packages/app-builder-lib/src/targets/FlatpakTarget.ts#L12-L16

rotu avatar Mar 31 '24 02:03 rotu

Found during development on macOS. I'm not sure the actual runtime implications of this since I'm not on Linux.

rotu avatar Mar 31 '24 02:03 rotu

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 30 days.

github-actions[bot] avatar May 31 '24 00:05 github-actions[bot]

not stale

rotu avatar May 31 '24 04:05 rotu

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 30 days.

github-actions[bot] avatar Aug 01 '24 00:08 github-actions[bot]

not stale

rotu avatar Aug 01 '24 20:08 rotu