Commit Graph

120 Commits

Author SHA1 Message Date
Michel Weststrate
7e50c0466a Move app/src (mostly) to flipper-ui-core/src
Summary:
This diff moves all UI code from app/src to app/flipper-ui-core. That is now slightly too much (e.g. node deps are not removed yet), but from here it should be easier to move things out again, as I don't want this diff to be open for too long to avoid too much merge conflicts.

* But at least flipper-ui-core is Electron free :)
* Killed all cross module imports as well, as they where now even more in the way
* Some unit test needed some changes, most not too big (but emotion hashes got renumbered in the snapshots, feel free to ignore that)
* Found some files that were actually meaningless (tsconfig in plugins, WatchTools files, that start generating compile errors, removed those

Follow up work:
* make flipper-ui-core configurable, and wire up flipper-server-core in Electron instead of here
* remove node deps (aigoncharov)
* figure out correct place to load GKs, plugins, make intern requests etc., and move to the correct module
* clean up deps

Reviewed By: aigoncharov

Differential Revision: D32427722

fbshipit-source-id: 14fe92e1ceb15b9dcf7bece367c8ab92df927a70
2021-11-16 05:29:21 -08:00
Michel Weststrate
2e7015388c Remove remaining Electron imports from product code: paths & env
Summary:
This diff removes most remaining Electron imports, by storing env and path constants on the RenderHost. As nice side effect those paths are all cached now as well.

To make sure RenderHost is initialised before Flipper itself, forced loading Flipper through a require. Otherwise the setup is super sensitive to circular import statements, since a lot of module initialisation code depends on those paths / env vars.

Reviewed By: nikoant

Differential Revision: D31992230

fbshipit-source-id: 91beb430902272aaf4b051b35cdf12d2fc993347
2021-11-03 07:01:21 -07:00
Pascal Hartig
2525a5efd4 Fix Flipper lints #9
Summary:
This introduces a few more lints in fact because I renamed the icon functions
to make clear that they use sync methods under the hood.

Reviewed By: timur-valiev

Differential Revision: D31964701

fbshipit-source-id: d0beb58b5b301f5428fdbfe8c65784df0d86eaad
2021-10-28 05:47:40 -07:00
Pascal Hartig
f8117240af Fix async filtering (#3008)
Summary:
I relied too much on the types which in this case don't help at all.
Filtering on a promise will just automatically get all values to pass.

Pull Request resolved: https://github.com/facebook/flipper/pull/3008

Test Plan: `yarn build --mac` works again on the GH checkout.

Reviewed By: mweststrate

Differential Revision: D31991576

Pulled By: passy

fbshipit-source-id: f632d29ddfc09b7130b68b4b17264fd30e1969ce
2021-10-28 05:36:52 -07:00
Michel Weststrate
75b5783fd0 Clean up QPL integration
Summary:
Removed the Flipper QPL integration, see:
https://fb.workplace.com/groups/flippersupport/permalink/1200183003795689/

It complicates our build setup significantly, without actually being used anywhere for the past year. Apparently it doesn't solve a gap compared to the scuba logging we have already in place.

Reviewed By: passy

Differential Revision: D30911573

fbshipit-source-id: 836e2aba0c92c0eed9fed0dfb12bd8bdcb8c7d71
2021-09-14 02:55:01 -07:00
Pascal Hartig
50f19ed3a0 Fix Flipper lints #17
Summary: Mostly disabling warnings for scripts which are fine to use `console.error` directly.

Reviewed By: timur-valiev

Differential Revision: D30812956

fbshipit-source-id: 7fdc5bdf08f72d0d849ece6a4194d6a115d693f0
2021-09-13 02:32:07 -07:00
Michel Weststrate
c3b2fe836d Fix issue where Flipper start starved
Summary: `yarn start` basically starves if watchman is still scanning the system, until that is completed (which took 40 minutes for me last time). Added a timeout of 1 minute, to signal that you can better to some dishes, instead of trying to hunt a bug that looks like an exception has been eaten somewhere (guess what I did..)

Reviewed By: timur-valiev

Differential Revision: D30806512

fbshipit-source-id: a2ebc3672d82f3388fc7b00f41c7e9c4f37794b3
2021-09-08 09:59:38 -07:00
Michel Weststrate
a78b6124d7 Add option to jest to run tests only locally, or on linux (#2609)
Summary:
Pull Request resolved: https://github.com/facebook/flipper/pull/2609

Make it possible to mark some tests to run on non-CI, or unix only

Reviewed By: nikoant

Differential Revision: D29813506

fbshipit-source-id: 140f8a4eaed5af3282ab9d139b46a52818be0934
2021-07-21 05:43:11 -07:00
Pascal Hartig
0e1f8e45ec Refactor out strip source map fn
Summary: Remove the duplicate function and centralise it as nikoant suggested.

Reviewed By: fabiomassimo

Differential Revision: D29548480

fbshipit-source-id: 3e931cc88198415017c557c6b7c81cb35c3f22c9
2021-07-05 06:37:09 -07:00
Pascal Hartig
04616ad647 Allow saving source maps during build
Summary: This makes it possible to save source maps to a separate folder so we can upload them from CI.

Reviewed By: nikoant

Differential Revision: D29521599

fbshipit-source-id: a137659092b7648858b97ecf5b5c60c88889517a
2021-07-05 06:05:43 -07:00
Anton Nikolaev
9fc85730ba Show plugin documentation in Flipper
Reviewed By: passy

Differential Revision: D29392524

fbshipit-source-id: 675de1fc070b1b8b22d0b27721c16dbd6f7076ef
2021-06-29 13:02:05 -07:00
Pascal Hartig
8df81d2dc0 Generate source maps for releases
Summary:
Allows for optional generation of source maps while building plugins.

Caveat: This will leave a broken `//# sourceMappingURL` comment at the bottom. If you set it to `null`, as the documentation suggests, you will instead get an inlined source map in addition to the written one.

Reviewed By: nikoant

Differential Revision: D29265385

fbshipit-source-id: 1e21e49d2516ecc5909b086e7797736b298b86ab
2021-06-21 11:11:38 -07:00
Michel Weststrate
db3d0486e7 Make sure all tests run in same TimeZone
Summary:
Not being able to have timestamps in Jest snapshots, as they would differ across machines required jumping through a lot of hoops.

Run this into once again more by a test suite that didn't trigger on CI, but failed for me locally.

With this fix everyone can happily commit time based snapshots and they will always be assumed to be running in UTC :)

Reviewed By: nikoant

Differential Revision: D29025759

fbshipit-source-id: 426d1b065afdd4a2ed75b47203b13fff0ece1272
2021-06-10 13:00:49 -07:00
Pascal Hartig
f18a00d451 Ignore naked console.error in build script
Summary: This only matters in Flipper proper.

Reviewed By: cekkaewnumchai

Differential Revision: D28964466

fbshipit-source-id: 6fae980cb091900c9b8325f443a2a6a9e81bbfe6
2021-06-10 05:22:28 -07:00
Pascal Hartig
6d1cecdeee Retry icon download
Summary:
In public CI (only?), asset downloads sometimes fail with a spurious 404.
We already have retrying in place, but it will obviously not do that on a 500.

Reviewed By: nikoant

Differential Revision: D28744817

fbshipit-source-id: b6a185d8e9db45e02c6427233a0171b00c552751
2021-05-27 06:26:48 -07:00
Anton Nikolaev
8d508c8634 Build script updated to allow specifying directory with default plugins
Summary: This change allows passing a directory containing plugin packages to include them into Flipper distributive. This is used by release command on Sandcastle (see D28626715).

Reviewed By: passy

Differential Revision: D28628425

fbshipit-source-id: 9c5d7527721f99b43991bace0b5e2f3a4ede0d13
2021-05-25 01:41:57 -07:00
Anton Nikolaev
d57c4d687c Fix build-plugin script
Summary: This diff fixes "build-plugin" script which is failing for fb-internal plugins, because "fb/package.json" not exist. Because of that release of "fb/mobilebuilds" plugin failed recently: https://www.internalfb.com/intern/sandcastle/job/13510799309874638.

Reviewed By: passy

Differential Revision: D28624924

fbshipit-source-id: e00da98cfef992f5d49045afc9d404764a0d13ac
2021-05-24 02:46:42 -07:00
Anton Nikolaev
5ae104cc59 Merge plugin package.json from public and fb-internal parts
Summary: Allow splitting package.json to public one and fb-internal one located in "fb/package.json". When plugin is packaged, fields in package.json are overwritten by fields from "fb/package.json" if they exist. This give us a way to specify additional metadata which only make sense internally (e.g. oncall and internal links to docs and support).

Reviewed By: mweststrate

Differential Revision: D28542101

fbshipit-source-id: c0167461897a994e5731aaf0fe625de052eda864
2021-05-21 07:15:28 -07:00
Anton Nikolaev
a4eb2a56d6 Option for "yarn start" and "yarn build" scripts to pre-install default plugin packages instead of bundling them
Summary:
Sorry for long diff! I can try to split it if necessary, but many changes here are 1-1 replacements / renames.

**Preambule**
Currently we bundle default plugins into the Flipper main bundle. This helps us to reduce bundle size, because of plugin dependencies re-use. E.g. if multiple plugins use "lodash" when they are bundled together, only one copy of "lodash" added. When they are bundled separately, the same dependency might be added to each of them. However as we're not going to include most of plugins into Flipper distributive anymore and going to rely on Marketplace instead, this bundling doesn't provide significant size benefits anymore. In addition to that, bundling makes it impossible to differentiate whether thrown errors are originated from Flipper core or one of its plugins.

Why don't we remove plugin bundling at all? Because for "dev mode" it actually quite useful. It makes dev build start much faster and also enables using of Fast Refresh for plugin development (fast refresh won't work for plugins loaded from disk).

**Changes**
This diff introduces new option "no-bundled-plugins" for "yarn start" and "yarn build" commands. For now, by default, we will continue bundling default plugins into the Flipper main bundle, but if this option provided then we will build each default plugin separately and include their packages into the Flipper distributive as "pre-installed" to be able to load them from disk even without access to Marketplace.

For "yarn start", we're adding symlinks to plugin folders in "static/defaultPlugins" and then they are loaded by Flipper. For "yarn build" we are dereferencing these symlinks to include physical files of plugins into folder "defaultPlugins" of the produced distributive. Folder "defaultPlugins" is excluded from asar, because loading of plugins from asar archive might introduce some unexpected issues depending on their implementation.

Reviewed By: mweststrate

Differential Revision: D28431838

fbshipit-source-id: f7757e9f5ba9183ed918d70252de3ce0e823177d
2021-05-18 08:08:30 -07:00
Anton Nikolaev
b5d8f6c63d Output unpacked plugin dir in addition to tar from "build-plugin" command
Summary: "plugin-build" command will produce dir with unpacked plugin sources in addition to tar package. This is required because for publishing to Marketplace we need to retrieve few files from the output package, like "readme.md" and "package.json" and it's better to have it already unpacked rather than pack and then unpack to get these files.

Reviewed By: passy

Differential Revision: D28409930

fbshipit-source-id: 51c8eeb848a72850a2f126eb91a563d52851ed41
2021-05-13 05:32:07 -07:00
Anton Nikolaev
ef091e7a07 Allow specifying min required Flipper version on "build-plugin" command call
Summary: Added an arg for "build-plugin" command to easily set min required flipper version when plugin is packaged. Before that we only saved engine version in Marketplace metadata, but it's better to save it into the package as well, so we can check compatibility for installed packages even when we have no Marketplace metadata for them.

Reviewed By: passy

Differential Revision: D28350276

fbshipit-source-id: 916d891540263a1f99c1f6d2033eb13e1c36d78f
2021-05-12 07:49:13 -07:00
Anton Nikolaev
2b41fba704 Change Flipper version retrieving
Summary:
Changed retrieving of Flipper version. Now it will be always retrieved from package.json. Before this change we used "remote.app.getVersion()" API which instead returned electron version for dev builds, e.g. "11.2.3". This is not convenient, because we now use Flipper version to check plugin compatibility and unrelated Electron version here makes things more complicated. After this change, if version is not properly bumped then "0.0.0" will be used: 1) when running using "yarn start", 2) when local building with "yarn build --mac" without setting new version, 3) when running tests "yarn test".

