merge-resolve-conflicts
Qué hace
Guía al agente de IA para actualizar tu rama de trabajo con la rama por defecto y resolver los conflictos. Está pensada para desarrolladores que trabajan en una rama de git o en un worktree.
Cuándo usarla
- ✓Cuando tu rama va por detrás de main y quieres traer los últimos cambios.
- ✓Cuando git informa de conflictos de fusión que necesitas resolver con ayuda.
- ✓Cuando tienes cambios sin guardar y necesitas decidir cómo guardarlos con stash o confirmarlos antes de fusionar.
Link de la skill
https://github.com/humanlayer/humanlayer/blob/main/.claude/skills/merge-resolve-conflicts/SKILL.mdCópialo y pégalo en tu IA (Claude, ChatGPT o Cursor) pidiéndole que siga las instrucciones.
Cómo usar
La forma más fácil: copia el mensaje y pégalo en tu IA. Ella lee la skill y sigue las instrucciones.
Mensaje listo para pegar
Para Claude Code, Codex o Cursor: ejecútalo en la carpeta del proyecto y la skill queda instalada.
Descarga el SKILL.md y ponlo en la carpeta de skills de tu agente.
Ejemplo de qué pedirle a la IA
“Fusiona la última versión de main en mi rama y ayúdame a arreglar los conflictos.”
5 skills nuevas por semana. 1 minuto de lectura.
Cómo funciona
El agente descarga los últimos cambios, comprueba el estado de tu rama y pregunta antes de tocar cualquier trabajo sin guardar. Después resuelve los conflictos contigo.
Contenido técnico (SKILL.md original)
Texto original del autor, en inglés, directo de GitHub.
You are either on a branch in a repository, or you are on a git worktree for a specific branch.
You are responsible for ensuring the default branch (usually main or master, but not always) is merged into the current branch.
Begin by running git fetch.
Then:
Step 1: Orientation
First, you must determine if you are on a worktree for a repository OR if you are on a regular branch on a repository OR if you are on the default branch for the repository
Second, you must determine if the branch you are on has changes on upstream / origin (as configured) that you do not have on your local branch
Third, you should determine if there are existing merge conflicts on your branch already by running git status.
Fourth, you should determine if the user has both an origin and an upstream configured.
Important: if the user is working across multiple repositories, you should ask them which repository(ies) they would like help merging in.
Step 2: Action
Depending on the results of your orientation you should take one of the following actions:
- If the user has unstaged changes which do not include merge conflicts or an ongoing merge: offer to either stash and merge, or to commit before merging, Then proceed with the following once the user answers:
- If there are existing merge conflicts on your current branch: proceed to "Conflict Resolution Procedure" and follow those instructions.
- If you are on a worktree or branch which is not for the default branch, and there are no merge conflicts:
- if the user has both upstream and origin configured: fetch the defualt branch from the upstream and then merge it into the current branch. Proceed to the "conflict resolution procedure" steps.
- if the user has only origin configured: fetch the default branch from the origin and merge it into the current branch. Proceed to the "Conflict resolution procedure" steps.
- If you are on the default branch and there are no merge conflicts and no changes on origin/upstream: Indicate this to the user and ask what they would like you to do.
Conflict Resolution Procedure
- Read the
ticket.mdand structure outline artifacts. These should contain sufficient context about the user's task and what they are working on. You may later read the plan file if you determine that more information is needed. - Use sub-agents to analyze the git state on the current branch and on the branch the conflicts come from to understand what was done and why they diverge.
- Use sub-agents to read the entire file for each conflict, as well as key relevant code and modules to understand the scope and nature of each conflict
- For each conflict (not necessarily each individual confict, e.g. group two related conflicts in the same file together e.g. for a function change and an import change for it), provide an analysis to the user of:
a. What is on HEAD
b. What is on the branch that the conflict is coming from (probably
mainor the other default branch) c. Based on the scope of the current task, recent commits to it and to the branch where the source of the conflict is coming from, how you recommend resolving it (keep HEAD, keep other branch, merge them), and why Keep your analysis concise, offer to provide more detail to the user if they ask. - Ask the user how they would like to proceed for each one.
- Work back and forth with the user to resolve all conflicts. Only make changes that the user explicitly asks for - e.g. do not resolve a conflict until the user confirms the approach or instructs you to make the change.
- Once all merge conflicts are resolved, ask the user if they would like you to commit and push. If they confirm, you should write a conventional commit-style message indicating the branch merged in (from what commit hash), and a full body that indicates what each of the conflicts resolved was and how it was resolved and why.
IMPORTANT: Update your todo list to include items 1-7. You MUST stop and ask the user how they would like to proceed after presenting the analysis from step 4. You MUST work back and forth with the user until all conflicts have been resolved before proceeding to stop 7. The user may only give you instructions / guidance on some of the changes at a time - you should use the todo tool to track which ones have been completed and which ones still need resolution in your todo list.
Preguntas frecuentes
¿Confirmará mis cambios por mí?
Pregunta primero. Si tienes cambios sin guardar, ofrece guardarlos con stash o confirmarlos antes de fusionar.
¿Funciona con varios repositorios?
Si trabajas con varios repositorios, pregunta cuáles quieres fusionar.
¿Revisa primero mis remotos?
Sí. Comprueba qué remotos están configurados y si la rama remota tiene cambios que aún no tienes.
Detalles
Descripción original del autor
Use to merge in main and resolve open merge conflicts.
repo: humanlayer/humanlayer
Popularidad
- Estrellas en GitHub
- 13 mil
- Posición en el ranking
- #11387
- Licencia
- Apache-2.0
- Actualizada
- 31/10/2026
Comentarios
- …
Más skills de este repositorio
asd-ste100
13 milEnseña a tu agente a reescribir inglés confuso en frases cortas de un solo significado, fáciles de leer para personas y para otros programas.
better-github-skill
13 milAyuda a tu agente a revisar el estado de una pull request, leer sus comentarios de revisión y averiguar por qué falló una compilación de CI, usando scripts de GitHub ya preparados.
calldiff
13 milAyuda a tu agente a comparar las cadenas de llamadas a funciones de un código entre dos versiones de git, para que una revisión de código vea qué comportamiento cambió.
chrome-devtools-cli
13 milPermite que tu agente controle Chrome desde la terminal para abrir páginas, hacer clic, rellenar formularios y tomar instantáneas de páginas, para automatizar y probar el navegador.
Skills parecidas
diffs
394 milPermite que tu agente genere un diff real y compartible de los cambios, como enlace de visualización o archivo de imagen, en lugar de un resumen escrito a mano.
coding-agent
394 milAyuda a tu agente a pasar un trabajo de programación grande a Codex, Claude Code u OpenCode como trabajador en segundo plano, y después revisar su progreso.
gh-issues
394 milAyuda a tu agente a encontrar incidencias de GitHub, elegir cuáles trabajar y abrir pull requests con correcciones, incluido el seguimiento de los comentarios de revisión.