Skip to main content

Clang-include-cleaner is an LLVM-based tool for finding and removing unused #include directives in C++ code

Project description

clang-include-cleaner Python distribution

PyPI Release

This project packages the clang-include-cleaner utility as a Python package. It allows you to install clang-include-cleaner directly from PyPI:

python -m pip install clang-include-cleaner

This project intends to release a new PyPI package for each major and minor release of clang-include-cleaner.

What is clang-include-cleaner?

clang-include-cleaner is an LLVM-based tool that analyzes C++ source files and identifies unused #include directives that can be safely removed. It is part of the clang-tools-extra suite.

Use with pipx

You can use pipx to run clang-include-cleaner, as well. For example, pipx run clang-include-cleaner <args> will run clang-include-cleaner without any previous install required on any machine with pipx (including all default GitHub Actions / Azure runners, avoiding requiring a pre-install step or even actions/setup-python).

Building new releases

The clang-include-cleaner repository provides the logic to build and publish binary wheels of the clang-include-cleaner utility.

In order to add a new release, the following steps are necessary:

On manual triggers, the following input variables are available:

  • use_qemu: Whether to build targets that require emulation (default: true)
  • llvm_version: Override the LLVM version (default: "")
  • wheel_version: Override the wheel packaging version (default "0")
  • deploy_to_testpypi: Whether to deploy to TestPyPI instead of PyPI (default: false)

The repository with the precommit hook is automatically updated using a scheduled Github Actions workflow.

Acknowledgments

This repository extends the great work of several other projects:

  • clang-include-cleaner itself is provided by the LLVM project under the Apache 2.0 License with LLVM exceptions.
  • The build logic is based on scikit-build which greatly reduces the amount of low level code necessary to package clang-include-cleaner.
  • The scikit-build packaging examples of CMake and Ninja were very helpful in packaging clang-include-cleaner.
  • The CI build process is controlled by cibuildwheel which makes building wheels across a number of platforms a pleasant experience (!)

We are grateful for the generous provisioning with CI resources that GitHub currently offers to Open Source projects.

Troubleshooting

To see which clang-include-cleaner binary the package is using you can set CLANG_INCLUDE_CLEANER_WHEEL_VERBOSE to 1 in your environment.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

