-
Notifications
You must be signed in to change notification settings - Fork 216
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
add OpenTimestamps file parser #769
Conversation
Your welcome to add URLs to code etc you used as reference to the top of ots.go or to a ots.md file, also you might want a ots.md file in any case, example file https://github.com/wader/fq/blob/master/format/bson/bson.md and see bson.go about embedding it to have cli help also. And you can use
🥳 hope it gave some good tips at least
I add a code comment about how automatic detection works. It's is currently solely done on content, maybe in the future a decoder will get access to the filename somehow BTW the CI error seems to be that a common format test i failing, can updated using |
c82c3e0
to
5e7c01a
Compare
I think I got it all now. I don't know what to put on an I don't have a use case for filtering through these files actually, my initial reason for implementing this was to be able to "see" the entire file in one go, not so much to dig into its sections and so on. |
👍
You can put a author section, links to references, examples and such, but it's optional. You can show format help with
Ok! but i think it's good to sym map numbers etc to human friendly things, not only for queries but also for when turning it into JSON. |
Overall it looks good now i think, had just one comment and maybe if you want some documentation. Otherwise i'm ready to merge |
c19f9e8
to
64a4ff2
Compare
Ready to merge? |
0ab70f6
to
912f411
Compare
Should be ready now. Added the doc file with some simple examples. |
Do one last |
Thanks! |
Thank you very much for merging and for your patience! |
No worries! also reminded me that i should look into minimizing number files needed to change to add a format |
https://opentimestamps.org/ (there is no spec or docs about the file format in this website, only libraries).
This is my first time contributing and I don't know if I did this right. I did read the developer guide.
One thing I wanted to know is how to make
.ots
files be detected automatically. They have this clear extension in their filenames and also an obvious sequence "magic bytes" at their beginning, so it should be pretty easy to detect without having to parse them entirely.