cclean

Crates.iocclean
lib.rscclean
version0.0.2
sourcesrc
created_at2023-04-16 19:32:33.108173
updated_at2023-04-16 23:09:15.223719
descriptiona cmake sanitizer
homepagehttps://github.com/mcandre/cclean
repository
max_upload_size
id840814
size27,360
Andrew (mcandre)

documentation

README

cclean: a cmake sanitizer

SUMMARY

cclean cleans up cmake's messiest build artifacts.

EXAMPLE

$ cd example

$ cmake .
$ cmake --build . --target hello
$ tree
.
├── CMakeCache.txt
├── CMakeFiles
...
├── CMakeLists.txt
├── Makefile
├── bin
│   └── hello
├── cmake_install.cmake
└── hello.c

$ cclean
$ tree
.
├── CMakeLists.txt
└── hello.c

See cclean -h for more options.

ABOUT

cclean assists cmake with removing common internal artifacts. This is helpful for freeing up disk space.

cmake often enters a corrupt state, requiring manual intervention. cclean automates the process of resetting cmake back to a clean state.

cclean is particularly helpful for cross-platform workflows. For example, when building the same host directory once in WSL, and then again in PowerShell.

NOTABLE FEATURES

  • cclean runs independently of cmake, enabling it to remove sticky cmake artifacts like .ninja_log
  • cclean removes custom -B build directories
  • cclean wraps the cmake global clean target
  • cclean removes cached conan packages

Like cmake, cclean encourages portable build steps. This enables cmake projects to build more reliably on more environments.

WARNING

Configure the cmake global clean target (esp. ADDITIONAL_CLEAN_FILES) carefully, in order to avoid accidents.

CRATE

https://crates.io/crates/cclean

INSTALL FROM SOURCE

$ cargo install --force --path .

RUNTIME REQUIREMENTS

CONTRIBUTING

For more details on developing cclean itself, see DEVELOPMENT.md.

LICENSE

FreeBSD

SEE ALSO

  • git, a distributed version control system
  • gitignore.io, community maintained gitignore templates
  • make, the classic, plain build system
  • ninja, the fast, plain build system
  • unmake, a linter for manually written makefiles
Commit count: 0

cargo fmt