separating the bin/jpm helper functions into lib/cmd
a+ promises for createTmpFile and createManifest