In Android Studio, how does Git update the local remote branch list ?, Androidgit
For example, if your colleague adds branch xxx in Git's remote branch, but you find that when you view the existing branch in Android Studio, you cannot see the branch he added. If you view branch, please stamp this: how does Android Studio view the branch list and switch branch,
The command line method is as follows: git branch-a or git branch-r.
If you can see the newly added branch, there are two ways:
Method 1: git fetch
Method 2: git remote update origin -- prune. Note that if your remote branch is not under 'origin', replace 'origin' with your name.
You can use the command line directly on git bash or terminate in Android Studio.
Before using Android Studio, configure the git bin directory as an environment variable (with path)
Git add git push-u origin master and then prompt: Branch master set up to track remote branch master
Git add. # add the file to stage area
Git commit # submit the file and prompt to enter the commit message
Git push-u origin master # push to the remote warehouse and set the tracking branch. When you push it next time, just enter git push and you will be awake, the system automatically uses the local master branch to track the remote master branch.
Actual use of git's "branch"
[Then I create another version library through git clone and can only obtain the code of the remote origin master branch.]
After cloning, you can check the log 'there should be a branch01 branch log '~
After you clone it, it is in the master branch 'You Need to checkout' ~ by default '~
[Git checkout branch01]