Organized options better using flags
Removed echos & fixed redirect output