-
Notifications
You must be signed in to change notification settings - Fork 369
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement Backup & Restore #2302
base: main
Are you sure you want to change the base?
Conversation
@@ -14,3 +14,4 @@ org.gradle.unsafe.configuration-cache=true | |||
voice.signing.play=false | |||
kotlin.daemon.useFallbackStrategy=false | |||
org.gradle.kotlin.dsl.allWarningsAsErrors=true | |||
org.gradle.jvmargs=-Xmx2g |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this was required for me to be able to build the project the first time, but I can back it out if you want
Yeah, good to know this isn't implemented yet. Too bad I can't see the reading positions on my old phone, since the SD card that had the books on it has been moved to the new phone already. So I'm SOL I guess. So I guess I should ask if this pull request backs up and restores the reading positions even for books that are no longer available on the device? |
@jgilmore I believe it does |
Thanks for the effort to implement a manual backup/restore! First, is Android's Auto Backup implemented? |
doesn't seem to have worked when I moved to a new phone the most recent time |
Is it set in the manifest? |
as requested in #1668 and #2103
I'm quite interested in being able to transfer read information, as I'm switching to a new phone and am in the middle of quite a few books 😅
NB I haven't written very much kotlin, so it's entirely likely that I've organized things weirdly. Let me know how you'd like things to be rearranged! I was pretty much just blundering around to get it to compile & work 🙃
But at the end of the day, it does work! I based my implementation fairly loosely on https://stackoverflow.com/a/73205884/290784. I'm exporting the whole sqlite file (including journaling files) as a .zip archive, and then to restore, I overwrite whatever sqlite database exists & restarting the app.
(It might be worth putting up an alert or something saying "Restoring will delete all your current data!" but I wasn't sure how to make an alert)
Here's a video of it in action:
https://github.com/PaulWoitaschek/Voice/assets/112170/d512e8b8-2762-4945-8a54-11ac84c3c952