clojure-android / lein-droid

A Leiningen plugin for building Clojure/Android projects
Eclipse Public License 1.0
645 stars 56 forks source link

"adb shell am start -n" requires {packageName}/{Activity} format strictly #47

Closed ayamada closed 11 years ago

ayamada commented 11 years ago

It cannot use short format.

adb shell am start -n com.example.MainActivity => Error: Bad component name: com.example.MainActivity
adb shell am start -n com.example/.MainActivity => run app
adb shell am start -n com.example/com.example.MainActivity => run app
alexander-yakushev commented 11 years ago

Atsuo, do you have a usecase where this leads to an error? I left this consciously because it is valid to specify main activity in AndroidManifest package-qualified (and not just its name).

ayamada commented 11 years ago

For example, my AndroidManifest.xml has <manifest package="com.example" ... and <activity android:name="com.example.MainActivity" ...>. And I do lein droid run. But run function in deploy.clj get above error. Because get-launcher-activity function return short name, not {packageName}/{Activity}.

Sorry, I apologize to not write explanation.

alexander-yakushev commented 11 years ago

I should have been more attentive, since you provided the example from the beginning! Sorry for that and thank you, merged via a7a6b9c547d2fb85021a1083ffaaa269b9d71baf.

ayamada commented 11 years ago

No problem, and thank you!