bugfix: commit small improvements #69

Merged
jt merged 4 commits from bugfix/commit-small-improvements into main 2026-09-28 17:27:54 +00:00
2 changed files with 10 additions and 1 deletions
Showing only changes of commit aacc5b90e2 - Show all commits
+1 -1
View File
@@ -53,7 +53,7 @@ más información):
- `init`: Inicializa el repositorio para utilizar git-flow (ramas principales y remoto).
- `new`: Crea una nueva rama siguiendo CB.
- `commit`: Crea un commit siguiendo CC.
- `commit`: Crea un commit siguiendo CC. No permite commitear directamente sobre un entorno.
- `merge`: Mergea la rama actual a uno de los entornos.
- `tag`: Crea un tag sobre el ultimo merge siguiendo SemVer (ver [Tag](#tag)).
- `release`: Prepara la rama actual para pasarse al siguiente entorno configurado.
+9
View File
@@ -15,6 +15,15 @@ def commit():
base.ensure_initialized()
branch = base.ensure_right_branch()
# Una rama WIP termina squasheando en su rama original, que tampoco puede ser un entorno
target_branch = branch.removeprefix(WIP_BRANCH_PREFIX)
if target_branch in base.environments:
raise GitFlowError(
f"No se puede commitear directamente sobre el entorno '{target_branch}'. "
"Debe crear una rama de trabajo con el comando `new`."
)
if not _has_files_staged():
base.io_warning("No hay cambios en el indice para commitear.")
if base.io_confirm("¿Desea agregar la carpeta actual?"):