Skip to content

Simplify Git Commits with Penify-CLI's Commit Summary Generator โ€‹

Good commit messages are crucial for any project. They help you and your team understand why changes were made. But writing clear, informative messages can be time-consuming. That's where Penify-CLI comes in.

Penify commits

What is Penify-CLI commit summary? โ€‹

Penify-CLI is a tool that automatically generates meaningful commit messages adhering to Semantic commit message standard. It looks at your code changes and creates a summary that explains what you did and why.

How to use Penify to generate Semantic Commitย Message? โ€‹

Install โ€‹

First things first, let's get Penify-CLI installed:

bash
pip install penify-cli

Setup Environment Variables โ€‹

  • PENIFY_API_TOKEN: You can set this environment variable with your API token to avoid passing it as an argument each time. Here is the tutorial on setting env variables
bash
export PENIFY_API_TOKEN=skl_ai_******

Generate a commit summary โ€‹

  1. Go to your repository
bash
cd path/to/your/repo
  1. Make some changes and stage your changes
bash
git add /all/your/files
  1. Only after you perform git add, Penify can pick your changes to automatically generate AI summary.
bash
penify-cli commit

This command will:

  • Look at your code changes
  • Create a commit message
  • Make the commit

Penify commit docs

Customizing Your Commit โ€‹

  1. Want to provide additional context to LLMs? Use the -m flag:

    bash
    penify-cli commit -m "Focus on login feature"

    While generating commit summary it will prioritizes your commit message

  2. Need to edit the message? Use the -e flag:

    bash
    penify-cli commit -e True

    This opens your text editor so you can make changes.

    Penify commit docs

Why Use Penify-CLI? โ€‹

  1. Save Time: Write less, explain more.
  2. Be Consistent: All commit messages follow the same style.
  3. Don't Miss Details: The AI catches things you might forget.
  4. Learn: Improve your own commit writing skills.

Tips for Using Penify-CLI โ€‹

  1. Always review the generated message before committing.
  2. Use your own message (with -m) to add extra context.
  3. Make it part of your regular Git workflow.

Are there any other tools? โ€‹

Github Co-pilot has such feature but itโ€™s quite buggy and doesnโ€™t generate โ€œsemantic commit messagesโ€

Conclusion โ€‹

Penify-CLI makes writing good commit messages easy. It saves you time and helps keep your project history clear. Give it a try on your next commit!

Penify commit docs