-
Notifications
You must be signed in to change notification settings - Fork 7
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
Save files in picked directory #6
Comments
Hello, thanks a lot for the sweet words!🌟 Unfortunately, I just noticed that it is missing this functionality. But hey, adding it seems easy, and it's an important feature. I'll look into it, and if everything goes well, I'll have it ready in a few days. Thanks a lot for bringing this issue up. |
Thank you so much for your nice reply :D I'd love to help implement this / similar operations but unfortunately I (as of yet) don't know how android native code works ^^' If there is anything on the Dart / Flutter side you'd like help with, I'll gladly try my best :) |
Hello @florian-obernberger , Sorry for the delayed update; I've been busy with other tasks and forgot about this. But finally, I implemented this in the plugin. To test it, you can use the GitHub project as a dependency: dependencies:
pick_or_save:
git:
url: https://github.com/chaudharydeepanshu/pick_or_save.git Example dart code: // Picking Directory
String? pickedDirectoryUri = await PickOrSave().directoryPicker(
params: DirectoryPickerParams()
);
// Saving to picked directory
List<String>? result = await PickOrSave().fileSaver(
params: FileSaverParams(
saveFiles: [
SaveFileInfo(
filePath: filePath,
fileName: "File.png")
],
directoryUri: pickedDirectoryUri, //<---------- New parameter for saving to the picked directory directly
)
);
String savedFilePath = result[0]; You can also run the example app to test it: I will test it and clean up the old code before publishing it on pub.dev in a few days. So, please feel free to give it a try and let me know your feedback. Thank you for your patience and support. |
Thank you so much!! I will test it out in the coming test and let you know if any problems arise :) |
So, I finally came around to testing it and I found one bug / issue: Even when called only once the same file is often saved multiple times resulting in not just Is there something I missed? Should I close this issue and create a separate one? Also thanks again for this amazing plugin! |
Thanks for testing it! Finally got some time to re-work the whole old code and fix all known issues. I'll roll a pre-release by maybe tomorrow! Also, we will track it here until it's bug-free. |
Hey there! First of all thank you for this lovely package! So far it works absolutely flawless!
I just have one question: How can I save files to a persistent directory that the user chose?
I would like to auto-export backup files into the folder and asking the user every time for that would kind off defeat the purpose of auto backups... So: Is there any way to save files to the picked directory? If I overlooked it in the documentation I apologize and thanks in advance for your response!
The text was updated successfully, but these errors were encountered: