diff --git a/README.md b/README.md new file mode 100644 index 0000000..f675f4e --- /dev/null +++ b/README.md @@ -0,0 +1,16 @@ +# movie-rename + +## A simple tool to reame movies, written in Rust. + +This is made mostly due to [mnamer](https://github.com/jkwill87/mnamer) not having support for director's name, and partly because I wanted to try writing something useful in Rust. + +The expected syntax is: + +`movie_rename [--dry-run]` +- There needs to be a config file names movie_rename.conf in your $XDG_CONFIG_HOME. +- It should consist of two lines. The first line should have your TMDb API key. +- The second line should have a pattern, that will be used for the rename. +- In the pattern, the variables need to be enclosed in {{}}, the supported variables are `title`, `year` and `director`. +- Default pattern is `{title} ({year}) - {director}`. Extension is always kept. + +I plan to add more variables in the future. Support for TV Shows will not be added, since [tvnamer](https://github.com/dbr/tvnamer) does that excellently. \ No newline at end of file diff --git a/src/main.rs b/src/main.rs index 4caf93a..397d7b1 100644 --- a/src/main.rs +++ b/src/main.rs @@ -51,16 +51,16 @@ fn main() { // If --help is passed, show help and exit if filenames.contains(&"--help".to_string()) { - println!("The expected syntax is:"); - println!("movie_rename [--dry-run]"); + println!(" The expected syntax is:"); + println!(" movie_rename [--dry-run]"); println!( - "There needs to be a config file names movie_rename.conf in your $XDG_CONFIG_HOME." + " There needs to be a config file names movie_rename.conf in your $XDG_CONFIG_HOME." ); - println!("It should consist of two lines. The first line should have your TMDb API key."); - println!("The second line should have a pattern, that will be used for the rename."); - println!("In the pattern, the variables need to be enclosed in {{}}, the supported variables are `title`, `year` and `director`."); + println!(" It should consist of two lines. The first line should have your TMDb API key."); + println!(" The second line should have a pattern, that will be used for the rename."); + println!(" In the pattern, the variables need to be enclosed in {{}}, the supported variables are `title`, `year` and `director`."); println!( - "Extension is always kept. Default pattern is `{{title}} ({{year}}) - {{director}}`" + " Default pattern is `{{title}} ({{year}}) - {{director}}`. Extension is always kept." ); exit(0); }