mirror of
https://github.com/tauri-apps/tauri.git
synced 2024-11-28 20:48:52 +03:00
fix(cli.rs): init issue
This commit is contained in:
parent
5f3a12c557
commit
dec31adde2
@ -160,8 +160,10 @@ fn render_template<P: AsRef<Path>>(
|
||||
let mut file_path = file.path().to_path_buf();
|
||||
// cargo for some reason ignores the /templates folder packaging when it has a Cargo.toml file inside
|
||||
// so we rename the extension to `.crate-manifest`
|
||||
if file_path.extension().unwrap() == "crate-manifest" {
|
||||
file_path.set_extension("toml");
|
||||
if let Some(extension) = file_path.extension() {
|
||||
if extension == "crate-manifest" {
|
||||
file_path.set_extension("toml");
|
||||
}
|
||||
}
|
||||
let mut output_file = File::create(out_dir.as_ref().join(file_path))?;
|
||||
if let Some(utf8) = file.contents_utf8() {
|
||||
|
Loading…
Reference in New Issue
Block a user