Refactor command line arguments and flavours
* Get rid of unsafePerformIO using shakeExtra * Move diagnostic info utilities to the library See #347
* Get rid of unsafePerformIO using shakeExtra * Move diagnostic info utilities to the library See #347