(feat) Moved TARGET in script.

Moved `TARGET` to the top of the bash script. It is still available within the function, but this also exposes it to calls to the function, so that a user does not need to rewrite the command to do so.

This change is also reflected in the README.