Look up the right shell command by describing what you want to do in plain English without leaving the terminal
Browse StackOverflow answers for terminal commands interactively using the -s flag and spacebar navigation
Replace searching Google and clicking through Stack Overflow pages with a single terminal command
Free AI mode is limited to 5 queries per day, a paid plan is available at the project website for professional use.
how2 is a command-line tool that helps you find the right shell command without leaving your terminal. Instead of opening a browser, searching Google, and clicking through to a StackOverflow answer, you type something like how2 compress a file with tar and it shows you the command. It is designed as a natural-language alternative to man pages, the built-in Unix help system. By default, how2 sends your query to an AI server that has been trained on Bash and PowerShell commands and returns a suggestion. The AI mode is free for up to five queries per day. Adding the -s flag switches to StackOverflow search mode instead, where it fetches the top answers for your question directly. After seeing an initial result, pressing the spacebar enters interactive mode, letting you browse through multiple StackOverflow questions and answers and select the most relevant one. Installation options include Homebrew on macOS, npm (as a global install), a .deb package for Ubuntu and Debian, and prebuilt binaries for direct download. If you install via npm without administrator access, you can run it with npx how2 or set up a manual alias. Proxy environments are supported through standard HTTP_PROXY and HTTPS_PROXY environment variables. The tool works well for common shell tasks but may produce unexpected output for unusual or very specific queries. The README suggests rewording the query if the first attempt does not return a useful result, and falling back to the StackOverflow mode when the AI result is not helpful. A paid subscription tier is available at the project's website for professional users who need more than five daily queries.
← santinic on gitmyhub — every repo by this author, as a profile.
Verify against the repo before relying on details.