Crates.io | gcm-ai |
lib.rs | gcm-ai |
version | 0.1.7 |
source | src |
created_at | 2023-02-17 21:49:57.796424 |
updated_at | 2023-03-29 01:42:23.340079 |
description | GCM-AI is a command-line tool that generates commit messages based on the diff of staged changes using OpenAI. |
homepage | |
repository | https://github.com/OLoKo64/gcm-ai |
max_upload_size | |
id | 787796 |
size | 52,323 |
GCM-AI
is a command-line tool that generates commit messages based on the diff of staged changes using OpenAI.
This app inspired by aicommits with some tweaks and written in Rust.
To install GCM-AI, you will need to have Rust installed on your system. You can install Rust by following the instructions here.
Once Rust is installed, you can install GCM-AI by running the following command:
cargo install gcm-ai
To generate a commit message for the staged changes, simply run the following command:
gcm-ai
This will generate a commit message using OpenAI's GPT-3 language model and print it to the console. You can then copy and paste the generated commit message into your git commit.
GCM-AI uses the OpenAI API to generate commit messages. To use the OpenAI API, you will need an API key. You can get an API key by signing up for OpenAI here.
Please note that OpenAI is currently in beta, and the API is not free. But for now when you sign up, you will get $18 of free credits to use on the API, which should be enough to generate enough commit messages as the generated commit messages are very cheap.
Once you have an API key, you can configure GCM-AI to use it by running the following command:
gcm-ai --config
This will prompt you for your OpenAI API key. Once you enter your API key, it will be saved to a .toml
configuration file in your home directory.
Contributions are welcome! If you would like to contribute to GCM-AI, please open a pull request.
GCM-AI is licensed under the MIT License. See the LICENSE file for more information.