clang_include_cleaner-22.1.7.tar.gz (11.1 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

clang_include_cleaner-22.1.7-py2.py3-none-win_amd64.whl (13.5 MB view details)

Uploaded Python 2Python 3Windows x86-64

clang_include_cleaner-22.1.7-py2.py3-none-win32.whl (11.8 MB view details)

Uploaded Python 2Python 3Windows x86

clang_include_cleaner-22.1.7-py2.py3-none-musllinux_1_2_x86_64.whl (19.9 MB view details)

Uploaded Python 2Python 3musllinux: musl 1.2+ x86-64

clang_include_cleaner-22.1.7-py2.py3-none-musllinux_1_2_i686.whl (22.4 MB view details)

Uploaded Python 2Python 3musllinux: musl 1.2+ i686

clang_include_cleaner-22.1.7-py2.py3-none-musllinux_1_2_armv7l.whl (17.2 MB view details)

Uploaded Python 2Python 3musllinux: musl 1.2+ ARMv7l

clang_include_cleaner-22.1.7-py2.py3-none-manylinux_2_31_armv7l.whl (16.0 MB view details)

Uploaded Python 2Python 3manylinux: glibc 2.31+ ARMv7l

clang_include_cleaner-22.1.7-py2.py3-none-manylinux_2_28_i686.whl (20.8 MB view details)

Uploaded Python 2Python 3manylinux: glibc 2.28+ i686

clang_include_cleaner-22.1.7-py2.py3-none-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl (18.0 MB view details)

Uploaded Python 2Python 3manylinux: glibc 2.27+ x86-64manylinux: glibc 2.28+ x86-64

clang_include_cleaner-22.1.7-py2.py3-none-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl (17.0 MB view details)

Uploaded Python 2Python 3manylinux: glibc 2.26+ ARM64manylinux: glibc 2.28+ ARM64

clang_include_cleaner-22.1.7-py2.py3-none-macosx_11_0_arm64.whl (13.2 MB view details)

Uploaded Python 2Python 3macOS 11.0+ ARM64

clang_include_cleaner-22.1.7-py2.py3-none-macosx_10_9_x86_64.whl (13.7 MB view details)

Uploaded Python 2Python 3macOS 10.9+ x86-64

File details

Details for the file clang_include_cleaner-22.1.7.tar.gz.

File metadata

  • Download URL: clang_include_cleaner-22.1.7.tar.gz
  • Upload date:
  • Size: 11.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for clang_include_cleaner-22.1.7.tar.gz
Algorithm Hash digest
SHA256 27c5903ab18ad83d598b23e10cb1a3e5d7f6d1aa2fce6ff9a7c49b6b504c19bc
MD5 f55a631fe441bd4f269f54a9e1f1f730
BLAKE2b-256 e20974989e97ba13b2572e63d4b9678fb87c802177d1437839c7c8ba8d0ff7fc

See more details on using hashes here.

Provenance

The following attestation bundles were made for clang_include_cleaner-22.1.7.tar.gz:

Publisher: release.yml on cpp-linter/clang-include-cleaner

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file clang_include_cleaner-22.1.7-py2.py3-none-win_amd64.whl.

File metadata

File hashes

Hashes for clang_include_cleaner-22.1.7-py2.py3-none-win_amd64.whl
Algorithm Hash digest
SHA256 7d4af3da0b3e0aaa2e619f7b666bb2b61ed657d7031affe32054b33298f9e040
MD5 f08dcae7f52637ad3b8b215917139b7f
BLAKE2b-256 fe1987dbe7da41508116f2069e92ba991af69e4c1ead8b26da0657fdfe8174a4

See more details on using hashes here.

Provenance

The following attestation bundles were made for clang_include_cleaner-22.1.7-py2.py3-none-win_amd64.whl:

Publisher: release.yml on cpp-linter/clang-include-cleaner

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file clang_include_cleaner-22.1.7-py2.py3-none-win32.whl.

File metadata

File hashes

Hashes for clang_include_cleaner-22.1.7-py2.py3-none-win32.whl
Algorithm Hash digest
SHA256 2cc5f796f2c8f5662a14a99b1e45bbea82cbc1e7248c50bfe8cf0b861dd464bf
MD5 a1c7c1430d9e2423ad074f0020413570
BLAKE2b-256 664dbef5c64220c8c5d3601e20a83b3ebc08368d46dea64b735cf62d48f4a230

See more details on using hashes here.

Provenance

The following attestation bundles were made for clang_include_cleaner-22.1.7-py2.py3-none-win32.whl:

Publisher: release.yml on cpp-linter/clang-include-cleaner

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file clang_include_cleaner-22.1.7-py2.py3-none-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for clang_include_cleaner-22.1.7-py2.py3-none-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 84becce390d38cc5a4c510e5e3f83e654913d6b8abf388df5648dc8a7360ccea
MD5 578e97c6d67098ebbcb0d9ba0450137e
BLAKE2b-256 159f477c144508262f839b8babd229a595084bc261658736e355c82d36969be5

See more details on using hashes here.

Provenance

The following attestation bundles were made for clang_include_cleaner-22.1.7-py2.py3-none-musllinux_1_2_x86_64.whl:

Publisher: release.yml on cpp-linter/clang-include-cleaner

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file clang_include_cleaner-22.1.7-py2.py3-none-musllinux_1_2_i686.whl.

File metadata

File hashes

Hashes for clang_include_cleaner-22.1.7-py2.py3-none-musllinux_1_2_i686.whl
Algorithm Hash digest
SHA256 d7812b73316473293ec73744154b2b268f2d380823579c9cb46dc85e2579d645
MD5 528eba4a1016995c9a83cf1c26cdd02f
BLAKE2b-256 3811cbdf65b3beb41dc2b982fa3d1d54d4635a30c75eaf9d313e08d64d7eb4de

See more details on using hashes here.

Provenance

The following attestation bundles were made for clang_include_cleaner-22.1.7-py2.py3-none-musllinux_1_2_i686.whl:

Publisher: release.yml on cpp-linter/clang-include-cleaner

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file clang_include_cleaner-22.1.7-py2.py3-none-musllinux_1_2_armv7l.whl.

File metadata

File hashes

Hashes for clang_include_cleaner-22.1.7-py2.py3-none-musllinux_1_2_armv7l.whl
Algorithm Hash digest
SHA256 835b75b44d0f65d93f268d831fcac866a73582584ae7e40df43467456c2d1c64
MD5 84aa577042a9621e6fcb8c4444088133
BLAKE2b-256 9dd205a10213273baa97ca2fba9055b25eb92f59459c3ad5393c78fb603a28d3

See more details on using hashes here.

Provenance

The following attestation bundles were made for clang_include_cleaner-22.1.7-py2.py3-none-musllinux_1_2_armv7l.whl:

Publisher: release.yml on cpp-linter/clang-include-cleaner

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file clang_include_cleaner-22.1.7-py2.py3-none-manylinux_2_31_armv7l.whl.

File metadata

File hashes

Hashes for clang_include_cleaner-22.1.7-py2.py3-none-manylinux_2_31_armv7l.whl
Algorithm Hash digest
SHA256 e49ce7296f1153e1da75a680cdc4a6d2117badee270de0bcba541ae3e613d2d5
MD5 5a9a511340b838834e3003e4667db400
BLAKE2b-256 89b0e185a35bae77deed1186095328dada875f7129f7beb36ad770d157f3044d

See more details on using hashes here.

Provenance

The following attestation bundles were made for clang_include_cleaner-22.1.7-py2.py3-none-manylinux_2_31_armv7l.whl:

Publisher: release.yml on cpp-linter/clang-include-cleaner

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file clang_include_cleaner-22.1.7-py2.py3-none-manylinux_2_28_i686.whl.

File metadata

File hashes

Hashes for clang_include_cleaner-22.1.7-py2.py3-none-manylinux_2_28_i686.whl
Algorithm Hash digest
SHA256 b0f6da44aa84525e64a15a36a821a4f9bc120a0b7ffa65ffcf2aa3ba6b447b2f
MD5 da44d5261ff0cc718309c19bb9b6d1ab
BLAKE2b-256 4057bad17389fb44247ab99a22456d638e73a9abe6476dc14874f3d0894dc441

See more details on using hashes here.

Provenance

The following attestation bundles were made for clang_include_cleaner-22.1.7-py2.py3-none-manylinux_2_28_i686.whl:

Publisher: release.yml on cpp-linter/clang-include-cleaner

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file clang_include_cleaner-22.1.7-py2.py3-none-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for clang_include_cleaner-22.1.7-py2.py3-none-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 260887225c3739e5abefb4a93f007d0ddd187c2bef20e445a47df1023af787be
MD5 8b97632830f21561df18c51999c325e9
BLAKE2b-256 45a31d9a68197b2ffcd17c2a74476c9009b6a99cfd6ac0b6aa7f78ee6b882f74

See more details on using hashes here.

Provenance

The following attestation bundles were made for clang_include_cleaner-22.1.7-py2.py3-none-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl:

Publisher: release.yml on cpp-linter/clang-include-cleaner

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file clang_include_cleaner-22.1.7-py2.py3-none-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for clang_include_cleaner-22.1.7-py2.py3-none-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 720c255cac06620676347ad8caae68952434850785beb3d532c3f85408c44b42
MD5 b7784a04dc4f1179e1ceb3718f7ca556
BLAKE2b-256 ac0e3714d3f5ebeec3a70ca63deba1de922516d7da4f4942fc59a4b26f094aa9

See more details on using hashes here.

Provenance

The following attestation bundles were made for clang_include_cleaner-22.1.7-py2.py3-none-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl:

Publisher: release.yml on cpp-linter/clang-include-cleaner

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file clang_include_cleaner-22.1.7-py2.py3-none-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for clang_include_cleaner-22.1.7-py2.py3-none-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 98807591676781977b63cddff3fe85a899ec2db83eb4e775d153a0773a2de634
MD5 d0790aa59c0b20b5229e2f379f666b39
BLAKE2b-256 687097deabed3eacd75b806cf153989135d1b565913f16ab8a204508c0507204

See more details on using hashes here.

Provenance

The following attestation bundles were made for clang_include_cleaner-22.1.7-py2.py3-none-macosx_11_0_arm64.whl:

Publisher: release.yml on cpp-linter/clang-include-cleaner

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file clang_include_cleaner-22.1.7-py2.py3-none-macosx_10_9_x86_64.whl.

File metadata

File hashes

Hashes for clang_include_cleaner-22.1.7-py2.py3-none-macosx_10_9_x86_64.whl
Algorithm Hash digest
SHA256 0ed5fe234e36b0818fcf61afb6a7f7ea7083a566d292ce017f14df8e86cc4f18
MD5 d826c1002f29d2e9283b1e071b343a9b
BLAKE2b-256 66e7e5f12c01f94274cca1691550bd62f0c0261b6fa1bc50fca350c05e26791a

See more details on using hashes here.

Provenance

The following attestation bundles were made for clang_include_cleaner-22.1.7-py2.py3-none-macosx_10_9_x86_64.whl:

Publisher: release.yml on cpp-linter/clang-include-cleaner

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page