Previously, arguments were examined by a for loop, but this loop is not
affected by the `shift` commands executed inside of it.
Because the loop always advances one argument further on each iteration,
this bug goes unnoticed with the `--portrait` option (`shift` is called
once, which matches the behavior of the loop). However, handling of the
`--destination` argument is broken because of that (`shift` is called
twice but the loop only advances one argument).
This commit replaces the `for` loop by a `while` loop which always
examines the next argument and properly takes `shift`s into account.
This is based on the following SO answer:
<https://stackoverflow.com/a/7069755/3452708>
Changed the README to reflect the command line options added with
bcf62e3. Also incorporates the SSH timeout of 1 second added by the
initial PR (#10).
Co-authored-by: Aaron David Schneider <aaron.david.schneider@gmail.com>