Ahora cuando quiero hacer una solución rápida a mi proyecto, hago esto:
# create and switch to this new branch git checkout -b fixes-20130828-01 # push the new branch back to the origin git push origin fixes-20130828-01 # link local and remote branches git --set-upstream fixes-20130828-01 origin/fixes-20130828-01
Me gustaría poder hacer lo anterior con algo como esto:
# is there a way to get this to not only create and switch locally, # but also to link to remote git checkout --[something] fixes-20130828-01 # and then this would do the actual push to create # the branch on the origin, now that it's logically linked up git push
Esto sería más fácil de usar, recordar, y más fácil de explicar a los nuevos miembros del equipo, etc., es decir, "Usted crea la nueva twig, basada en la existente usando este command, y luego la empuja hacia atrás como lo hace normalmente".
¿Hay una opción para hacer esto de la caja?
Creo que tienes que hacerlo en 2 pasos. No sé de una manera de hacerlo en uno.
git checkout -b my-new-branch git push -u origin my-new-branch
(la opción -u establece el seguimiento en sentido ascendente).