Skip to content

Conversation

@weiznich
Copy link
Contributor

During our dependency reviews we discovered that the ttf-parser crate as uploaded to crates.io includes test data and additional tools that are not used by the rust code. This increases the package size and makes it harder to review the source code.

This commit explicitly includes only relevant files. This helps to reduce the package size

Before: 118 files, 1.0MiB (198.4KiB compressed)
After: 75 files, 747.1KiB (140.6KiB compressed)

Overall based on the reduction in the compressed package size and the current download numbers that results to a traffic reduction for crates.io of around 110GB / Month.

@LaurenzV
Copy link
Collaborator

I'd probably wait on some input from others, but I personally think that having a blacklist would be better than a whitelist. Not sure though.

@RazrFalcon
Copy link
Collaborator

During our dependency reviews we discovered that the ttf-parser crate as
uploaded to crates.io includes test data and additional tools that are
not used by the rust code. This increases the package size and makes it
harder to review the source code.

This commit explicitly includes only relevant files. This helps to
reduce the package size

Before: 118 files, 1.0MiB (198.4KiB compressed)
After: 75 files, 747.1KiB (140.6KiB compressed)

Overall based on the reduction in the compressed package size and the
current download numbers that results to a traffic reduction for
crates.io of around 110GB / Month.
@weiznich weiznich force-pushed the remove_unneded_files branch from 23ba294 to 24901a8 Compare September 4, 2025 13:10
@weiznich
Copy link
Contributor Author

weiznich commented Sep 4, 2025

I've updated the PR to use an exclude approach instead.

In contranst to rustybuzz I also excluded:

  • testing-tools as it contains otherwise not needed code
  • examples
  • meson.build

Hopefully that's fine.

The new size is: 76 files, 768.6KiB (146.5KiB compressed)

@LaurenzV LaurenzV merged commit eab7348 into harfbuzz:main Sep 4, 2025
2 checks passed
@LaurenzV
Copy link
Collaborator

LaurenzV commented Sep 4, 2025

Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants