Crate code2prompt

Source

Re-exports§

pub use filter::should_include_file;
pub use git::get_git_diff;
pub use git::get_git_diff_between_branches;
pub use git::get_git_log;
pub use path::label;
pub use path::traverse_directory;
pub use template::copy_to_clipboard;
pub use template::handle_undefined_variables;
pub use template::handlebars_setup;
pub use template::render_template;
pub use template::write_to_file;
pub use token::count_tokens;
pub use token::get_model_info;
pub use token::get_tokenizer;

Modules§

filter
This module contains the logic for filtering files based on include and exclude patterns.
git
This module handles git operations.
path
This module contains the functions for traversing the directory and processing the files.
template
This module contains the functions to set up the Handlebars template engine and render the template with the provided data. It also includes functions for handling user-defined variables, copying the rendered output to the clipboard, and writing it to a file.
token
This module encapsulates the logic for counting the tokens in the rendered text.