If you try to be offline as much as possible, backing up an
Android
phone
before an upgrade or phone change is not quite as easy.
As a start, try a non-Google
Android contact
From the file system starting at /sdcard, copy
Books, DCIM, keepass,
Kiwix (large, contains wikipedia),
Music, noteeverything,
OpenKeychain.
From /sdcard/Android, copy
com.fsck.k9, de.hafas,
de.schildbach.,
de.softxperience,
net.osmand (large, contains maps),
org.kiwix,
org.thoughtcrime,
uk.co.nickfines,
uk.co.olilan.
After (re-)installing the apps, see which files you can overwrite.
For Signal,
choose "Import/Export->/sdcard.
Restore with "Import plaintext backup".
For K-9 mail,
go to accounts view (the first one; just do not be in "Unified
Inbox" or in one of the accounts) and choose "Settings Import &
Export->Export settings and accounts". This gives a file
/sdcard/com.fsck.k9.
Restore with "Settings Import & Export->Import settings".
For OpenKeychain,
choose "Top left->/sdcard.
Restore with "Backup/Restore->
For Note Everything,
choose "More->Export textnotes to SD-Card".
This gives files text[1-99]_
in /sdcard. Restore with
"More->
To see the Android files in the folder view of the PC, you need to reboot the phone, then reconnect.
For OSMAnd,
choose "My Places->favourites.gpx. Restore with a file explorer,
clicking the gpx file should given an "Open with OSMAnd" choice.
For the settings, adb backup -f osm.ab net.osmand.plus -apk,
restore with adb restore osm.ab
[forum].
Sometimes when you have a new phone,
an app will have vanished from
f-droid
or
gplay.
Assuming compatibility to the new android version, and an
adb connection
you can download any installed apk package
[forum]
though it is a bit convoluted.
First search for the internal app name (Java package name),
here "music" since I wanted an older "music player" app.
adb shell pm list packages |grep music
package:com.hmct.music
package:com.maxfour.music
package:com.android.einklauncher.plugin.musicplugin
Either by guessing or trying each, I found that
com.maxfour.music is the one I want.
Since the apk location is secret,
we have to find out:
adb shell pm path com.maxfour.music
package:/data/app/com.maxfour.music-miUMPl8eDqTvVOw-TRzmOQ==/base.apk
And finally we can download the package:
adb pull /data/app/com.maxfour.music-miUMPl8eDqTvVOw-TRzmOQ==/base.apk
The downloaded file name is always the same base.apk,
so remember to rename the apk
before starting the next download.
There, go ahead now, upgrade your phone. Good luck :)
EOF (Apr:2021)