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

JSON format for import needs documenting #787

Open
n8willis opened this issue Oct 8, 2024 · 2 comments
Open

JSON format for import needs documenting #787

n8willis opened this issue Oct 8, 2024 · 2 comments

Comments

@n8willis
Copy link

n8willis commented Oct 8, 2024

I'm interested in importing some link sets that are exported by other applications (think, for example, "starred repos on GitHub" or bookmarked posts from your social network of choice). Those tend to come in whatever format that the upstream vendor feels like producing, but in most cases JSON is an option.

However, it seems like buku's -i import feature has some expectations about how the JSON files it imports ought to be arranged. I presume it's looking for something like the browsers export, but I don't find documentation anywhere that says what structure it actually wants.

If the necessary JSON structure for import is documented, then at least we could transform the from-elsewhere exported file into something useful (or, you know, long term maybe add support for importing it natively, if it's popular enough)....

@LeXofLeviafan
Copy link
Collaborator

LeXofLeviafan commented Oct 8, 2024

Currently when importing from JSON file, buku expects it to be a Firefox backup file.

(It would make sense to support the output format used by --json, and/or the Chrome bookmarks file format used during automatic import, but there's no such code as of yet)

@LeXofLeviafan
Copy link
Collaborator

Those tend to come in whatever format that the upstream vendor feels like producing, but in most cases JSON is an option.

I doubt these are all using the same exact JSON scheme, so you're likely going to have to convert these files anyway.

The simplest solution might be to use markdown (* [title](url) <!-- TAGS: tags -->... description not supported though).

P.S. If I end up implementing a plugin system for buku as I was planning to, it might be possible to support whatever import formats you like using those… but that's still at the draft stage for now.

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

No branches or pull requests

2 participants