In addition to that I added a new command-line argument and env var which allow overriding version number for Flipper. This is useful for testing plugin updates, because compatibility between plugins and Flipper is checked by comparing Flipper version with the min version set in the plugin metadata.

Reviewed By: passy

Differential Revision: D28287354

fbshipit-source-id: 2f9482080e3612b95a24300050d98150c6db6cb7
2021-05-12 07:49:13 -07:00
dependabot[bot]
674f71a426 Bump prettier from 2.2.1 to 2.3.0 in /desktop (#2300)
Summary:
Bumps [prettier](https://github.com/prettier/prettier) from 2.2.1 to 2.3.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a href="https://github.com/prettier/prettier/releases">prettier's releases</a>.</em></p>
<blockquote>
<h2>2.3.0</h2>
<p><a href="https://github.com/prettier/prettier/compare/2.2.1...2.3.0">diff</a></p>
<p>{emoji:1f517} <a href="https://prettier.io/blog/2021/05/09/2.3.0.html">Release Notes</a></p>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a href="https://github.com/prettier/prettier/blob/main/CHANGELOG.md">prettier's changelog</a>.</em></p>
<blockquote>
<h1>2.3.0</h1>
<p><a href="https://github.com/prettier/prettier/compare/2.2.1...2.3.0">diff</a></p>
<p>{emoji:1f517} <a href="https://prettier.io/blog/2021/05/09/2.3.0.html">Release Notes</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a href="2afc3b9ae6"><code>2afc3b9</code></a> Release 2.3.0</li>
<li><a href="7cfa9aa89b"><code>7cfa9aa</code></a> Fix pre-commit hook setup command (<a href="https://github-redirect.dependabot.com/prettier/prettier/issues/10710">#10710</a>)</li>
<li><a href="c8c02b4753"><code>c8c02b4</code></a> Build(deps-dev): Bump concurrently from 6.0.2 to 6.1.0 in /website (<a href="https://github-redirect.dependabot.com/prettier/prettier/issues/10834">#10834</a>)</li>
<li><a href="6506e0f50e"><code>6506e0f</code></a> Build(deps-dev): Bump webpack-cli from 4.6.0 to 4.7.0 in /website (<a href="https://github-redirect.dependabot.com/prettier/prettier/issues/10836">#10836</a>)</li>
<li><a href="69fae9c291"><code>69fae9c</code></a> Build(deps): Bump flow-parser from 0.150.0 to 0.150.1 (<a href="https://github-redirect.dependabot.com/prettier/prettier/issues/10839">#10839</a>)</li>
<li><a href="164a6e2351"><code>164a6e2</code></a> Switch CLI to async (<a href="https://github-redirect.dependabot.com/prettier/prettier/issues/10804">#10804</a>)</li>
<li><a href="d3e7e2f634"><code>d3e7e2f</code></a> Build(deps): Bump codecov/codecov-action from v1.4.1 to v1.5.0 (<a href="https://github-redirect.dependabot.com/prettier/prettier/issues/10833">#10833</a>)</li>
<li><a href="9e09845da0"><code>9e09845</code></a> Build(deps): Bump <code>@​angular/compiler</code> from 11.2.12 to 11.2.13 (<a href="https://github-redirect.dependabot.com/prettier/prettier/issues/10838">#10838</a>)</li>
<li><a href="1bfab3d045"><code>1bfab3d</code></a> Build(deps-dev): Bump eslint from 7.25.0 to 7.26.0 (<a href="https://github-redirect.dependabot.com/prettier/prettier/issues/10840">#10840</a>)</li>
<li><a href="387fce4ed8"><code>387fce4</code></a> Minor formatting tweaks (<a href="https://github-redirect.dependabot.com/prettier/prettier/issues/10807">#10807</a>)</li>
<li>Additional commits viewable in <a href="https://github.com/prettier/prettier/compare/2.2.1...2.3.0">compare view</a></li>
</ul>
</details>
<br />

[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=prettier&package-manager=npm_and_yarn&previous-version=2.2.1&new-version=2.3.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

 ---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `dependabot rebase` will rebase this PR
- `dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `dependabot merge` will merge this PR after your CI passes on it
- `dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `dependabot cancel merge` will cancel a previously requested merge and block automerging
- `dependabot reopen` will reopen this PR if it is closed
- `dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- `dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- `dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- `dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

</details>

Pull Request resolved: https://github.com/facebook/flipper/pull/2300

Reviewed By: passy

Differential Revision: D28323849

Pulled By: cekkaewnumchai

fbshipit-source-id: 1842877ccc9a9587af7f0d9ff9432c2075c8ee22
2021-05-11 05:51:56 -07:00
Anton Nikolaev
763eda8f6b Fix re-loading of source maps with "-fast-refresh" flag enabled
Summary: Fixed loading of source maps when dev server is running with --fast-refresh flag set. Looks like it was broken after last metro upgrade because it changed the way how module paths are passed to dev server. We also had a hack to workaround bug when requested module paths were malformed, but it looks this hack is not needed now, so I deleted it as well.

Reviewed By: passy

Differential Revision: D28120080

fbshipit-source-id: 03a39c9840da8f4c8c72be6189c0b71c62fac7f0
2021-04-30 09:38:15 -07:00
Pascal Hartig
f1b8aeffd7 Disable mangling and compression
Summary:
This is not doing much in terms of size. We're talking 780 bytes after
PACK compression but we're losing a lot of information in our errors
(before have symbolication).

We may reenable this at some point but I think it might be safe to leave it to this.

Reviewed By: nikoant

Differential Revision: D27887636

fbshipit-source-id: 15affeac588db667914320cbd098f7041b8b9c09
2021-04-20 11:34:43 -07:00
Michel Weststrate
e29222fba7 Update and patch loading React DevTools
Summary:
When trying to run some React component performance profiles, the updates registered made absolutely no sense (components rerendering without any parent or other cause causing them to render etc). That turned out to be caused by having an outdated version of the React devTools in Flipper.

Sadly the newer version of the React DevTools didn't work with our current Electron version anymore. Some horrible hacking is needed to work around that.

To help with updating the tools in the future (they are by default cached forever on the local machine), I've introduced the `FLIPPER_UPDATE_DEV_TOOLS` variable.

The plugin loading work around is inspired by https://github.com/electron/electron/issues/23662#issuecomment-787420799

Reviewed By: passy

Differential Revision: D27685981

fbshipit-source-id: c35e49aff9b2457b63122eeee0d5c042ddd3b08b
2021-04-15 07:48:33 -07:00
Anton Nikolaev
dc7226b7dc Script for plugin type-checking (#2172)
Summary:
Pull Request resolved: https://github.com/facebook/flipper/pull/2172

New script which runs "tsc" for all plugins, receives list of errors and then checks which plugins are affected. It works for shared libs too, e.g. if there is an error in a shared library, then all plugins dependant on it will be counted as affected. For convenience, script saves list of errors affecting each plugin to "tsc-errors.log" in plugin folder.

This script will be used for automatic type-checking plugins against current "stable" and "insiders" versions of Flipper.

An alternative to this implementation would be to simply run "tsc" for each plugin individually, but such implementation takes a lot of time (5+ sec per plugin) and so cannot be effectively used on diffs.

Reviewed By: mweststrate

Differential Revision: D27499765

fbshipit-source-id: fcbbfc94a13e6c7c5beff0c889a929f84c41b2dd
2021-04-09 05:22:01 -07:00
Anton Nikolaev
b45b5f854a Move layout plugin sidebar extensions to the plugin package
Summary: Moved layout plugin sidebar extensions to the plugin package.

Reviewed By: passy

Differential Revision: D27036489

fbshipit-source-id: 5b3406e5c50ba61709d925a3c0cb07a6fd7552db
2021-04-09 05:22:00 -07:00
Anton Nikolaev
4997cb9847 Show file path and position when babel transformation failed
Summary: Currently when babel transformation is failed, only stack is shown. It's better to log the whole error object because it also contains path and line number of the code failing to transpile.

Reviewed By: passy

Differential Revision: D27034942

fbshipit-source-id: 76e03871c924489e2698a26622e6bc6fdd305560
2021-04-09 05:22:00 -07:00
Anton Nikolaev
b3274a8450 Plugin folders re-structuring
Summary:
Here I'm changing plugin repository structure to allow re-using of shared packages between both public and fb-internal plugins, and to ensure that public plugins has their own yarn.lock as this will be required to implement reproducible jobs checking plugin compatibility with released flipper versions.

Please note that there are a lot of moved files in this diff, make sure to click "Expand all" to see all that actually changed (there are not much of them actually).

New proposed structure for plugin packages:
```
- root
- node_modules - modules included into Flipper: flipper, flipper-plugin, react, antd, emotion
-- plugins
 --- node_modules - modules used by both public and fb-internal plugins (shared libs will be linked here, see D27034936)
 --- public
---- node_modules - modules used by public plugins
---- pluginA
----- node_modules - modules used by plugin A exclusively
---- pluginB
----- node_modules - modules used by plugin B exclusively
 --- fb
---- node_modules - modules used by fb-internal plugins
---- pluginC
----- node_modules - modules used by plugin C exclusively
---- pluginD
----- node_modules - modules used by plugin D exclusively
```
I've moved all public plugins under dir "plugins/public" and excluded them from root yarn workspaces. Instead, they will have their own yarn workspaces config and yarn.lock and they will use flipper modules as peer dependencies.

Reviewed By: mweststrate

Differential Revision: D27034108

fbshipit-source-id: c2310e3c5bfe7526033f51b46c0ae40199fd7586
2021-04-09 05:22:00 -07:00
dependabot[bot]
12717e1b9d Bump app-builder-lib from 22.9.1 to 22.10.5 in /desktop (#2072)
Summary:
allow-large-files
Bumps [app-builder-lib](https://github.com/electron-userland/electron-builder) from 22.9.1 to 22.10.5.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a href="https://github.com/electron-userland/electron-builder/releases">app-builder-lib's releases</a>.</em></p>
<blockquote>
<h2>22.10.5</h2>
<p>We have a new maintainer — welcome Mike Maietta (<a href="https://github.com/mmaietta"><code>@​mmaietta</code></a>)!</p>
<p><strong>electron-updater</strong>  4.3.8 contains fix for <a href="https://github.com/electron-userland/electron-builder/issues/5595">#5595</a>. This version is a pre-release.</p>
<h3>Bug Fixes</h3>
<ul>
<li>Look for the Amazon cred header to remove auth header (<a href="https://github.com/electron-userland/electron-builder/issues/5594">#5594</a>) (<a href="46a8840bb4">46a8840</a>)</li>
<li><strong>mac:</strong> fix &quot;Contents/Info.plist&quot; don't have identical SHAs when creating a universal build (<a href="https://github.com/electron-userland/electron-builder/issues/5550">#5550</a>) (<a href="0ba839b72b">0ba839b</a>)</li>
<li>updating nsis script to properly identify arm64 vs x64 vs ia32 package files within universal installers. (<a href="https://github.com/electron-userland/electron-builder/issues/5558">#5558</a>) (<a href="60f7fe367c">60f7fe3</a>)</li>
<li><strong>mac:</strong> Allow arm64 macs to update to x64 version if no arm64 version available (<a href="https://github.com/electron-userland/electron-builder/issues/5524">#5524</a>) (<a href="dc5c2f8e77">dc5c2f8</a>)</li>
<li><strong>mac:</strong> Pass platformName and options in doPack (<a href="https://github.com/electron-userland/electron-builder/issues/5511">#5511</a>) (<a href="f78e3f48d7">f78e3f4</a>)</li>
<li><strong>mac:</strong> Workaround for hdiutil randomly failing (<a href="https://github.com/electron-userland/electron-builder/issues/5431">#5431</a>) (<a href="https://github.com/electron-userland/electron-builder/issues/5464">#5464</a>) (<a href="53270cfe4e">53270cf</a>)</li>
<li>binary detection signing (<a href="https://github.com/electron-userland/electron-builder/issues/5493">#5493</a>) (<a href="a6e86b5930">a6e86b5</a>), closes <a href="https://github.com/electron-userland/electron-builder/issues/5465">#5465</a></li>
<li>ci-tests (<a href="https://github.com/electron-userland/electron-builder/issues/5523">#5523</a>) (<a href="ced6e50b93">ced6e50</a>)</li>
</ul>
<h3>Features</h3>
<ul>
<li><strong>electron-updater:</strong> follow <code>autoInstallOnAppQuit = false</code> on macOS (<a href="https://github.com/electron-userland/electron-builder/issues/5271">#5271</a>) (<a href="1643d56960">1643d56</a>)</li>
<li>add support for executableName to non-Linux Platforms (<a href="https://github.com/electron-userland/electron-builder/issues/5409">#5409</a>) (<a href="106b68010f">106b680</a>)</li>
<li>Custom electronDist callback (<a href="https://github.com/electron-userland/electron-builder/issues/5527">#5527</a>) (<a href="4f4e018771">4f4e018</a>)</li>
<li>macOS default architecture (<a href="https://github.com/electron-userland/electron-builder/issues/5495">#5495</a>) (<a href="https://github.com/electron-userland/electron-builder/issues/5504">#5504</a>) (<a href="5203d7eb15">5203d7e</a>)</li>
</ul>
<h2>22.10.4</h2>
<h3>Bug Fixes</h3>
<ul>
<li>CI unit tests (<a href="https://github.com/electron-userland/electron-builder/issues/5489">#5489</a>) (<a href="637334ddba">637334d</a>)</li>
</ul>
<h3>Features</h3>
<ul>
<li>Apple Silicon Universal Support (<a href="https://github.com/electron-userland/electron-builder/issues/5481">#5481</a>) (<a href="ca20151c34">ca20151</a>)</li>
<li><strong>mas:</strong> Apple Silicon support (<a href="https://github.com/electron-userland/electron-builder/issues/5484">#5484</a>) (<a href="6b7d30555d">6b7d305</a>)</li>
</ul>
<h3>Reverts</h3>
<ul>
<li>Revert &quot;fix: codesign all binary-like files (<a href="https://github.com/electron-userland/electron-builder/issues/5322">#5322</a>)&quot; (<a href="https://github.com/electron-userland/electron-builder/issues/5488">#5488</a>) (<a href="026227888f">0262278</a>), closes <a href="https://github.com/electron-userland/electron-builder/issues/5322">#5322</a> <a href="https://github.com/electron-userland/electron-builder/issues/5488">#5488</a></li>
</ul>
<h2>22.10.3</h2>
<h3>Bug Fixes</h3>
<ul>
<li>signing of playwright (<a href="https://github.com/electron-userland/electron-builder/issues/5451">#5451</a>) (<a href="50750683b1">5075068</a>)</li>
<li><strong>dmg:</strong> new version of mac_alias (<a href="https://github.com/electron-userland/electron-builder/issues/5460">#5460</a>) (<a href="a8acb583bc">a8acb58</a>)</li>
<li>compiler error and test updates (<a href="https://github.com/electron-userland/electron-builder/issues/5449">#5449</a>) (<a href="0dec1b8c19">0dec1b8</a>)</li>
<li><strong>AppImage:</strong> Add default argument --no-sandbox (<a href="https://github.com/electron-userland/electron-builder/issues/4496">#4496</a>) (<a href="ede6d50ddb">ede6d50</a>)</li>
<li><strong>linux:</strong> Linux icon is not set if path is not explicitly defined in config (<a href="https://github.com/electron-userland/electron-builder/issues/5385">#5385</a>) (<a href="9fd950bc04">9fd950b</a>)</li>
<li><strong>nsis:</strong> cs locale typos in messages (<a href="https://github.com/electron-userland/electron-builder/issues/5358">#5358</a>) (<a href="0fb69b5d11">0fb69b5</a>)</li>
<li>codesign all binary-like files (<a href="https://github.com/electron-userland/electron-builder/issues/5322">#5322</a>) (<a href="27ea1b2b9c">27ea1b2</a>)</li>
</ul>

</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a href="79940292bd"><code>7994029</code></a> Cannot read property 'log' of undefined (<a href="https://github.com/electron-userland/electron-builder/issues/5622">#5622</a>)</li>
<li><a href="1643d56960"><code>1643d56</code></a> feat(electron-updater): follow <code>autoInstallOnAppQuit = false</code> on macOS (<a href="https://github.com/electron-userland/electron-builder/issues/5271">#5271</a>)</li>
<li><a href="0360cd1705"><code>0360cd1</code></a> chore(build-utils): remove unreachable useless statement in createMessage (<a href="https://github.com/electron-userland/electron-builder/issues/5">https://github.com/facebook/flipper/issues/5</a>...</li>
<li><a href="c348e318ce"><code>c348e31</code></a> Add &quot;open&quot; guard for AsarUtil to fix concurrent builds (<a href="https://github.com/electron-userland/electron-builder/issues/5567">#5567</a>)</li>
<li><a href="11aa06c701"><code>11aa06c</code></a> Detect CI tag for Bitbucket pipelines</li>
<li><a href="8decc18674"><code>8decc18</code></a> (fix) master branch depCheck + tests (<a href="https://github.com/electron-userland/electron-builder/issues/5630">#5630</a>)</li>
<li><a href="46a8840bb4"><code>46a8840</code></a> fix: Look for the Amazon cred header to remove auth header (<a href="https://github.com/electron-userland/electron-builder/issues/5594">#5594</a>)</li>
<li><a href="0ba839b72b"><code>0ba839b</code></a> fix(mac): fix &quot;Contents/Info.plist&quot; don't have identical SHAs when creating a...</li>
<li><a href="60f7fe367c"><code>60f7fe3</code></a> fix: updating nsis script to properly identify arm64 vs x64 vs ia32 package f...</li>
<li><a href="5de0db981d"><code>5de0db9</code></a> chore: lint</li>
<li>Additional commits viewable in <a href="https://github.com/electron-userland/electron-builder/compare/v22.9.1...v22.10.5">compare view</a></li>
</ul>
</details>
<br />

[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=app-builder-lib&package-manager=npm_and_yarn&previous-version=22.9.1&new-version=22.10.5)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

 ---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `dependabot rebase` will rebase this PR
- `dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `dependabot merge` will merge this PR after your CI passes on it
- `dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `dependabot cancel merge` will cancel a previously requested merge and block automerging
- `dependabot reopen` will reopen this PR if it is closed
- `dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- `dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- `dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- `dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

</details>

Pull Request resolved: https://github.com/facebook/flipper/pull/2072

Reviewed By: passy

Differential Revision: D27230105

Pulled By: priteshrnandgaonkar

fbshipit-source-id: e53e942319a15d982797f7ce3af128a8b25b357f
2021-03-23 08:46:58 -07:00
Anton Nikolaev
f468f0e07d Produce tsc typings for "flipper" package
Summary: This diffs refactors tsc projects structure and structure of our custom typings to allow producing typescript typings for "flipper" package. In next diffs I'm going to use the produced typings to check compatibility of plugins with certain versions of Flipper, e.g. to check whether plugin is compatible with current "stable" and "insiders" version.

Reviewed By: passy

Differential Revision: D26997158

fbshipit-source-id: a0416c7139bf08ec9d175730da4c4c2a8768eeb7
2021-03-17 14:03:38 -07:00
Anton Nikolaev
f508a35ff9 Fix patch release versioning for open-source version
Summary: Patch was always set to "0" for open source releases even if it is set to "1" in package.json

Reviewed By: passy

Differential Revision: D26975947

fbshipit-source-id: b3f127c9746797fbb5a79dfcd9bd52210c3a7df8
2021-03-11 04:32:21 -08:00
Anton Nikolaev
58b2daea02 Bundle all plugins script
Summary: New script which bundles all plugins. It is faster to bundle them all in one script rather than call "build-plugin" for each of them. The new script will be used in CI to catch regressions when some plugins cannot be bundled into standalone packages.

Reviewed By: passy

Differential Revision: D26918103

fbshipit-source-id: dbc5c4cd706e8d585718a198dbd7ae9ffd988e28
2021-03-10 08:09:02 -08:00
Anton Nikolaev
c065760d15 Stable babel transformation cache key
Summary:
This diff makes babel transformation cache key stable. With the previous approach it was changed on each CI build so it was not possible to persist cache between builds. Now it is computed from the transformation package content after each build. Because of that it is equal for every CI build while Babel transformations unchanged and so we could use same cache on different Sandcastle agents.

In addition to that, it makes it possible to specify directory for Metro cache so we can save/restore it in CI builds.

Reviewed By: mweststrate

Differential Revision: D26877989

fbshipit-source-id: 7cb04a177f86e61986585e5a74d9c7396ddddc18
2021-03-10 08:09:02 -08:00
Anton Nikolaev
baeb8ba5be Performance improvements for "build-plugin" task
Summary:
Few improvements for "build-plugin" task which together with Sandcastle command changes (D26872427) helps to build all plugins in CI ~30% faster if most of them has not changed (which is usually the case):
1) compute package checksum in the same script to not call additional yarn scripts for each plugin
2) avoid packaging plugin if it's checksum has not changed since last release

Reviewed By: mweststrate

Differential Revision: D26872253

fbshipit-source-id: 968102d32a1550ea7503f1169f0ef2863296383f
2021-03-10 08:09:02 -08:00
Anton Nikolaev
fa3ff83595 Rename star/unstar actions to enable/disable/switch
Summary:
Renamed actions "star" and "unstar" everywhere to "enable", "disable" and "switch". The logic behind original "star" action changed significantly, so this rename just makes everything much clearer.

Please note that as a part of rename persisted state fields "userStarredPlugins" and "userStarredDevicePlugins" were renamed. I've added a "redux-persist" migration for seamless transition.

Reviewed By: passy

Differential Revision: D26606459

fbshipit-source-id: 83ad475f9b0231194701c40a2cdbda36f02c3d10
2021-02-24 05:30:57 -08:00
Anton Nikolaev
eba9bafb74 Fix running "insiders" dev build
Summary: Fixed passing parameter for running dev build as "insiders" via env var. It was broken before and it was only possible to pass it via command line.

Reviewed By: passy

Differential Revision: D26578901

fbshipit-source-id: a579ac5bb6e5527abbe978318bf0c0398f76f1fe
2021-02-23 05:07:44 -08:00
Anton Nikolaev
4cb40de3f5 Device plugin management (3/n): unbundle less used device plugins from Flipper Insiders builds
Summary: Now as we can install device plugins from Marketplace, I was able to unbundle device plugins which were used quite rarely, but still added ~3 MB to the final Flipper bundle.

Reviewed By: mweststrate

Differential Revision: D26337297

fbshipit-source-id: 23a36cc15ca976a1215440192718d985e1f322fd
2021-02-16 10:50:19 -08:00
Pascal Hartig
aacf5b8565 Hard-code mutable version info for Windows
Summary:
This is quite hacky but avoids having to patch electron-builder directly.

We're intercepting the signing/editing process on Windows and triggering it ourselves while overriding version information that otherwise changes for every release causing cache invalidations to occur. This does *not* change the version display in the app as we're not depending on the PE metadata but on the version in the `package.json`.

Reviewed By: nikoant, mweststrate

Differential Revision: D25973921

fbshipit-source-id: 0fad07f3597fba9927643d24fba12f8750ca54bc
2021-01-21 03:43:17 -08:00
Pascal Hartig
4a8e98733d Simpler win sign exception
Summary:
We're skipping the signing and editing of EXEs on Windows. This is only temporary but I want to have an atomic commit we can go back to. This is to avoid cache eviction due to version numbers being encoded in the binary.

This means you're not getting the logo on the binary and copyright information, etc. We're not actually shipping these right now, so the real-world impact of this is zero.

Reviewed By: mweststrate

Differential Revision: D25973944

fbshipit-source-id: d076919acfaac1f618178294baff3e9122d820bf
2021-01-20 09:14:21 -08:00
Pascal Hartig
f6087cf765 Fix typo
Summary: Per title

Reviewed By: mweststrate

Differential Revision: D25973952

fbshipit-source-id: cf01555d3536da1eef2cd386aa5def424dc3f159
2021-01-20 09:14:21 -08:00
dependabot[bot]
ea4b8b8f8a Bump socket.io from 2.3.0 to 3.1.0 in /desktop (#1845)
Summary:
Bumps [socket.io](https://github.com/socketio/socket.io) from 2.3.0 to 3.1.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a href="https://github.com/socketio/socket.io/releases">socket.io's releases</a>.</em></p>
<blockquote>
<h2>3.1.0</h2>
<p>In order to ease the migration to Socket.IO v3, the v3 server is now able to communicate with v2 clients:</p>
<pre lang="js"><code>const io = require(&quot;socket.io&quot;)({
  allowEIO3: true // false by default
});
</code></pre>
<p>Note: the <code>allowEIO3</code> refers to the version 3 of the Engine.IO protocol which is used in Socket.IO v2</p>
<h3>Features</h3>
<ul>
<li>confirm a weak but matching ETag (<a href="https://github-redirect.dependabot.com/socketio/socket.io/issues/3485">#3485</a>) (<a href="161091dd4c">161091d</a>)</li>
<li><strong>esm:</strong> export the Namespace and Socket class (<a href="https://github-redirect.dependabot.com/socketio/socket.io/issues/3699">#3699</a>) (<a href="233650c222">233650c</a>)</li>
<li>add support for Socket.IO v2 clients (<a href="9925746c8e">9925746</a>)</li>
<li>add room events (<a href="155fa6333a">155fa63</a>)</li>
</ul>
<h3>Bug Fixes</h3>
<ul>
<li>allow integers as event names (<a href="1c220ddbf4">1c220dd</a>)</li>
</ul>
<h4>Links:</h4>
<ul>
<li>Milestone: -</li>
<li>Diff: <a href="https://github.com/socketio/socket.io/compare/3.0.5...3.1.0">https://github.com/socketio/socket.io/compare/3.0.5...3.1.0</a></li>
<li>Client release: <a href="https://github.com/socketio/socket.io-client/releases/tag/3.1.0">3.1.0</a></li>
<li>engine.io version:  <code>~4.1.0</code></li>
<li>ws version: <code>~7.4.2</code></li>
</ul>
<h2>3.0.5</h2>
<h3>Bug Fixes</h3>
<ul>
<li>properly clear timeout on connection failure (<a href="170b739f14">170b739</a>)</li>
</ul>
<h3>Reverts</h3>
<ul>
<li>restore the socket middleware functionality (<a href="bf54327421">bf54327</a>)</li>
</ul>
<h4>Links:</h4>
<ul>
<li>Milestone: -</li>
<li>Diff: <a href="https://github.com/socketio/socket.io/compare/3.0.4...3.0.5">https://github.com/socketio/socket.io/compare/3.0.4...3.0.5</a></li>
<li>Client release: <a href="https://github.com/socketio/socket.io-client/releases/tag/3.0.5">3.0.5</a></li>
<li>engine.io version:  <code>~4.0.6</code></li>
<li>ws version: <code>~7.4.2</code></li>
</ul>

</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a href="https://github.com/socketio/socket.io/blob/master/CHANGELOG.md">socket.io's changelog</a>.</em></p>
<blockquote>
<h1><a href="https://github.com/socketio/socket.io/compare/3.0.5...3.1.0">3.1.0</a> (2021-01-15)</h1>
<h3>Features</h3>
<ul>
<li>confirm a weak but matching ETag (<a href="https://github-redirect.dependabot.com/socketio/socket.io/issues/3485">#3485</a>) (<a href="161091dd4c">161091d</a>)</li>
<li><strong>esm:</strong> export the Namespace and Socket class (<a href="https://github-redirect.dependabot.com/socketio/socket.io/issues/3699">#3699</a>) (<a href="233650c222">233650c</a>)</li>
<li>add support for Socket.IO v2 clients (<a href="9925746c8e">9925746</a>)</li>
<li>add room events (<a href="155fa6333a">155fa63</a>)</li>
</ul>
<h3>Bug Fixes</h3>
<ul>
<li>allow integers as event names (<a href="1c220ddbf4">1c220dd</a>)</li>
</ul>
<h2><a href="https://github.com/socketio/socket.io/compare/3.0.4...3.0.5">3.0.5</a> (2021-01-05)</h2>
<h3>Bug Fixes</h3>
<ul>
<li>properly clear timeout on connection failure (<a href="170b739f14">170b739</a>)</li>
</ul>
<h3>Reverts</h3>
<ul>
<li>restore the socket middleware functionality (<a href="bf54327421">bf54327</a>)</li>
</ul>
<h2><a href="https://github.com/socketio/socket.io/compare/3.0.3...3.0.4">3.0.4</a> (2020-12-07)</h2>
<h2><a href="https://github.com/socketio/socket.io/compare/3.0.2...3.0.3">3.0.3</a> (2020-11-19)</h2>
<h2><a href="https://github.com/socketio/socket.io/compare/3.0.1...3.0.2">3.0.2</a> (2020-11-17)</h2>
<h3>Bug Fixes</h3>
<ul>
<li>merge Engine.IO options (<a href="43705d7a91">43705d7</a>)</li>
</ul>
<h2><a href="https://github.com/socketio/socket.io/compare/3.0.0...3.0.1">3.0.1</a> (2020-11-09)</h2>
<h3>Bug Fixes</h3>
<ul>
<li>export ServerOptions and Namespace types (<a href="https://github-redirect.dependabot.com/socketio/socket.io/issues/3684">#3684</a>) (<a href="f62f180eda">f62f180</a>)</li>
<li><strong>typings:</strong> update the signature of the emit method (<a href="50671d984a">50671d9</a>)</li>
</ul>

</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a href="f05a4a6f82"><code>f05a4a6</code></a> chore(release): 3.1.0</li>
<li><a href="2c883f5d4e"><code>2c883f5</code></a> chore: bump socket.io-adapter version</li>
<li><a href="161091dd4c"><code>161091d</code></a> feat: confirm a weak but matching ETag (<a href="https://github-redirect.dependabot.com/socketio/socket.io/issues/3485">#3485</a>)</li>
<li><a href="d52532b7be"><code>d52532b</code></a> docs: add other client implementations (<a href="https://github-redirect.dependabot.com/socketio/socket.io/issues/3593">#3593</a>)</li>
<li><a href="6b1d7901db"><code>6b1d790</code></a> docs(examples): Improve the chat example with more ES6 features (<a href="https://github-redirect.dependabot.com/socketio/socket.io/issues/3240">#3240</a>)</li>
<li><a href="b55892ae80"><code>b55892a</code></a> docs: add run on repl.it badge to README (<a href="https://github-redirect.dependabot.com/socketio/socket.io/issues/3617">#3617</a>)</li>
<li><a href="233650c222"><code>233650c</code></a> feat(esm): export the Namespace and Socket class (<a href="https://github-redirect.dependabot.com/socketio/socket.io/issues/3699">#3699</a>)</li>
<li><a href="9925746c8e"><code>9925746</code></a> feat: add support for Socket.IO v2 clients</li>
<li><a href="de8dffd252"><code>de8dffd</code></a> refactor: strict type check in if expressions (<a href="https://github-redirect.dependabot.com/socketio/socket.io/issues/3744">#3744</a>)</li>
<li><a href="f8a66fd11a"><code>f8a66fd</code></a> chore(release): 3.0.5</li>
<li>Additional commits viewable in <a href="https://github.com/socketio/socket.io/compare/2.3.0...3.1.0">compare view</a></li>
</ul>
</details>
<br />

[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=socket.io&package-manager=npm_and_yarn&previous-version=2.3.0&new-version=3.1.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

 ---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `dependabot rebase` will rebase this PR
- `dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `dependabot merge` will merge this PR after your CI passes on it
- `dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `dependabot cancel merge` will cancel a previously requested merge and block automerging
- `dependabot reopen` will reopen this PR if it is closed
- `dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- `dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- `dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- `dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

</details>

Pull Request resolved: https://github.com/facebook/flipper/pull/1845

Reviewed By: mweststrate

Differential Revision: D25945568

Pulled By: priteshrnandgaonkar

fbshipit-source-id: 31e4955729b2ce16de88243e9520429f59922d58
2021-01-19 18:45:38 -08:00
Michel Weststrate
9cdb36ec0e Add --public-build option to start an OSS like build of Flipper
Summary: This diff adds the `--public-build` option which allows run a devServer emulating the OSS version of flipper. Technical details are explained in the comments.

Reviewed By: passy, nikoant

Differential Revision: D25944966

fbshipit-source-id: 540855808179582752b8aa646f0b8afd4b78396f
2021-01-18 06:48:03 -08:00
Chaiwat Ekkaewnumchai
8af2d819b0 Remove Trailing Whitespace in Changelog
Summary: In D25584424 (V1), Sandcastle complained about trailing whitespace. This diff removes the adde description if none can be retrieved

Reviewed By: nikoant

Differential Revision: D25608443

fbshipit-source-id: a798bb0c40afaaafd55c90c70177f7c2af79af34
2020-12-17 19:33:40 -08:00
Anton Nikolaev
c14bab3677 Unbundle less popular plugins for Insiders builds
Summary: Unbundle most of plugins from Insiders version of Flipper. Users will need to install them from Marketplace.

Reviewed By: passy

Differential Revision: D25558043

fbshipit-source-id: 648b0d4c83d9096972b5463cdcaa3de23426bdda
2020-12-15 09:31:59 -08:00
Anton Nikolaev
bd01b58566 Sandy-based plugin auto-update UI
Summary:
New UX/UI for plugin auto-updates based on Sandy:
- disabled plugins auto-updated silently without any notifications as there is no active state for them so there is nothing to loose.
- enabled plugins can have some state and user can actually work with them, so we cannot reload them automatically. Instead, we show notification in the top of the plugin container asking user to reload the plugin when she is ready.
- if the auto-updated plugin failed to reload - show error notification.
- for non-sandy we continue using notifications as before.

Reviewed By: mweststrate

Differential Revision: D25530384

fbshipit-source-id: de3d0565ef0b930c9343b9e0ed07a4acb51885be
2020-12-15 09:31:57 -08:00
Anton Nikolaev
5383017299 Separate interfaces for installed, bundled and downloadable plugins
Summary:
I've re-designed interfaces describing plugins as I found that mental overhead working with them became too expensive because of slightly flawed design. However this cascaded changes in many files so you can see how extensively these interfaces used in our codebase.

Before this change we had one interface PluginDetails which described three different entities: 1) plugins installed on the disk 2) plugins bundled into Flipper 3) plugins available on Marketplace. It's hard to use this "general" PluginDetails interface because of this as you always need to think about all three use cases everywhere.

After this change we have 3 separate interfaces: InstalledPluginDetails, BundledPluginDetails and DownloadablePluginDetails and things became much type-safer now.

Reviewed By: mweststrate

Differential Revision: D25530383

fbshipit-source-id: b93593916a980c04e36dc6ffa168797645a0ff9c
2020-12-15 09:31:57 -08:00
Anton Nikolaev
f3e1a48ff3 Plugin Marketplace state refresh and cache
Summary:
Separate dispatcher for periodic refreshing available plugins data from the Marketplace backend and caching it locally.

The plugin auto update downloader subscribes to these state refreshes and automatically schedules plugin update downloads when required.

Reviewed By: passy

Differential Revision: D25360897

fbshipit-source-id: 5b6d95b63ff47b8ae9ad8b12e2480d1fed524ca5
2020-12-15 09:31:54 -08:00
Michel Weststrate
08b5644253 Killed Flipper headless
Reviewed By: nikoant

Differential Revision: D24160480

fbshipit-source-id: 221e60473dddc0a49cea674e210beb6f85b1b03c
2020-12-15 01:46:44 -08:00