Version Control Integration
Working with Git and other version control systems
Verdent for VS Code integrates seamlessly with Git and other version control systems, enabling natural language version control operations, automated commit message generation, and intelligent branch management. This guide shows you how to leverage Verdent's Git integration for efficient version control workflows.
Creating Meaningful Commit Messages
Suppose you've made changes and want Verdent to generate a descriptive commit message.
Request commit with generated message
Stage all changes and create a commit with an appropriate messageVerdent analyzes your changes using git diff.
Verdent analyzes changes
Verdent examines:
- Files modified and their purpose
- Nature of changes (new feature, bug fix, refactoring)
- Scope of impact
- Related functionality
Generates descriptive commit message
git commit -m "feat: add user profile image upload with S3 integration
- Add file upload endpoint to user API
- Integrate AWS S3 for image storage
- Update user model with profileImage field
- Add frontend image upload component with preview"Message follows conventional commit format and describes what changed.
Commit is created
Changes are committed with the generated message. You can review the commit:
git log -1Tips:
- Verdent follows conventional commit formats (feat, fix, refactor, docs, etc.)
- Commit messages focus on "what" and "why", not "how"
- You can customize commit message format in User Rules or Project Rules
- Request specific commit message styles: "Create a commit with a detailed multi-line message"
Customizing Commit Message Formats
Suppose you want Verdent to follow your team's specific commit message conventions.
Define commit message preferences in VERDENT.md for all projects:
# VERDENT.md
## Git Commit Messages
When generating commit messages:
- Always include ticket number in format: [PROJ-123]
- Use present tense verbs
- Maximum 50 characters for first line
- Include detailed explanation in body
- Add "Co-authored-by" for pair programming sessions
Example format:
[PROJ-123] Add user authentication feature
Detailed explanation of changes...
Co-authored-by: Team Member <email@example.com>Verdent follows these rules globally.
Define project-specific commit conventions in AGENTS.md:
# AGENTS.md
## Git Commit Conventions
For this project, use conventional commits with these scopes:
- feat(api): API changes
- feat(ui): Frontend changes
- fix(auth): Authentication fixes
- docs(readme): Documentation updates
Always reference GitHub issue: "Fixes #123" or "Relates to #456"Rules apply only to this project.
Provide one-time instructions directly:
Create a commit with message format: "[TICKET-NUMBER] description" including reference to issue #42Verdent generates:
git commit -m "[PROJ-42] Add search functionality
Relates to #42"Tips:
- User Rules apply globally across all projects
- Project Rules (AGENTS.md) override User Rules for specific projects
- Inline instructions override both for one-time needs
- Conventional Commits format is recommended for consistency
Creating Pull Requests
Suppose you want Verdent to create a comprehensive pull request.
Ensure changes are committed
Make sure all my changes are committedVerdent checks git status and commits any uncommitted changes.
Push branch to remote
Push this branch to originVerdent pushes:
git push origin feature/user-notificationsRequest PR creation
Create a pull request for this featureVerdent uses gh CLI to create PR.
Verdent generates PR description
Verdent analyzes commits and changes to generate:
Title: Add user notification system
Body:
## Summary
- Implements real-time user notifications
- Adds WebSocket support for instant delivery
- Includes email fallback for offline users
- Comprehensive test coverage
## Test Plan
- [ ] Test real-time notifications in browser
- [ ] Verify email fallback for offline users
- [ ] Check notification persistence across sessions
- [ ] Test with multiple concurrent users
## Changes
- Added NotificationService with WebSocket integration
- Created notification UI components
- Integrated SendGrid for email notifications
- Added notification preferences to user settingsThe PR is created with a comprehensive description.
Tips:
- Verdent analyzes all commits in the branch to generate PR description
- Request specific PR formats: "Create a PR with detailed test plan"
- Include screenshots: "Add this screenshot to the PR description"
- You can refine PR description before creation: "Update the PR to mention the breaking change"
Resolving Merge Conflicts
Suppose you encounter merge conflicts and need Verdent's help resolving them.
Attempt merge
Merge main into this feature branchMerge conflict occurs:
Auto-merging src/auth.ts
CONFLICT (content): Merge conflict in src/auth.tsRequest conflict resolution
Help me resolve the merge conflict in src/auth.tsVerdent reads the conflict markers.
Verdent analyzes both versions
Verdent examines:
- Current branch changes (HEAD)
- Incoming changes (main branch)
- Context around conflicts
- Intent of both changes
Verdent proposes resolution
The conflict is between your JWT implementation and the main branch's session-based auth. I'll merge both approaches to support both authentication methods.Verdent resolves the conflict by integrating both changes intelligently.
Mark conflict as resolved
git add src/auth.ts
git commit -m "Merge main into feature/jwt-auth, resolved conflicts"The conflict is resolved and the merge is complete.
Tips:
- Verdent understands code context to resolve conflicts intelligently
- Always review conflict resolutions before committing
- For complex conflicts, ask Verdent to explain both versions first
- Test thoroughly after resolving conflicts
Verdent analyzes merge conflicts by understanding both branches' intent, suggesting resolutions that preserve functionality from both sides.
Managing Branches and Tags
Suppose you need to manage branches and create release tags.
Create and switch branches:
Create a new branch called feature/user-notificationsVerdent executes:
git checkout -b feature/user-notificationsgit checkout maingit checkout -b feature/payment-integration
git push -u origin feature/payment-integrationMerge feature branches:
Merge the feature/user-notifications branch into mainVerdent performs the merge workflow:
git checkout main
git pull origin main
git merge feature/user-notifications
git push origin mainVerdent ensures main is up-to-date before merging.
Create annotated tags:
Create an annotated tag for version 1.2.0 with release notesVerdent creates detailed tag:
git tag -a v1.2.0 -m "Release 1.2.0
New Features:
- User notification system
- Email integration
- Real-time WebSocket support
Bug Fixes:
- Fixed authentication timeout issue
- Resolved cart calculation bug"Push tags:
Push all tags to originVerdent pushes:
git push origin --tagsTips:
- Use descriptive branch names:
feature/user-auth,fix/cart-bug,refactor/api-layer - Always pull latest changes before merging
- Use annotated tags for releases (they include metadata)
- Follow semantic versioning: v1.2.3 (major.minor.patch)
Consistent branch naming conventions help Verdent understand your workflow. Define patterns in AGENTS.md for automatic compliance.
Frequently Asked Questions
Does Verdent automatically commit my changes?
No. Verdent only creates commits when you explicitly request them. You maintain full control over when changes are committed. Simply ask "Stage all changes and create a commit" when you're ready.
Can I edit the commit message before committing?
Yes. You can ask Verdent to revise the commit message before it's created. Say "Update the commit message to mention the breaking change" or "Make that commit message more concise." Verdent will regenerate the message based on your feedback.
Does Verdent work with GitHub, GitLab, Bitbucket, and other Git platforms?
Yes. Verdent uses standard Git commands, so it works with any Git repository regardless of hosting platform. For creating pull requests, Verdent uses the gh CLI which requires GitHub, but all other Git operations work universally.
Will Verdent push to remote repositories without asking?
No. Verdent only pushes to remote repositories when you explicitly request it. All Git operations (commit, push, merge, rebase) require your explicit instruction for safety.
Can Verdent resolve all types of merge conflicts?
Verdent can resolve most text-based merge conflicts by understanding code context and intent. Binary file conflicts or very complex multi-way conflicts may require manual intervention. Always review Verdent's conflict resolution before committing.