pub struct TemplateManager { /* private fields */ }Expand description
Template manager for Ferrous Forge
Implementations§
Source§impl TemplateManager
impl TemplateManager
Sourcepub fn generate_cargo_toml(
&self,
project_name: &str,
is_lib: bool,
) -> Result<String>
pub fn generate_cargo_toml( &self, project_name: &str, is_lib: bool, ) -> Result<String>
Generate a Cargo.toml file with Ferrous Forge standards
Sourcepub fn generate_main_rs(&self, project_name: &str) -> Result<String>
pub fn generate_main_rs(&self, project_name: &str) -> Result<String>
Generate a main.rs file with Ferrous Forge standards
Sourcepub fn generate_lib_rs(&self, project_name: &str) -> Result<String>
pub fn generate_lib_rs(&self, project_name: &str) -> Result<String>
Generate a lib.rs file with Ferrous Forge standards
Sourcepub fn generate_github_workflow(&self, project_name: &str) -> Result<String>
pub fn generate_github_workflow(&self, project_name: &str) -> Result<String>
Generate GitHub Actions CI workflow
Sourcepub async fn apply_to_project(&self, project_path: &Path) -> Result<()>
pub async fn apply_to_project(&self, project_path: &Path) -> Result<()>
Apply templates to an existing project
Trait Implementations§
Auto Trait Implementations§
impl Freeze for TemplateManager
impl !RefUnwindSafe for TemplateManager
impl Send for TemplateManager
impl Sync for TemplateManager
impl Unpin for TemplateManager
impl !UnwindSafe for TemplateManager
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more