{"id":20961442,"url":"https://github.com/boeschj/CommandLM","last_synced_at":"2025-12-31T00:27:44.955Z","repository":{"id":261724904,"uuid":"884589542","full_name":"boeschj/ShellGPT","owner":"boeschj","description":"ShellGPT is an AI powered command-line tool that suggests and explains shell commands based on natural language queries. Perfect for those cases where you forget how to exit vim!","archived":false,"fork":false,"pushed_at":"2024-11-17T04:54:16.000Z","size":35,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-01-20T00:48:22.314Z","etag":null,"topics":["chatgpt","developer-tools","openai","productivity","shell","terminal"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":false,"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/boeschj.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}},"created_at":"2024-11-07T02:56:09.000Z","updated_at":"2024-11-17T04:54:19.000Z","dependencies_parsed_at":"2025-01-20T00:44:52.827Z","dependency_job_id":"d8a5f0af-ef82-4c75-83b5-4b55eaa17659","html_url":"https://github.com/boeschj/ShellGPT","commit_stats":null,"previous_names":["boeschj/shellgpt"],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/boeschj%2FShellGPT","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/boeschj%2FShellGPT/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/boeschj%2FShellGPT/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/boeschj%2FShellGPT/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/boeschj","download_url":"https://codeload.github.com/boeschj/ShellGPT/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243358307,"owners_count":20277996,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["chatgpt","developer-tools","openai","productivity","shell","terminal"],"created_at":"2024-11-19T02:13:37.599Z","updated_at":"2025-12-31T00:27:44.947Z","avatar_url":"https://github.com/boeschj.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# CommandLM\n\nCommandLM is an AI powered command-line tool that you can ask to suggest or explain shell commands based on natural language queries.\n\n\n## Installation\n\n### MacOS (via Homebrew)\n```bash\nbrew tap boeschj/tap\nbrew install commandlm\n```\n\n### Manual Installation (Linux/Windows)\n1. Download the appropriate binary for your system from the [releases page](https://github.com/boeschj/CommandLM/releases):\n   - Linux: `clm-linux-x86_64.tar.gz`\n   - Windows: `clm-windows-x86_64.zip`\n\n2. Extract and install:\n```bash\n# Linux\ntar xvf clm-linux-x86_64.tar.gz\nsudo mv clm /usr/local/bin/\nchmod +x /usr/local/bin/clm\n\n# Windows\n# Extract the ZIP file and add the directory to your PATH\n```\n\n## Setup\n\n1. If you don't already have an OpenAI API key, follow the setup instructions from [OpenAI](https://platform.openai.com/api-keys)\n\n2. Add your API key to your shell environment:\n```bash\n# Add this line to your shell config (~/.zshrc, ~/.bashrc, etc.)\nexport OPENAI_API_KEY='your-api-key-here'\n\n# Reload your shell configuration\nsource ~/.zshrc  # or source ~/.bashrc\n```\n\n## Usage\n\n### Get Command Suggestions\n\n#### DISCLAIMER: CommandLM generates shell commands using AI and may be inaccurate. **ALWAYS review and understand any command before executing it** and never blindly run suggested commands. You are responsible for any commands you execute.\n \n```bash\n# Ask how to perform a task\nclm \"scaffold a new react application called MyCoolApp using typescript and vite\"\n\n# Get help with complex commands\nclm \"create a tar archive and compress it\"\n# Shows: tar -czf archive.tar.gz folder/\n# Prompt: Execute this command? [y/N]\n\n# Understand what a command does\nclm \"what does chmod 755 do\"\n```\n\nCommandLM will suggest a command and ask if you want to execute it. You can safely review the command before confirming.\n\n### Interactive Chat Mode\n```bash\nclm chat\n```\n\n## Examples\n\n```bash\n$ clm chat\nStarting interactive chat session (type 'exit' to quit)\n\nYou\u003e What's the difference between chmod and chown?\nAssistant: chmod (change mode) and chown (change owner) serve different purposes...\n\nYou\u003e exit\n```\n\n## Development \u0026 Releases\n\n### Building From Source\n```bash\n# Clone the repository\ngit clone https://github.com/boeschj/CommandLM.git\ncd CommandLM\n\n# Build\ncargo build --release\n```\n\n### Creating a New Release\n\n1. Update version in `Cargo.toml`\n\n2. Create and push a new tag:\n```bash\ngit tag v0.x.x\ngit push origin v0.x.x\n```\n\n3. Wait for GitHub Actions to build and upload release artifacts\n\n4. Update Homebrew formula:\n```bash\n# Get SHA of new Mac binary\ncurl -LO https://github.com/boeschj/CommandLM/releases/latest/download/clm-mac-x86_64.tar.gz\nshasum -a 256 clm-mac-x86_64.tar.gz\n\n# Update homebrew-tap repository:\n# 1. Change VERSION in Formula/clm.rb\n# 2. Update SHA256\n# 3. Commit and push changes\n```\n\n## Gotchas/Limitations\n\n- Currently only compatible with gpt-4o-mini\n- CommandLM sends the last 5 commands from history for context - be mindful of sensitive information\n- This tool was primarily designed and tested for macOS `zsh` environments.\n\n## License\n\nMIT License - see LICENSE file for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fboeschj%2FCommandLM","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fboeschj%2FCommandLM","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fboeschj%2FCommandLM/lists"}