macro_rules! count_it_all {
() => { ... };
(workspace: true) => { ... };
(workspace: false) => { ... };
($other:tt) => { ... };
}Expand description
Fires up a comprehensive line count across all file types in your project with CountRoo. 🌍🔢
count_it_all is your one-stop macro for when you want to dive deep and get a full count
of every line of code, across all file types recognized by your CountRoo configuration.
It’s like commissioning CountRoo for a grand tour of your entire codebase, leaving no
stone unturned.
This macro simplifies the process by automatically setting up CountRoo with a configuration
based on a relative file path to “config.txt”, initiating a thorough line count, and then
exporting the tally to stdout. Ideal for when you need a bird’s-eye view of your project’s
size and scope.
§Requirements
- The
defaultfeature flag must be active for this macro to come into play. - Ensure that
CountRoo,Config, and an appropriateOutputWriter(likeStdoutWriter) are in scope and properly defined.
§Example Invocation
To get a comprehensive line count of your project, simply call:
// Inside build.rs
use countroo::prelude::*;
fn main() {
count_it_all!();
// If you're using it for a workspace, you can just use it like this inside any project's build.rs
countroo::count_it_all!(workspace: true);
}Whether you’re evaluating the scale of a new project, or you need detailed metrics for
documentation or analysis, count_it_all! offers a hassle-free solution to gather those
insights with minimal setup. 🚀📊