Skip to content

Commit 43df320

Browse files
authored
Merge pull request #136 from warpdotdev/aloke/pin_rust_version
Fix clippy warnings caused by rust update
2 parents b412ed4 + 7f24d9f commit 43df320

1 file changed

Lines changed: 5 additions & 5 deletions

File tree

workflows/build.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ fn main() -> Result<()> {
3434

3535
println!("attempting to generate workflow at {:?}", entry.path());
3636
let workflow: Workflow = serde_yaml::from_str(yaml_content)?;
37-
println!("generated workflow is {:?}", workflow);
37+
println!("generated workflow is {workflow:?}");
3838

3939
let file_name = entry
4040
.file_name()
@@ -43,14 +43,14 @@ fn main() -> Result<()> {
4343
.replace(".yaml", "")
4444
.replace(".yml", "")
4545
.to_case(Case::Snake);
46-
println!("file name is {:?}", file_name);
46+
println!("file name is {file_name:?}");
4747

4848
// Create a module for each Workflow within the parent module.
4949
workflows_added.push(file_name.clone());
5050

5151
write_workflow(workflow, file_name.as_str())?;
5252

53-
writeln!(&parent_module, "pub mod {};", file_name)?;
53+
writeln!(&parent_module, "pub mod {file_name};")?;
5454
}
5555
}
5656

@@ -84,7 +84,7 @@ fn write_workflows_function(
8484
writeln!(parent_module, "pub fn workflows() -> Vec<Workflow> {{")?;
8585
writeln!(parent_module, "vec![")?;
8686
for workflows in workflows_added {
87-
writeln!(parent_module, "{}::workflow(),", workflows)?;
87+
writeln!(parent_module, "{workflows}::workflow(),")?;
8888
}
8989
writeln!(parent_module, "]")?;
9090
writeln!(parent_module, "}}")?;
@@ -103,7 +103,7 @@ fn write_workflows_function(
103103
/// }
104104
/// ```
105105
fn write_workflow(workflow: Workflow, file_name: &str) -> Result<()> {
106-
let module = std::fs::File::create(format!("src/generated_workflows/{}.rs", file_name))?;
106+
let module = std::fs::File::create(format!("src/generated_workflows/{file_name}.rs"))?;
107107

108108
writeln!(&module, "use warp_workflows_types::*;")?;
109109
writeln!(&module, r#"pub fn workflow() -> Workflow {{"#)?;

0 commit comments

Comments
 (0)