terminally-gpt
v1.0.14
Published
A package to generate and run terminal commands using ChatGPT
Downloads
749
Readme
About The Project
https://github.com/user-attachments/assets/78ec488c-3bfd-4cb2-9449-e85fe8f08d22
Sick of having to actually remember terminal commands? Tired of tapping the up arrow 47 times trying to find that command you ran late last Monday after way too much coffee? Fear not, because TerminallyGPT is here to rescue you from the endless grind of knowing stuff!
TerminallyGPT is a tool that leverages AI to generate and execute terminal commands for you. Simply provide a task, and it queries OpenAI's GPT to generate the correct terminal command based on your operating system. You can review the command before it’s run, ensuring control while saving time. Perfect for automating everyday tasks or handling complex terminal operations without memorizing syntax.
Built With
🚀 Installation
- Get an OpenAI API Key https://openai.com/
- Run
npx terminally-gpt
from your terminal. - Or install the package globally
npm install -g terminally-gpt
and runterminally-gpt
How to Use It
- Run package via
npx terminally-gpt
orterminally-gpt
if installed globally. - Follow the prompts from the software:
- Explain the desired task to be run in your terminal in plain English.
- Paste your OpenAI API Key when prompted.
- Accept the disclaimer and run your code.
Use Cases
- Creating a file:
"Create a text file named example.txt"
- Running a Docker container:
"Run a Docker container for PostgreSQL"
- Automate deletion of files:
"Delete all .PNG files in the current folder"
Anything that can be done with your terminal can be done with TerminallyGPT!
Roadmap
- [x] Run LLM-generated scripts in the terminal
- [x] Integrate with OpenAI API
- [x] Add Linux/Mac/Windows support
- [x] Guardrails and disclaimers for commands
- [ ] Save OpenAI API key locally
- [ ] AGI
Contributing
Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.
If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue.
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/feature-name
) - Commit your Changes (
git commit -m 'Add some feature'
) - Push to the Branch (
git push origin feature/feature-name
) - Open a Pull Request
License
Distributed under the MIT License. See LICENSE.txt
for more information.
Disclaimer
This tool generates and executes terminal commands generated by ChatGPT. Always review the commands and use them at your own risk. Ensure you have proper backups and understand the potential consequences of running commands on your system.