CLI Guidelines – A guide to help you write better command-line programs
Hello HN!We’re Ben, Aanand, Carl, Eva, and Mark, and we made the Command Line Interface Guidelines.Earlier this year, I was working on the Replicate CLI [0]. I had previously worked on Docker so I had a bunch of accumulated knowledge about what makes a good CLI, but I wanted to make Replicate really good, so I looked for some design guides or best practices. Turns out, nothing substantial had been published since the 1980s.On this search I found a superb blog post by Carl about CLI naming [1]. He must be the only person in the world who cares about CLI design and is actually a good writer, so we teamed up. We also were joined by Aanand, who did loads of work on the Docker CLIs; Eva, who is a technical writer, to turn our scrappy ideas into a real piece of writing; and Mark, who typeset it and made a super design.We love the CLI, but so much of it is a mess and hard to use. This is our attempt to make the CLI a better place. If you’re making a tool, we hope this is useful for you, and would love to hear your feedback.Some of it is a bit opinionated, so feel free to challenge our ideas here or on GitHub! [2] We’ve also got a Discord server if you want to talk CLI design. [3][0] https://replicate.ai/[1] https://smallstep.com/blog/the-poetics-of-cli-command-names/[2] https://github.com/cli-guidelines/cli-guidelines[3] https://discord.gg/EbAW5rUCkE