Trait guidon::TryNew [−][src]
Try to initialize Guidon from different sources
Required methods
Loading content...Implementors
impl<'a> TryNew<CustomTemplate<'a>> for Guidon<'a>
[src]
impl<'a> TryNew<CustomTemplate<'a>> for Guidon<'a>
[src]fn try_new(src: CustomTemplate<'a>) -> Result<Self>
[src]
Initialization from a directory and a custom template file
Arguments
- dir_path: the base directory of templatized files
- template_path: the path of the template file to apply. Must respect
template.toml
syntax
impl<'a> TryNew<GitOptions> for Guidon<'a>
[src]
impl<'a> TryNew<GitOptions> for Guidon<'a>
[src]fn try_new(git: GitOptions) -> Result<Self>
[src]
Initialization from a git repository
The repo MUST contains at its root a template.toml
file.
impl<'a, P: 'a + AsRef<Path>> TryNew<P> for Guidon<'a>
[src]
impl<'a, P: 'a + AsRef<Path>> TryNew<P> for Guidon<'a>
[src]fn try_new(path: P) -> Result<Self>
[src]
Initialization from a folder path or a file path
- dir_path: the base directory for guidon-cli template. The file
template.toml
is searched in this directory, and templates files intemplate
dir. - file_path: the path of the template file. The working dir is the current dir.