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: vendor information in releaseInfo #7373

Conversation

indutny-signal
Copy link
Contributor

We've been running a version of this patch internally for awhile and decided that it is time to submit it as a Pull Request.

The idea of this change is to allow to pass a custom vendor object down to the .yml file. This object might have some custom properties on it like requireManualUpdate or minOSVersion that the vendor's updater could be checking when deciding whether to update to this release or not.

I understand that this will be ignored by the auto-updater bundled in electron-builder, but at least in our case we are running our own updater and we really find this additional information handy.

@changeset-bot
Copy link

changeset-bot bot commented Jan 13, 2023

🦋 Changeset detected

Latest commit: 20cee51

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 8 packages
Name Type
app-builder-lib Minor
dmg-builder Minor
electron-builder-squirrel-windows Minor
electron-builder Minor
electron-forge-maker-appimage Minor
electron-forge-maker-nsis-web Minor
electron-forge-maker-nsis Minor
electron-forge-maker-snap Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@netlify
Copy link

netlify bot commented Jan 13, 2023

Deploy Preview for car-park-attendant-cleat-11576 ready!

Name Link
🔨 Latest commit 20cee51
🔍 Latest deploy log https://app.netlify.com/sites/car-park-attendant-cleat-11576/deploys/63c6fb22065cd40008d77a4f
😎 Deploy Preview https://deploy-preview-7373--car-park-attendant-cleat-11576.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

@indutny-signal
Copy link
Contributor Author

I actually have a bunch of TS errors when I run pnpm generate-all (even on master branch). Not sure how to proceed with this:

> typescript-json-schema packages/app-builder-lib/tsconfig-scheme.json Configuration --out packages/app-builder-lib/scheme.json --noExtraProps --useTypeOfKeyword --strictNullChecks --required && node ./scripts/fix-schema.js

/Users/indutny/Code/electron-userland/electron-builder/packages/app-builder-lib/src/publish/BitbucketPublisher.ts (52,28): Property 'timeout' does not exist on type 'BitbucketOptions'.
/Users/indutny/Code/electron-userland/electron-builder/packages/app-builder-lib/src/publish/BitbucketPublisher.ts (63,26): Property 'timeout' does not exist on type 'BitbucketOptions'.
/Users/indutny/Code/electron-userland/electron-builder/packages/app-builder-lib/src/publish/KeygenPublisher.ts (142,26): Property 'timeout' does not exist on type 'KeygenOptions'.
/Users/indutny/Code/electron-userland/electron-builder/packages/app-builder-lib/src/publish/KeygenPublisher.ts (158,26): Property 'timeout' does not exist on type 'KeygenOptions'.
/Users/indutny/Code/electron-userland/electron-builder/packages/app-builder-lib/src/publish/KeygenPublisher.ts (216,26): Property 'timeout' does not exist on type 'KeygenOptions'.
/Users/indutny/Code/electron-userland/electron-builder/packages/app-builder-lib/src/publish/KeygenPublisher.ts (231,26): Property 'timeout' does not exist on type 'KeygenOptions'.
/Users/indutny/Code/electron-userland/electron-builder/packages/app-builder-lib/src/publish/KeygenPublisher.ts (264,26): Property 'timeout' does not exist on type 'KeygenOptions'.
/Users/indutny/Code/electron-userland/electron-builder/packages/app-builder-lib/src/publish/PublishManager.ts (167,23): Property 'timeout' does not exist on type 'PublishConfiguration'.
/Users/indutny/Code/electron-userland/electron-builder/packages/app-builder-lib/src/publish/PublishManager.ts (168,13): Property 'timeout' does not exist on type 'UploadTask'.
/Users/indutny/Code/electron-userland/electron-builder/packages/app-builder-lib/src/publish/PublishManager.ts (168,37): Property 'timeout' does not exist on type 'PublishConfiguration'.
/Users/indutny/Code/electron-userland/electron-builder/packages/app-builder-lib/src/targets/FpmTarget.ts (199,70): Argument of type 'string | undefined' is not assignable to parameter of type 'string'.
  Type 'undefined' is not assignable to type 'string'.
/Users/indutny/Code/electron-userland/electron-builder/packages/app-builder-lib/src/targets/FpmTarget.ts (205,9): Object is possibly 'undefined'.
/Users/indutny/Code/electron-userland/electron-builder/packages/app-builder-lib/src/targets/FpmTarget.ts (209,41): Type 'string[] | undefined' must have a '[Symbol.iterator]()' method that returns an iterator.
/Users/indutny/Code/electron-userland/electron-builder/packages/app-builder-lib/src/winPackager.ts (300,119): Argument of type 'string | undefined' is not assignable to parameter of type 'string'.
  Type 'undefined' is not assignable to type 'string'.
/Users/indutny/Code/electron-userland/electron-builder/node_modules/.pnpm/typescript-json-schema@0.51.0/node_modules/typescript-json-schema/dist/typescript-json-schema.js:1292
                throw new Error("No output definition. Probably caused by errors prior to this?");

@mmaietta
Copy link
Collaborator

That's weird, it just worked perfectly fine for me with pnpm compile && pnpm generate-all on your PR branch. If you're unable to get it working, I can get this merged and then push another PR with schema/doc updates

@indutny-signal
Copy link
Contributor Author

I'd appreciate if you could do it. I'll try to figure it out on my end.

@mmaietta mmaietta merged commit 9700c75 into electron-userland:master Jan 23, 2023
@github-actions github-actions bot mentioned this pull request Mar 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants