
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
@blendsdk/git-commit-agent
Advanced tools
AI-powered git commit message generator using LangChain and OpenAI. Automatically analyzes code changes and creates conventional commit messages.
AI-powered git commit message generator using LangChain and OpenAI. Automatically analyzes code changes and creates high-quality conventional commit messages.
~/.agent-config# Using npm
npm install -g @blendsdk/git-commit-agent
# Using yarn
yarn global add @blendsdk/git-commit-agent
# Clone the repository
git clone https://github.com/blendsdk/git-commit-agent.git
cd git-commit-agent
# Install dependencies
yarn install
# Build
yarn build
# Link globally for testing
yarn link
# Navigate to your git repository
cd your-project
# Make some changes
# ... edit files ...
# Run the agent
git-commit-agent
The agent will:
Create a .env file in your project root or ~/.agent-config in your home directory:
# Required
OPENAI_API_KEY=your_openai_api_key_here
# Optional - Model configuration
OPENAI_MODEL=gpt-4
# Optional - LangChain configuration
LANGCHAIN_TRACING_V2=true
LANGCHAIN_API_KEY=your_langchain_api_key
# Optional - Commit format defaults
COMMIT_TYPE=feat
COMMIT_SCOPE=api
COMMIT_SUBJECT_MAX_LENGTH=72
COMMIT_DETAIL_LEVEL=normal
COMMIT_FILE_BREAKDOWN=true
# Optional - Behavior defaults
AUTO_STAGE=all
PUSH=false
SKIP_VERIFICATION=false
CONVENTIONAL_STRICT=true
# Optional - Execution defaults
DRY_RUN=false
VERBOSE=false
For user-wide settings, create ~/.agent-config:
# Linux/Mac
echo "OPENAI_API_KEY=your_key_here" > ~/.agent-config
# Windows
echo OPENAI_API_KEY=your_key_here > %USERPROFILE%\.agent-config
Note: Local .env files override global settings.
Configuration values are merged from three sources:
.env file)# Use default configuration
git-commit-agent
# Preview commit message without committing
git-commit-agent --dry-run
# Enable verbose output for debugging
git-commit-agent --verbose
# Get help
git-commit-agent --help
# Show version
git-commit-agent --version
--commit-type <type>
Force a specific commit type instead of letting the agent determine it.
Choices: feat, fix, refactor, docs, test, build, ci, perf, style, chore
git-commit-agent --commit-type feat
--scope <scope>
Set the commit scope (e.g., auth, api, ui).
git-commit-agent --scope auth
--subject-max-length <number>
Maximum length for the commit subject line (default: 72).
git-commit-agent --subject-max-length 50
--detail-level <level>
Control the level of detail in the commit message body.
Choices: brief, normal, detailed (default: normal)
brief: Minimal description (1-2 sentences)normal: Standard description with key changesdetailed: Comprehensive description with file-by-file breakdowngit-commit-agent --detail-level detailed
--file-breakdown / --no-file-breakdown
Include or exclude file-by-file breakdown in the commit body (default: true).
git-commit-agent --no-file-breakdown
--auto-stage <mode>
Control automatic staging behavior before commit.
Choices: all, modified, none (default: all)
all: Stage all changes including untracked files (git add .)modified: Stage only modified and deleted files (git add -u)none: Don't stage anything, commit only what's already stagedgit-commit-agent --auto-stage modified
--push
Push changes to remote repository after committing (default: false).
When this flag is set, the system will automatically push the commit to the remote repository after successfully committing locally. Without this flag, commits remain local only.
git-commit-agent --push
--no-verify
Skip commit verification hooks (pre-commit, commit-msg) (default: false).
git-commit-agent --no-verify
--conventional-strict
Enforce strict conventional commit format (default: true).
git-commit-agent --conventional-strict
--dry-run
Analyze changes and generate commit message without actually committing (default: false).
git-commit-agent --dry-run
--verbose
Enable verbose logging to see detailed execution information (default: false).
git-commit-agent --verbose
--config <path>
Path to custom configuration file (future feature).
git-commit-agent --config ./custom-config.json
# Use all defaults
git-commit-agent
# Preview commit message without committing
git-commit-agent --dry-run
# Enable verbose output for debugging
git-commit-agent --verbose
# Force specific commit type and scope
git-commit-agent --commit-type feat --scope auth
# Brief commit message without file breakdown
git-commit-agent --detail-level brief --no-file-breakdown
# Detailed commit with longer subject line
git-commit-agent --detail-level detailed --subject-max-length 100
# Quick fix with minimal detail
git-commit-agent --commit-type fix --detail-level brief
# Stage all files including untracked (default)
git-commit-agent --auto-stage all
# Only stage modified files
git-commit-agent --auto-stage modified
# Only commit already staged files
git-commit-agent --auto-stage none
# Complete workflow: stage all, commit, and push
git-commit-agent --auto-stage all --push
# Complete workflow: stage all and commit (without pushing)
git-commit-agent --auto-stage all
# Skip pre-commit hooks
git-commit-agent --no-verify
# Dry run with verbose output to see what would happen
git-commit-agent --dry-run --verbose
# Feature commit with detailed breakdown
git-commit-agent --commit-type feat --scope api --detail-level detailed
# Consistent brief commits for the team
git-commit-agent --detail-level brief --subject-max-length 50
# Detailed commits for major features
git-commit-agent --detail-level detailed --commit-type feat
# Quick fixes without verification
git-commit-agent --commit-type fix --no-verify --detail-level brief
For rapid development with minimal commit messages:
git-commit-agent --detail-level brief --no-file-breakdown
Or in .env:
COMMIT_DETAIL_LEVEL=brief
COMMIT_FILE_BREAKDOWN=false
AUTO_STAGE=all
For comprehensive commit history:
git-commit-agent --detail-level detailed --file-breakdown --subject-max-length 72
Or in .env:
COMMIT_DETAIL_LEVEL=detailed
COMMIT_FILE_BREAKDOWN=true
COMMIT_SUBJECT_MAX_LENGTH=72
For automated commits in CI/CD:
git-commit-agent --auto-stage all --no-verify --push --detail-level normal
Or in .env:
AUTO_STAGE=all
SKIP_VERIFICATION=true
PUSH=true
COMMIT_DETAIL_LEVEL=normal
The agent generates commit messages following the Conventional Commits specification:
<type>(<scope>): <subject>
<body>
<footer>
| Type | Description |
|---|---|
feat | New feature |
fix | Bug fix |
docs | Documentation changes |
style | Code style changes (formatting) |
refactor | Code refactoring |
perf | Performance improvements |
test | Adding or updating tests |
build | Build system changes |
ci | CI configuration changes |
chore | Other changes |
feat(auth): add OAuth2 authentication support
- Implement OAuth2 flow with Google and GitHub providers
- Add token refresh mechanism
- Create user session management
- Update authentication middleware to support OAuth tokens
This enables users to sign in using their existing social accounts,
improving user experience and reducing friction in the signup process.
Closes #234
Make sure you're in a git repository:
git init # If starting a new repo
Set your API key:
export OPENAI_API_KEY=your_key_here
# Or add to .env file
Make sure you have uncommitted changes:
git status # Check for changes
Reduce --subject-max-length or use --detail-level brief:
git-commit-agent --subject-max-length 50 --detail-level brief
Use --auto-stage none and manually stage files first:
git add file1.js file2.js
git-commit-agent --auto-stage none
Use --no-verify to skip hooks (use cautiously):
git-commit-agent --no-verify
Use --verbose and --dry-run together:
git-commit-agent --verbose --dry-run
# Clear node_modules and reinstall
rm -rf node_modules yarn.lock
yarn install
yarn build
.env for team defaults: Set common configuration in .env and commit it to your repository--dry-run to preview the commit message before committing--verbose when troubleshooting issuesbrief for small changes, detailed for major featuresISC License - see LICENSE file for details.
For issues, questions, or contributions, please visit the GitHub repository.
Note: Remember to replace repository URLs with your actual GitHub repository.
FAQs
AI-powered git commit message generator using LangChain and OpenAI. Automatically analyzes code changes and creates conventional commit messages.
The npm package @blendsdk/git-commit-agent receives a total of 2 weekly downloads. As such, @blendsdk/git-commit-agent popularity was classified as not popular.
We found that @blendsdk/git-commit-agent demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.