Skip to content

Commit

Permalink
Add Aknowledgements section to Readme, fix formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
an-dr committed Jan 21, 2025
1 parent 01eb5ce commit 5a65791
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 18 deletions.
8 changes: 8 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
- [Storage Layout](#storage-layout)
- [Template Variables](#template-variables)
- [💡 Notes](#-notes)
- [❤️ Aknowledgements](#️-aknowledgements)
- [🤝 Contribute](#-contribute)
- [License](#license)

Expand Down Expand Up @@ -103,6 +104,13 @@ Yes, you can use spaces in the variable name! 😄

For questions, feedback, or contributions, don't hesitate to reach out!

## ❤️ Aknowledgements

| Contributor | Contribution |
| ----------- | ------------ |
| [@Arteiii](https://github.com/Arteiii) | 🪟 Windows installer [#5](https://github.com/an-dr/creator/pull/5) <br> ⚙️ Actions improvements [#5](https://github.com/an-dr/creator/pull/5)
| [@zamazan4ik](https://github.com/zamazan4ik) | 💡 Optimization proposals [#9](https://github.com/an-dr/creator/issues/9) |

## 🤝 Contribute

For the application design and architecture see [docs/design.md](docs/design.md).
Expand Down
21 changes: 3 additions & 18 deletions src/creator.rs
Original file line number Diff line number Diff line change
Expand Up @@ -69,12 +69,7 @@ impl Creator {
// Replace the variables in the path
let mut dest_path_str = dest_path.to_str().expect("The path should be valid").to_string();
for (var_name, var_value) in &self.source_variable_values {
let new_var_name = format!(
"{}{}{}",
Self::TEMPLATE_VAR_PREFIX,
var_name,
Self::TEMPLATE_VAR_SUFFIX
);
let new_var_name = format!("{}{}{}", Self::TEMPLATE_VAR_PREFIX, var_name, Self::TEMPLATE_VAR_SUFFIX);
dest_path_str = dest_path_str.replace(&new_var_name, var_value);
}

Expand All @@ -93,12 +88,7 @@ impl Creator {
// Replace the variables in the path
let mut dest_path_str = dest_path.to_str().expect("The path should be valid").to_string();
for (var_name, var_value) in &self.source_variable_values {
let new_var_name = format!(
"{}{}{}",
Self::TEMPLATE_VAR_PREFIX,
var_name,
Self::TEMPLATE_VAR_SUFFIX
);
let new_var_name = format!("{}{}{}", Self::TEMPLATE_VAR_PREFIX, var_name, Self::TEMPLATE_VAR_SUFFIX);
dest_path_str = dest_path_str.replace(&new_var_name, var_value);
}
debug!("Dest path: {:?}\n", dest_path_str);
Expand All @@ -110,12 +100,7 @@ impl Creator {
let content = fs::read_to_string(&dest_path_str)?;
let mut new_content = content.clone();
for (var_name, var_value) in &self.source_variable_values {
let var_name = format!(
"{}{}{}",
Self::TEMPLATE_VAR_PREFIX,
var_name,
Self::TEMPLATE_VAR_SUFFIX
);
let var_name = format!("{}{}{}", Self::TEMPLATE_VAR_PREFIX, var_name, Self::TEMPLATE_VAR_SUFFIX);
new_content = new_content.replace(&var_name, var_value);
}
// Write the new content
Expand Down

0 comments on commit 5a65791

Please sign in to comment.