-
-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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: Export all user Memos as a .zip of Markdown files #2757
Conversation
Thanks for the PR, there are some points I would like to clarify about import/export:
So I don't think we need to do export in UI. Are there any other reasons about this feature? @nalderto |
For example, Joplin has this functionality I foresee a separate tab in Settings for Import/Export instead of always having it in "My Account", however since we would only have export functionality at the moment, I figured "My Account" is fine for now. |
Not the same as Joplin, memos is deployed by someone and can be used by others. In case one user has a large amount of data, it may take up a lot of resources when exporting or even cause the service to hang. So perhaps export should be an administrator's function. |
That's fair, although with the infrequency of exports occurring and friends/family use case of Memos, I don't see that being a major issue. Making it an admin only is better than nothing, although that makes it difficult to export other users' data. The file creation is all done in memory, so I would hope that performance wouldn't be impacted significantly with an export |
SGTM. It's better to use APIv2(protobuf + gRPC) to implement the export api instead of the deprecated one. |
Gotcha! I wasn’t sure if I should use v1 or v2. I can re-implement this with the v2 API in a couple weeks if you’d like. |
Merging the PR is highly advisable for those like me needing reliable export features. I frequently use Obsidian and various other note-taking apps for my day-to-day tasks, and for quick notes, I turn to Memos because it's incredibly user-friendly & handy. In this case, I aim to export my memos to a local storage solution to unify all my notes in a single location. Having this export capability is a critical requirement for me. Previously, before the Open API was phased out, I could export all my memos seamlessly using the memos-export service. Regrettably, this is no longer possible. |
I can backup database files, but the database files are very inconvenient for further interactions with notes. I think we can not implement the import function, but the export function is necessary. There are already many users requesting a similar function in GitHub Issues, I hope it can be implemented. |
thank you for your work.Memos as a distributed platform, I believe the export/import feature is very important, users can freely migrate to another site. thank you again. |
I'm closing this PR, because I made a new PR to implement the streaming gRPC endpoint to download the zip folder. |
This PR adds an "Export Memos" button to the Setting => My Account page. This will download a zip folder, generated by the server, containing all of the user's Memos in Markdown files. The individual memos filenames are named after their creation date in RFC3339 format. This PR is should partially address this open enhancement to improve exports with Memos.
I also resolved some memory leaks with downloading images and files in the share dialog.