cantino / mcfly

Fly through your shell history. Great Scott!
MIT License
6.75k stars 176 forks source link

Remove unnecessary/unused regex features #352

Closed jirutka closed 1 year ago

jirutka commented 1 year ago

To reduce binary size.

cantino commented 1 year ago

Does this have any other impact on our regex that I should be aware of besides removing \d? How significant is the size reduction?

jirutka commented 1 year ago

Does this have any other impact on our regex that I should be aware of besides removing \d?

No, not on the regexes you currently use.

How significant is the size reduction?

About 400–500 kiB for the release build (with stripped debug symbols and enabled LTO). You can see it in Alpine Linux package mcfly – it’s built with opt-level = "s", panic = "abort", lto = true, codegen-units = 1, strip = true, without bundled sqlite and with this patch applied.

cantino commented 1 year ago

Thanks!

cantino commented 1 year ago

Released in https://github.com/cantino/mcfly/releases/tag/v0.8.1