Ask HN: CLI design of import/export commands
2 pointsby mlawren2 comments
prog help [COMMAND...]
prog init [DIRECTORY]
prog import HUB [PATHS...]
prog new ITEM
prog new project [PATH] [TITLE...]
prog new task [PATH] [TITLE...]
prog new issue [PATH] [TITLE...]
prog list ITEMS
prog list topics
prog list projects
prog list project-states PATH
prog list task-states PATH
prog list issue-states PATH
prog list hubs
prog show ID
prog log [ID]
prog comment ID
prog drop ID
prog push ID PATH [HUB]
prog export PATH HUB
prog sync [ID] [HUB]
prog upgrade [DIRECTORY]
prog sql STATEMENT...
prog ALIAS
At the moment PATH is the way to reference a project.
Of all of the formats I looked at nothing matched. So I created Bifcode [https://metacpan.org/pod/Bifcode]. It is a bit of a mix between Netstrings, Bencode and JSON. It is not really human readable, but it is extremely simple and robust, easy to generate and parse, and therefore relatively secure.
I'm not promoting it for any particular use case, and I only have a Perl implementation. Posting here as I think some of the audience in this thread may find it useful.