Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: integrate @electron/universal #1346

Merged
merged 10 commits into from
Apr 19, 2022
Merged

feat: integrate @electron/universal #1346

merged 10 commits into from
Apr 19, 2022

Conversation

MarshallOfSound
Copy link
Member

As in title, this integrates @electron/universal into packager by intercepting package requests for "universal" and then building arm64 / x64 separately behind the scenes and stitching them together.

@codecov
Copy link

codecov bot commented Mar 23, 2022

Codecov Report

Merging #1346 (469cbd7) into main (b66e97f) will decrease coverage by 4.01%.
The diff coverage is 27.90%.

@@             Coverage Diff             @@
##              main    #1346      +/-   ##
===========================================
- Coverage   100.00%   95.98%   -4.02%     
===========================================
  Files           14       15       +1     
  Lines          733      773      +40     
===========================================
+ Hits           733      742       +9     
- Misses           0       31      +31     
Impacted Files Coverage Δ
src/universal.js 14.28% <14.28%> (ø)
src/index.js 98.94% <85.71%> (-1.06%) ⬇️
src/targets.js 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update b66e97f...469cbd7. Read the comment docs.

@erickzhao erickzhao requested a review from a team March 23, 2022 18:27
Copy link
Member

@VerteDinde VerteDinde left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! 👍

@@ -16,6 +16,9 @@ import {
TransporterOptions
} from 'electron-notarize/lib/types';
import { SignOptions } from 'electron-osx-sign';
import type { makeUniversalApp } from '@electron/universal';

type MakeUniversalOpts = Parameters<typeof makeUniversalApp>[0]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

note: this leverages Parameters in TS to get the args for makeUniversalApp since @electron/universal doesn't expose them.

* app with the target architecture of "universal". Unused otherwise, providing a value does not imply
* a universal app is built.
*/
osxUniversal?: OsxUniversalOptions;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

note: not exposed via CLI

@MarshallOfSound MarshallOfSound merged commit c6849c2 into main Apr 19, 2022
@MarshallOfSound MarshallOfSound deleted the universal branch April 19, 2022 17:18
@electron electron deleted a comment Jun 16, 2022
@pushkin- pushkin- mentioned this pull request Jul 6, 2023
3 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants