Use your own spell against you.
- Ruby 2.6 or later
- An OpenAI API key
Install the aicommit gem:
gem install aicommit
To upgrade to the latest version of AICommit, run:
gem update aicommit
To generate a commit message based on the changes in your Git repository:
-
Run the following command at the root of your project:
aicommit
-
The AI model will generate a commit message based on the changes in your Git repository.
-
Review the generated commit message.
-
To commit the staged changes with the generated commit message, enter Y at the prompt. To regenerate a new commit message, enter R. To enter a new commit message by yourself, enter N. To quit without committing, enter Q.
To set your OpenAI API key manually, run the following command:
aicommit --config
Get your API key from https://beta.openai.com/account/api-keys
To show the version of AICommit, run the following command:
aicommit --version
AICommit uses OpenAI's GPT-3.5 AI model to generate commit messages based on the changes in your Git repository.
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
Please make sure to update tests as appropriate.
This project is licensed under the MIT License - see the LICENSE.md file for details.