studio icon indicating copy to clipboard operation
studio copied to clipboard

Reduce install size by removing .map files from ASAR

Open jhurliman opened this issue 4 years ago • 11 comments

We already upload these files directly to Sentry, they do not need to be in the app installation images as well. Map files take up two thirds of the uncompressed ASAR disk space.

jhurliman avatar Jul 19 '21 19:07 jhurliman

Does this work? I think the rimraf happens too late - the package has already been created.

defunctzombie avatar Jul 19 '21 19:07 defunctzombie

Doesn't this make it harder to use the in-app debugger?

jtbandes avatar Jul 19 '21 19:07 jtbandes

Doesn't this make it harder to use the in-app debugger?

Yea - for production builds. Dunno if I think this is worth the decrease in size for that loss (tho I guess we can always make local builds with the maps). I'd like to know what the decrease in final app size is before we decide on this.

defunctzombie avatar Jul 19 '21 20:07 defunctzombie

Where did we land on this? Maybe not enough benefit for the tradeoff for now?

defunctzombie avatar Oct 08 '21 18:10 defunctzombie

@jhurliman ^

defunctzombie avatar Oct 22 '21 18:10 defunctzombie

This PR has been marked as stale because there has been no activity in the past 3 months. Please add a comment to keep it open.

github-actions[bot] avatar Jan 21 '22 00:01 github-actions[bot]

This PR has been marked as stale because there has been no activity in the past 3 months. Please add a comment to keep it open.

github-actions[bot] avatar Apr 25 '22 00:04 github-actions[bot]

@jtbandes @jhurliman thoughts on pushing this over the finish line? Seems like we don't do a lot of stepping through the code with users and we already upload maps to sentry (as stated in the issue) so maybe its worth the decrease in bundle size to merge this?

defunctzombie avatar May 03 '22 15:05 defunctzombie

I think this is a good idea still, but don't have enough knowledge of the build steps to properly implement it.

jhurliman avatar May 09 '22 16:05 jhurliman

Here's some actual numbers from my Mac OS build:

Item W/ .map files Size No .map files Size
Size of Foxglove Studio Dev.app 526M 423M
Size of app.asar 166M 72M

defunctzombie avatar May 09 '22 17:05 defunctzombie

This PR has been marked as stale because there has been no activity in the past 3 months. Please add a comment to keep it open.

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