Skip to content
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

Provide KStore initialiser for implicit storage directories #121

Open
xxfast opened this issue Sep 9, 2024 · 1 comment
Open

Provide KStore initialiser for implicit storage directories #121

xxfast opened this issue Sep 9, 2024 · 1 comment
Labels
enhancement New feature or request

Comments

@xxfast
Copy link
Owner

xxfast commented Sep 9, 2024

Similar to kable, perhaps we can initialise the store's file implicitly to simplify the store creation for users

Docs: https://developer.android.com/topic/libraries/app-startup

@xxfast
Copy link
Owner Author

xxfast commented Oct 23, 2024

Hmm.. So I thought I had a nice solution for this with Androidx Startup, however it is not quite so straightforward

This is because the Context available for the Initializer doesn't give access to the same filesDir

context.filesDir           = /data/user/0/io.github.xxfast.nytimes.android/files
defaultDirectory.files     = /.local/share/io.github.xxfast.kstore

So that's a problem 🤔

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant