| | 1 | = EdenMobile Debugging = |
| | 2 | [[TOC]] |
| | 3 | |
| | 4 | == Database on Android Device == |
| | 5 | |
| | 6 | To be able to view the EdenMobile database on an Android device, make sure that: |
| | 7 | |
| | 8 | - the App is build with debug-option |
| | 9 | - you have the Android Debug Bridge ''adb'' installed (part of the Android SDK) |
| | 10 | |
| | 11 | Then you can copy the database from the device to the SD card, and pull it from there to your development machine. |
| | 12 | |
| | 13 | Linux users can use the following script: |
| | 14 | {{{ |
| | 15 | #!/bin/bash |
| | 16 | PACKAGE=org.sahanafoundation.eden_mobile |
| | 17 | FILENAME=emdb.db |
| | 18 | adb shell run-as $PACKAGE chmod 777 /data/data/$PACKAGE/databases/ |
| | 19 | adb shell run-as $PACKAGE chmod 777 /data/data/$PACKAGE/databases/$FILENAME |
| | 20 | adb shell cp /data/data/$PACKAGE/databases/$FILENAME /sdcard/ |
| | 21 | adb pull /sdcard/$FILENAME |
| | 22 | }}} |
| | 23 | |
| | 24 | (Windows users analogously, just not /bin/bash then ;)) |
| | 25 | |
| | 26 | Then use e.g. [[http://sqlitebrowser.org SQLiteBrowser]] to browse the database schema and data. |