-
Notifications
You must be signed in to change notification settings - Fork 425
feat(fs): resolve content URIs on Android #1658
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
feat(fs): resolve content URIs on Android #1658
Conversation
Package Changes Through 81dbaa5There are 5 changes which include dialog with prerelease, dialog-js with prerelease, global-shortcut with prerelease, fs with prerelease, single-instance with prerelease Planned Package VersionsThe following package releases are the planned based on the context of changes in this pull request.
Add another change file through the GitHub UI by following this link. Read about change files or the docs at github.com/jbolda/covector |
Sorry. |
New and removed dependencies detected. Learn more about Socket for GitHub ↗︎
🚮 Removed packages: npm/@tauri-apps/[email protected]), npm/@unocss/[email protected]), npm/[email protected]), npm/[email protected]) |
I've pushed a change to extend the approach for more file APIs (all the read, write, open APIs). We should add dedicated Android APIs for the other functions (reading a directory, renaming files, copying, etc). |
This is exciting!! |
* Implemented writeTextFile on Android. * Added license headers. * fix fmt checks. * implement more file APIs * change file * cleanup * refactor dialog plugin to leverage new FS APIs * implement metadata functions * fix build * expose FS rust API * resolve resources on android * update pnpm * update docs --------- Co-authored-by: Lucas Nogueira <[email protected]>
This is part of #1494. (Implementation of write text file for Android)
Separated #1591 for each plugin change.
NOTE: Please this PR merge after #1657
I implemented the save_text_file for the fs plugin.
As mentioned in the following two comments, saving files on Android requires the use of
activity.getContentResolver().openOutputStream(uri)
, so I use Uri instead of file path in the communication between the app and the plugin.Since the fs plugin requires the use of
activity.getContentResolver().openOutputStream(uri)
, I've added an Android implementation to the fs plugin.