Smaller binary size for compact installation #367
-
|
Current binary size is almost 120MB+ easily even with ReleaseSmall profile. Is there any way to make this small? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
|
The size is mostly due to tree-sitter. Flow is a batteries included binary with zero additional files needed after download. 120Mb is actually pretty tiny. Most tree-sitter editors require several GB with the same set of languages installed. The huge advantage of the way flow does it is trivial deployment. All you need is one single file (for your arch at least). You can, just for example, map just the flow binary directly into a docker container and it's installed. In any case, you have a few options to reduce the binary size:
We could release pre-built binaries with no tree-sitter and upx compressed. But no-one has really questioned the binary size up to now. You're the first. Note: packing the full flow binary with upx will cost you ~70ms of time on startup. I prefer to save the 70ms at the const of 100Mb disk. |
Beta Was this translation helpful? Give feedback.
The size is mostly due to tree-sitter. Flow is a batteries included binary with zero additional files needed after download. 120Mb is actually pretty tiny. Most tree-sitter editors require several GB with the same set of languages installed. The huge advantage of the way flow does it is trivial deployment. All you need is one single file (for your arch at least). You can, just for example, map just the flow binary directly into a docker container and it's installed.
In any case, you have a few options to reduce the binary size:
zig build -Duse_tree_sitter=false -Do…