feature: muestro el listado de commits a pasar al siguiente entorno en release
This commit is contained in:
@@ -43,6 +43,17 @@ class ReleaseCommand(Command):
|
||||
else f"release/{next_env}/{branch}"
|
||||
)
|
||||
|
||||
base = Git.get_first_fork_point(branch, env)
|
||||
commits = Git("log", base + ".." , format="%s").lines()
|
||||
|
||||
if not commits:
|
||||
raise GitFlowError("No hay cambios a mergear.")
|
||||
|
||||
print("Cambios a pasar al proximo entorno:")
|
||||
|
||||
for commit in commits:
|
||||
print("- " + commit)
|
||||
|
||||
group = args.group
|
||||
|
||||
if not group and self.confirm("¿Desea agrupar este release con otra rama?", False):
|
||||
@@ -55,11 +66,8 @@ class ReleaseCommand(Command):
|
||||
Git("pull").exec(print="Sincronizando cambios la rama objetivo")
|
||||
Git("switch", "-").exec(print="Volviendo a la rama original")
|
||||
|
||||
base = Git.get_first_fork_point(branch, env)
|
||||
commits = int(Git("rev-list", base + "..", count=True).firstline())
|
||||
|
||||
if commits > 1 and self.confirm(
|
||||
f"¿Desea reemplazar los {commits} commits de la rama por uno solo?",
|
||||
if len(commits) > 1 and self.confirm(
|
||||
f"¿Desea reemplazar los {len(commits)} commits de la rama por uno solo?",
|
||||
False
|
||||
):
|
||||
self.info("Debe ingresar el mensaje del commit a crear.")
|
||||
|
||||
Reference in New Issue
Block a user