branch_sync_guard: handle stack branches whose upstream is the parent branch

Abierto
#7,874 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
3/5
Tiempo estimado
1-2 días
Aptitud para principiantes
55/100
Tipo de issue
Error
Claridad
Bastante claro
Estado de actividad
Activo
Stack tecnológico
git, shell
Área
devtools

Línea de trabajo

Start in scripts/lib/branch_sync_guard.sh, where the guard resolves the upstream via @{u}, and check how scripts/wait_pr_ready.sh calls it. Reproduce by creating a branch with git switch -c <branch> origin/<base> and inspecting git rev-parse --abbrev-ref @{u}. Done means the guard compares against origin/<current> when the upstream names a different branch, and prints a --no-track hint when that ref is missing. The issue does not name a test file.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

git switch -c <branch> origin/<base> sets the new branch's upstream to the parent PR's branch. scripts/lib/branch_sync_guard.sh then compares against that upstream, so wait_pr_ready.sh refuses the stack branch. An owner in the Cursor plugin stack had to run git branch --unset-upstream.

Proposed mechanism: when @{u} names a different branch than the current one and origin/<current> exists, compare against origin/<current>. Otherwise print a hint to use --no-track.


Generated with xum • Model: anthropic:claude-opus-5-5 • Thinking: high

Lenguaje dominante
TypeScript
Estrellas
2.1k
Forks
139
Merge medio
4 h 38 min
PR fusionados (30 d)
926

Preparar el entorno

  • Incluye un Dockerfile o un archivo de Docker Compose
  • Sin plantilla de pull request
  • Sin guía de contribución

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de coder/xum

Todos los issues de coder/xum

Issues similares

Más issues de TypeScript

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.