{ "id": "120320", "key": "TIMOB-15307", "fields": { "issuetype": { "id": "2", "description": "A new feature of the product, which has yet to be developed.", "name": "New Feature", "subtask": false }, "project": { "id": "10153", "key": "TIMOB", "name": "Titanium SDK/CLI", "projectCategory": { "id": "10100", "description": "Titanium and related SDKs used in application development", "name": "Client" } }, "fixVersions": [ { "id": "15699", "description": "2013 Sprint 21", "name": "2013 Sprint 21", "archived": true, "released": true, "releaseDate": "2013-10-18" }, { "id": "15701", "description": "2013 Sprint 21 Core", "name": "2013 Sprint 21 Core", "archived": true, "released": true, "releaseDate": "2013-10-18" }, { "id": "14982", "description": "Release 3.2.0", "name": "Release 3.2.0", "archived": false, "released": true, "releaseDate": "2013-12-19" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2013-10-19T01:25:16.000+0000", "created": "2013-09-22T04:51:59.000+0000", "priority": { "name": "High", "id": "2" }, "labels": [ "androidbuild", "ay-verified", "cb-verified", "module_CLI", "qe-testadded" ], "versions": [], "issuelinks": [ { "id": "32082", "type": { "id": "10000", "name": "Blocks", "inward": "is blocked by", "outward": "blocks" }, "outwardIssue": { "id": "110719", "key": "TISTUD-3669", "fields": { "summary": "Studio: Expose android keystore for Android non-production builds", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "priority": { "name": "High", "id": "2" }, "issuetype": { "id": "4", "description": "An improvement or enhancement to an existing feature or task.", "name": "Improvement", "subtask": false } } } } ], "assignee": { "name": "cbarber", "key": "cbarber", "displayName": "Chris Barber", "active": true, "timeZone": "America/Chicago" }, "updated": "2013-11-20T18:42:21.000+0000", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "components": [ { "id": "10202", "name": "Android", "description": "Android Platform" }, { "id": "13103", "name": "CLI", "description": "Node-based command line interface" } ], "description": "From [~ygbr] in TISTUD-3669:\r\n\r\nI think that the CLI also currently ignores a custom keystore when deploying directly to the device.\r\n\r\nFor instance, if I do something like:\r\n\r\n\r\n{code}\r\ntitanium build -p android -T device -L pinion -K /PATH-TO-MY/pinion.keystore -P *********\r\n{code}\r\n\r\n\r\ntheoretically the app should be signed with my keystore and them sent to the device for running.\r\n\r\nBUT, taking a closer look at what the CLI is doing, you can see that the build script completely ignores the custom keystore parameters and signs the app with the default tidev keystore:\r\n\r\n\r\n{code}\r\n[DEBUG] keytool -v -list -keystore \"/Users/yg/Library/Application Support/Titanium/mobilesdk/osx/3.1.1.GA/android/dev_keystore\" -storepass ******* -alias tidev\r\n[DEBUG] jarsigner -sigalg MD5withRSA -digestalg SHA1 -storepass ******* -keystore \"/Users/yg/Library/Application Support/Titanium/mobilesdk/osx/3.1.1.GA/android/dev_keystore\" -signedjar /Users/yg/Developer/android/build/android/bin/app.apk /Users/yg/Developer/android/build/android/bin/app-unsigned.apk tidev\r\n[DEBUG] /Applications/Android/sdk/tools/zipalign -v 4 /Users/yg/Developer/android/build/android/bin/app.apk /Users/yg/Developer/android/build/android/bin/app.apkz\r\n{code}\r\n\r\n\r\nThis is a GIANT pain, specially when you need to test stuff involving the new GMaps v2 and Facebook SSO authentication since they depend on the app being signed with your production keystore (although FB accepts many keys).\r\n\r\nIs there a specific JIRA ticket for this? I know that this isn't exactly Studio but it is very related with this ticket and should also exist on the CLI since many developers like me use only the CLI...", "attachment": [], "flagged": false, "summary": "CLI: support custom keystore when running on Android device", "creator": { "name": "mxia", "key": "mxia", "displayName": "Michael Xia", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "ygbr", "key": "ygbr", "displayName": "Ygor Lemos", "active": true, "timeZone": "America/Sao_Paulo" }, "environment": null, "comment": { "comments": [ { "id": "273916", "author": { "name": "cbarber", "key": "cbarber", "displayName": "Chris Barber", "active": true, "timeZone": "America/Chicago" }, "body": "Pull request: https://github.com/appcelerator/titanium_mobile/pull/4760", "updateAuthor": { "name": "cbarber", "key": "cbarber", "displayName": "Chris Barber", "active": true, "timeZone": "America/Chicago" }, "created": "2013-10-05T00:27:39.000+0000", "updated": "2013-10-05T00:27:39.000+0000" }, { "id": "273930", "author": { "name": "asor", "key": "asor", "displayName": "Kyle Berezin", "active": true, "timeZone": "America/New_York" }, "body": "I just ran into this problem and I am on a pretty tight time crunch. I am not outputting to a device, but to a folder I made. The compilation goes without a hitch but the file never makes it to the folder, and on closer inspection is signed with a dev keystore rather than the one I specified.\r\nI would just manually sign \"app-unsigned.apk\" but the source files are not obfuscated. Is there any way to get around this issue?", "updateAuthor": { "name": "asor", "key": "asor", "displayName": "Kyle Berezin", "active": true, "timeZone": "America/New_York" }, "created": "2013-10-05T11:16:30.000+0000", "updated": "2013-10-05T11:16:30.000+0000" }, { "id": "273939", "author": { "name": "cbarber", "key": "cbarber", "displayName": "Chris Barber", "active": true, "timeZone": "America/Chicago" }, "body": "[~asor] You need to package your app for distribution. That will minify and encrypt the code as well as allow you to sign the app with whatever keystore you wish. If building from Studio, it's under the package icon menu. If building from the CLI, then use \"ti build -p android -T dist-playstore\".", "updateAuthor": { "name": "cbarber", "key": "cbarber", "displayName": "Chris Barber", "active": true, "timeZone": "America/Chicago" }, "created": "2013-10-05T20:49:51.000+0000", "updated": "2013-10-05T20:49:51.000+0000" }, { "id": "275828", "author": { "name": "ayeung", "key": "ayeung", "displayName": "Allen Yeung", "active": true, "timeZone": "America/Los_Angeles" }, "body": "PR: https://github.com/appcelerator/titanium_mobile/pull/4781", "updateAuthor": { "name": "ayeung", "key": "ayeung", "displayName": "Allen Yeung", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-10-19T01:25:16.000+0000", "updated": "2013-10-19T01:25:16.000+0000" } ], "maxResults": 4, "total": 4, "startAt": 0 } } }