AgentStack
Browse Sign in
Browse Why AgentStack Sell Docs
Sign in
SKILL verified MIT Self-run

Merge Conflict Surgeon

skill-latestaiagents-agent-skills-merge-conflict-surgeon · by latestaiagents

|

No reviews yet
0 installs
34 views
0.0% view→install

Install

$ agentstack add skill-latestaiagents-agent-skills-merge-conflict-surgeon

✓ scanned · ✓ verified, works with Claude Code, Cursor, and more.

Security review

✓ Passed

No issues found. Passed automated security review. · v0.1.0 How review works →

  • Prompt-injection patterns
  • Secret / credential exfiltration
  • Dangerous shell & filesystem operations
  • Untrusted network calls
  • Known-malicious package signatures

What it can access

  • Network access No
  • Filesystem access No
  • Shell / process execution No
  • Environment & secrets Used
  • Dynamic code execution No

From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.

View the full security report →

Verified badge

Passed review? Show it. Paste this badge into your README, it links to the public security report.

AgentStack Verified badge Links to your public security report.
[![AgentStack Verified](https://agentstack.voostack.com/badges/verified.svg)](https://agentstack.voostack.com/security/report/skill-latestaiagents-agent-skills-merge-conflict-surgeon)

Reliability & compatibility

Security review passed
0 installs to date
no reviews yet
5mo ago

Declared compatibility

Claude CodeClaude Desktop

Compatibility is declared by the source manifest. End-to-end runtime verification is coming, see below.

Preview Execution monitoring

We're building live execution health for every listing: tool-call success rate, median latency, uptime, and last-checked timestamps, measured, not self-reported. It isn't live yet, so we don't show numbers we can't stand behind.

How agent discovery & health will work →
Are you the author of Merge Conflict Surgeon? Claim this listing to set pricing, connect Stripe payouts, and keep 70% of every sale.
Sign up to claim

About

Merge Conflict Surgeon

Resolve Git merge conflicts systematically and safely.

When to Use

  • git merge or git rebase fails with conflicts
  • You see conflict markers (>>>>>>) in files
  • git status shows "both modified" files
  • Merging feature branches into main/develop
  • Rebasing a branch onto updated main

Workflow

Step 1: Assess the Damage

# See all conflicted files
git status

# See the full diff of conflicts
git diff --name-only --diff-filter=U

List all conflicted files and categorize them:

  • Simple conflicts: Same file, different lines (auto-resolvable logic)
  • Overlap conflicts: Same lines modified differently (needs human decision)
  • Delete/modify conflicts: One side deleted, other modified

Step 2: Understand Both Sides

For each conflicted file, understand:

# See what YOUR branch changed
git diff HEAD~1 -- 

# See what the OTHER branch changed
git diff MERGE_HEAD~1 -- 

# See common ancestor
git show :1:  # Base version
git show :2:  # Ours (current branch)
git show :3:  # Theirs (merging branch)

Step 3: Resolve Strategically

For simple conflicts (different functionality):

  • Keep both changes, ensure they don't break each other
  • Run the code mentally or actually to verify

For overlapping conflicts (same code, different changes):

  1. Understand the INTENT of each change
  2. Determine which achieves the goal better
  3. Sometimes combine logic from both
  4. Never blindly pick "ours" or "theirs"

For delete/modify conflicts:

  • If deleted intentionally (refactoring), ensure the modification isn't needed
  • If deleted accidentally, restore and apply modification

Step 4: Validate Resolution

# Mark as resolved
git add 

# Verify no remaining conflicts
git diff --check

# Run tests before completing
npm test  # or your test command

# Complete the merge
git commit  # or git rebase --continue

Resolution Patterns

Pattern 1: Sequential Changes

>>>>>> feature-branch

Resolution: Keep both - they're independent additions

function processUser(user) {
  validateUser(user);
  logUserAccess(user);

Pattern 2: Competing Implementations

 x.active).map(x => x.name);
=======
const result = items.reduce((acc, x) => x.active ? [...acc, x.name] : acc, []);
>>>>>>> feature-branch

Resolution: Choose based on readability/performance needs. The filter().map() is clearer.

Pattern 3: Configuration Changes

>>>>>> feature-branch

Resolution: This is environment-specific. Use environment variables instead:

const API_URL = process.env.API_URL || 'https://api.prod.example.com';

Tools

# Use a merge tool (if configured)
git mergetool

# Abort if things go wrong
git merge --abort
git rebase --abort

# Accept all of one side (use carefully)
git checkout --ours     # Keep your version
git checkout --theirs   # Keep their version

Common Mistakes to Avoid

  • Never blindly accept "ours" or "theirs" without understanding the changes
  • Don't leave conflict markers in code (>>>>>>)
  • Don't skip running tests after resolution
  • Don't force push to shared branches after rebase conflicts
  • Don't ignore whitespace or formatting conflicts - they can hide real issues

Emergency Recovery

# If you messed up the resolution
git checkout -m   # Restore conflict markers

# If you committed a bad resolution
git reset --soft HEAD~1  # Undo commit, keep changes
# Then resolve again

# Nuclear option: start over
git merge --abort  # or git rebase --abort

Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

Install and usage instructions live in the source repository linked above.

Reviews

No reviews yet, be the first.

Versions

  • v0.1.0 Imported from the upstream source.