1.0.5 • Published 3 years ago
ryan-test2 v1.0.5
Update December 12, 2022
OpenAI added additional Cloudflare protections that make it more difficult to access the unofficial API. The tool is not working temporary until I find a way to workaround it.
More details in the issue.
commitgpt
Automatically generate commit messages using ChatGPT.

How to use?
npx commitgptor use -c for conventional commits format.
npx commitgpt -cOn the first run you will be asked to enter your OpenAI session token.
Get your session token
- Go to https://chat.openai.com/chat and log in or sign up.
- Open console with
F12. - Open
Application>Cookies.
- Copy the value for
__Secure-next-auth.session-tokenand paste it into the terminal prompt.
How it works
- Runs
git diff --cached - Sends the diff to ChatGPT and asks it to suggest commit messages
- Shows suggestions to the user
Credits
Some code and approaches were inspired by the awesome projects below:
- https://github.com/acheong08/ChatGPT
- https://github.com/transitive-bullshit/chatgpt-api
- https://github.com/wong2/chat-gpt-google-extension
Do you need API docs? Check out Redocly.
1.0.5
3 years ago