tags:

views:

668

answers:

3

I'm making some changes to the provisioning app that ships with the Android Eclair source code. I'd like a way to launch the app to test it that doesn't involve reflashing my device or restarting my emulator. The app is located in packages/apps/Provision and the main Activity is src/com/android/provision/DefaultActivity.java. I've tried:

adb shell am start -a android.intent.action.MAIN -n com.android.provision/.DefaultActivity

adb shell am start -n com.android.provision/com.android.provision.DefaultActivity

Both of which return:

Starting: Intent { act=android.intent.action.MAIN cmp=com.android.provision/.DefaultActivity }
Error type 3
Error: Activity class {com.android.provision/com.android.provision.DefaultActivity} does not exist.
A: 

Hi Did you ever get an answer to this questions? I am trying to use the provision app also and with no luck.

robin

robin
Not specifically but I've worked around it. I'll add an answer to this question. If there's not enough detail, let me know.
Marcus
A: 

I added a layout to the provisioning app (which is something my app specifically needed) then commented out the line that sets the device as provisioned as well as the lines that finish the activity and remove the package.

From there I built a system image with the provisioning app and flashed the phone. Since the provisioning app is no longer marking the phone as provisioned I can then build just the provisioning app, use adb sync to push it to the phone and restart the phone to see the changes. It's perhaps not ideal, but it works.

Marcus
A: 

Sounds like this bug: http://code.google.com/p/android/issues/detail?id=9158 Has been fixed in post-Froyo builds. I guess you will need to prepend a dot to the activity name.

EboMike