target flag should work in scripts

used to only work in tools, now works in scripts too
Merge pull request #71 from metridoc/target-flag-should-work-in-scripts

target flag should work in scripts