merge-resolve-conflicts
O que ela faz
Ele orienta o agente de IA a atualizar sua branch de trabalho com a branch padrão e a resolver conflitos. É para desenvolvedores que trabalham em uma branch ou worktree do git.
Quando usar
- ✓Quando sua branch está atrás da main e você quer trazer as mudanças mais recentes.
- ✓Quando o git informa conflitos de merge que você precisa resolver com ajuda.
- ✓Quando você tem alterações não salvas e precisa decidir como guardá-las ou fazer commit antes do merge.
Link da skill
https://github.com/humanlayer/humanlayer/blob/main/.claude/skills/merge-resolve-conflicts/SKILL.mdCopie e cole na sua IA (Claude, ChatGPT ou Cursor) pedindo para seguir as instruções.
Como usar
O jeito mais fácil: copie a mensagem e cole na sua IA. Ela lê a skill e segue as instruções.
Mensagem pronta para colar
Para Claude Code, Codex ou Cursor: rode na pasta do projeto e a skill fica instalada.
Baixe o SKILL.md e coloque na pasta de skills do seu agente.
Exemplo do que pedir para a IA
“Faça o merge da main mais recente na minha branch e me ajude a corrigir os conflitos.”
5 skills novas por semana. 1 minuto de leitura.
Como funciona
O agente busca as mudanças mais recentes, verifica o estado da sua branch e pergunta antes de mexer em trabalho não salvo. Depois trabalha nos conflitos junto com você.
Conteúdo técnico (SKILL.md original)
Texto original do autor, em inglês, direto do 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.
Perguntas frequentes
Ele faz commit das minhas mudanças por mim?
Ele pergunta antes. Se você tiver alterações não salvas, ele oferece guardá-las com stash ou fazer commit antes do merge.
Ele funciona em vários repositórios?
Se você trabalha em vários repositórios, ele pergunta em quais quer ajuda para fazer o merge.
Ele verifica os remotos antes?
Sim. Ele verifica quais remotos estão configurados e se a branch remota tem mudanças que você ainda não tem.
Detalhes
Descrição original do autor
Use to merge in main and resolve open merge conflicts.
repo: humanlayer/humanlayer
Popularidade
- Estrelas no GitHub
- 13 mil
- Posição no ranking
- #11387
- Licença
- Apache-2.0
- Atualizada em
- 31/10/2026
Comentários
- …
Mais skills deste repositório
asd-ste100
13 milEnsina seu agente a reescrever textos confusos em inglês, usando frases curtas e com um único sentido, fáceis de ler para pessoas e outros softwares.
better-github-skill
13 milAjuda seu agente a checar o status de um pull request, ler os comentários de revisão e descobrir por que um build de CI falhou, com scripts prontos do GitHub.
calldiff
13 milAjuda seu agente a comparar as cadeias de chamadas de funções em um código entre duas versões do git, para que a revisão veja o que mudou no comportamento.
chrome-devtools-cli
13 milPermite que seu agente controle o Chrome pelo terminal para abrir páginas, clicar, preencher formulários e tirar capturas da página, para automação e testes de navegador.
Skills parecidas
diffs
394 milPermite que seu agente gere um diff real e compartilhável das edições, como link de visualização ou arquivo de imagem, em vez de um resumo escrito à mão.
coding-agent
394 milAjuda seu agente a passar um trabalho grande de programação para o Codex, Claude Code ou OpenCode em segundo plano e acompanhar o andamento.
gh-issues
394 milAjuda seu agente a encontrar issues do GitHub, escolher quais resolver e abrir pull requests com correções, acompanhando os comentários de revisão.