{"id":29826635,"url":"https://github.com/mbrt/gencmd","last_synced_at":"2026-05-16T22:02:51.793Z","repository":{"id":305707268,"uuid":"1021510474","full_name":"mbrt/gencmd","owner":"mbrt","description":"Generate bash commands from natural language directly in the console","archived":false,"fork":false,"pushed_at":"2026-05-16T00:29:05.000Z","size":348,"stargazers_count":8,"open_issues_count":3,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-05-16T02:56:27.655Z","etag":null,"topics":["ai","bash","go"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mbrt.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":"AGENTS.md","dco":null,"cla":null}},"created_at":"2025-07-17T14:01:29.000Z","updated_at":"2026-02-01T15:05:22.000Z","dependencies_parsed_at":"2025-07-21T16:43:40.164Z","dependency_job_id":"eba8731f-9e8a-4380-9f51-f282ab5c076f","html_url":"https://github.com/mbrt/gencmd","commit_stats":null,"previous_names":["mbrt/gencmd"],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/mbrt/gencmd","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mbrt%2Fgencmd","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mbrt%2Fgencmd/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mbrt%2Fgencmd/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mbrt%2Fgencmd/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mbrt","download_url":"https://codeload.github.com/mbrt/gencmd/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mbrt%2Fgencmd/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33120450,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-16T18:38:32.183Z","status":"ssl_error","status_checked_at":"2026-05-16T18:38:29.903Z","response_time":115,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ai","bash","go"],"created_at":"2025-07-29T05:10:21.232Z","updated_at":"2026-05-16T22:02:51.788Z","avatar_url":"https://github.com/mbrt.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# gencmd\n\n[![Build](https://github.com/mbrt/gencmd/actions/workflows/build.yml/badge.svg)](https://github.com/mbrt/gencmd/actions/workflows/build.yml)\n[![Go Report Card](https://goreportcard.com/badge/github.com/mbrt/gencmd)](https://goreportcard.com/report/github.com/mbrt/gencmd)\n\ngencmd is an interactive command line utility to generate bash commands from a\nnatural language description, directly from the console.\n\n[![asciicast](https://asciinema.org/a/QoGh9TXk3GMcyP4FmWyh2iUqH.svg)](https://asciinema.org/a/QoGh9TXk3GMcyP4FmWyh2iUqH)\n\nEver went to ChatGPT after struggling some time with `man awk`, or with\nquestions like \"was it `curl` or `wget` with `-O`\"? Well, save some time and ask\ndirectly from the terminal. Think of this as the\n[fzf](https://github.com/junegunn/fzf) for natural language to bash commands.\n\n## Why?\n\nThere are many alternative tools for this task, but none did all I wanted:\n\n* Simple to install and configure (i.e. single binary, no dependencies).\n* Work interactively in the terminal, but require minimal typing.\n* Fast.\n* *Do not* run commands for me, but suggest alternatives.\n* Paste the result directly in the terminal (without me having to do it).\n* Have built-in history for both commands and prompts.\n* Open source, no sign-up required, no strings attached.\n\nThis project is minimal but provides all of the above.\n\n## Installation\n\nHead over to the\n[latest release](https://github.com/mbrt/gencmd/releases/latest), and download a\nbinary appropriate for your system.\n\nMake it executable and put it somewhere in `$PATH`:\n\n```sh\nchmod a+x gencmd\nsudo mv gencmd /usr/local/bin\n```\n\nIf you want to set up key bindings (default is \u003ckbd\u003eCtrl\u003c/kbd\u003e + \u003ckbd\u003eG\u003c/kbd\u003e),\nadd this to your `.bashrc`:\n\n```sh\nsource ~/.config/gencmd/key-bindings.bash\n```\n\nor use `key-bindings.zsh` for `.zshrc`.\n\n## API Keys\n\nInitialize with:\n\n```sh\ngencmd init\n```\n\nThe instructions will guide you through setting up an AI model provider. The\ncurrently supported providers are OpenAI, Gemini, Anthropic, and Ollama.\n\nThe easiest to get started is to get a free API key from [Google AI\nStudio](https://aistudio.google.com/apikey). Follow the instructions there and\nonce you have the key, paste it into the interactive prompt.\n\nFor local models, you can use [Ollama](https://ollama.ai). First install Ollama\nand pull a model (e.g., `ollama pull gemma-3`), then configure gencmd to use it.\n\nCredentials are stored locally, and NEVER sent anywhere else.\n\n\u003e [!NOTE]\n\u003e By default, `gencmd` uses \"gemini-2.5-flash-lite\", which has a generous free\n\u003e tier of 200 requests per day. More than enough for typical usage. If you want\n\u003e to make sure to block requests over the free tier, use a dedicated GCP project\n\u003e without billing enabled.\n\n\u003e [!TIP]\n\u003e If you just want to test how `gencmd` looks without configuring it, you can\n\u003e try the demo (returning fake history and commands) with `gencmd demo`.\n\n## Usage\n\nThink of this as [fzf](https://github.com/junegunn/fzf) for natural language to\nbash commands. Open a new terminal and press \u003ckbd\u003eCtrl\u003c/kbd\u003e + \u003ckbd\u003eG\u003c/kbd\u003e.\nAs you type your query, `gencmd` will filter your recent history, so you can\neither select something from there, or submit a new prompt.\n\nIn case the prompt is new, your configured LLM will be invoked to generate a few\nalternative commands to solve your intended usage.\n\nYou can navigate history and completions with keyboard arrows \u003ckbd\u003e↑\u003c/kbd\u003e\n\u003ckbd\u003e↓\u003c/kbd\u003e, or \u003ckbd\u003eCtrl\u003c/kbd\u003e + \u003ckbd\u003eJ\u003c/kbd\u003e and \u003ckbd\u003eCtrl\u003c/kbd\u003e +\n\u003ckbd\u003eK\u003c/kbd\u003e.\n\nThe result is *not executed*, but pasted into your command line, so that you\ncan edit it.\n\nExamples for inspiration:\n\n* Find all subdirectories\n* Count the lines of a file that don't start with #\n* Delete a remote git tag\n\n## Building from source\n\nThis project is written in [Go](https://go.dev):\n\n```sh\ngit clone https://github.com/mbrt/gencmd\ncd gencmd\ngo build .\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmbrt%2Fgencmd","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmbrt%2Fgencmd","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmbrt%2Fgencmd/lists"}