From 23675279fc24ef75a76a93f32bac9aa0b33036de Mon Sep 17 00:00:00 2001 From: koalaman Date: Sat, 13 Jan 2018 16:49:14 -0800 Subject: [PATCH] Created SC2224 (markdown) --- SC2224.md | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 SC2224.md diff --git a/SC2224.md b/SC2224.md new file mode 100644 index 0000000..3d3042b --- /dev/null +++ b/SC2224.md @@ -0,0 +1,22 @@ +## This mv has no destination. Check the arguments. + +### Problematic code: + +```sh +mv "$file $dir" +``` + +### Correct code: + +```sh +mv "$file" "$dir" +``` +### Rationale: + +ShellCheck found an `mv` command with a single parameter. This may be because the source and destination was accidentally merged into a single argument, or because the line was broken in an invalid way. + +Fix the `mv` statement by correctly specifying both source and destination. + +### Exceptions: + +None \ No newline at end of file