Browse Source

android readme: extend "access datadir on Android from desktop"

- add commands to restrict unix permissions for pushed files
- add notes for "multiple user profiles" case
master
SomberNight 1 year ago
parent
commit
eb3b288337
No known key found for this signature in database
GPG Key ID: B33B5F232C6271E9
  1. 15
      contrib/android/Readme.md

15
contrib/android/Readme.md

@ -145,11 +145,26 @@ $ adb push ~/wspace/tmp/my_wallet /data/local/tmp
$ adb shell $ adb shell
adb$ ls -la /data/local/tmp adb$ ls -la /data/local/tmp
adb$ run-as org.electrum.testnet.electrum cp /data/local/tmp/my_wallet /data/data/org.electrum.testnet.electrum/files/data/testnet/wallets/ adb$ run-as org.electrum.testnet.electrum cp /data/local/tmp/my_wallet /data/data/org.electrum.testnet.electrum/files/data/testnet/wallets/
adb$ run-as org.electrum.testnet.electrum chmod -R 700 /data/data/org.electrum.testnet.electrum/files/data/testnet/wallets
adb$ run-as org.electrum.testnet.electrum chmod -R u-x,u+X /data/data/org.electrum.testnet.electrum/files/data/testnet/wallets
adb$ rm /data/local/tmp/my_wallet adb$ rm /data/local/tmp/my_wallet
``` ```
Or use Android Studio: "Device File Explorer", which can download/upload data directly from device (via adb). Or use Android Studio: "Device File Explorer", which can download/upload data directly from device (via adb).
#### Device with multiple user profiles
There are further complications if using an Android device
[with multiple user profiles](https://source.android.com/docs/devices/admin/multi-user-testing)
(typical for GrapheneOS/etc).
Run `$ adb shell pm list users` to get a list of all existing users, and take note of the user ids.
Instead of `/data/data/{app.path}`, private app data is stored at `/data/user/{userId}/{app.path}`.
Further, instead of `adb$ run-as org.electrum.electrum`,
you need `adb$ run-as org.electrum.electrum --user {userId}`.
### How to investigate diff between binaries if reproducibility fails? ### How to investigate diff between binaries if reproducibility fails?
``` ```
cd dist/ cd dist/

Loading…
Cancel
Save