diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 4d902d3..8ed1491 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,6 +1,6 @@ repos: - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v4.6.0 + rev: v5.0.0 hooks: - id: check-added-large-files - id: check-case-conflict @@ -14,12 +14,12 @@ repos: args: [--autofix, --no-sort-keys] - repo: https://github.com/DavidAnson/markdownlint-cli2 - rev: v0.13.0 + rev: v0.14.0 hooks: - id: markdownlint-cli2 - repo: https://github.com/opensource-nepal/commitlint - rev: v1.2.0 + rev: v1.3.0 hooks: - id: commitlint diff --git a/README.md b/README.md index cff91fa..ee98c80 100644 --- a/README.md +++ b/README.md @@ -114,5 +114,5 @@ Extract with `unzip your_project.xrns` first. Once unzipped, you will find a ## Contributing Thanks for your help improving the project! :balloon: Happy to have you! Peruse -the [contributing guide](./.github/CONTRIBUTING.md) to help you get involved in +the [contributing guide](./docs/CONTRIBUTING.md) to help you get involved in the project. diff --git a/src/lib.rs b/src/lib.rs index e89638b..fca1178 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -64,7 +64,12 @@ pub struct Args { pub fn set_filename(song_title: &str) -> String { let credits_file: String = format!( "{}-credits.md", - song_title.replace(&[' ', '\''][..], "-").to_lowercase() + song_title + .replace( + &['/', '\\', '(', ')', '[', ']', '<', '>', '{', '}', ' ', '\'', '"', '?', '!'][..], + "-" + ) + .to_lowercase() ); credits_file }