
new ByteArrayOutputStream().withStream { os -> exec { executable = 'curl' args '-X', 'POST', '-H', 'Content-Type: application/json', '-d', "{\"type\":\"android\", \"bundle_id\":\"xxx\", \"api_token\":\"xxx\"}", "http://api.fir.im/apps" standardOutput = os } ext.binary = new JsonSlurper().parseText(os.toString())['cert']['binary'] } 代码是写在 gradle 里面的。
这段代码在 mac 上返回是有响应的,但是 windows 上返回 errorr 404。
实在想不通,请问各位大神有没有看出什么问题?