Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is it safe to checkout a new git branch during the push of a current branch?

For example, if I am pushing master to a remote repo and it's taking a while, is it safe to open another terminal and do git checkout secondbranch so I can start working again? Is the original process doing the push going to be disrupted by the new checkout?

like image 676
Josh Diehl Avatar asked Oct 08 '22 02:10

Josh Diehl


1 Answers

It should be safe, because push is reading from your local repo and writing to the remote, and checkout is reading from your local repo and writing to your workspace.

Nice visualization of what-goes-where: http://www.ndpsoftware.com/git-cheatsheet.html#loc=local_repo;

like image 143
nabcos Avatar answered Oct 13 '22 11:10

nabcos