Git branch-constantly updating

Source: Internet
Author: User

If you want to check the code of a previous version during development, first check the log

Git logcommit commit: Eric <eric@gmail.com> date: Sun Jun 23 23:06:17 2013 + 0800 app can run andorid wellcommit commit: Eric <eric@gmail.com> date: Sun Jun 23 21:30:36 2013 + 0800

Then we checkout a version

Git checkout f224a720b8192165a4e70f2564e42859964bebbb

If a problem is found, we changed it. Then we commit and push, but the server does not have the information we submitted because we are on a new branch.

View Branch

Bogon: pindie Eric $ git Branch * (no branch) Master

We are now on the anonymous branch. Use the following command to name the anonymous Branch:

Git checkout-B working,

We need to synchronize the modified content of the Branch to the master. Use the following command

Git stashgit pull -- rebase origin mastergit stash apply

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.