![]() ![]() Many people consider the name main to do a better job of describing this branch and its typical usage. DESCRIPTION Clones a repository into a newly created directory, creates remote-tracking branches for each branch in the cloned repository (visible using git branch -remotes ), and creates and checks out an initial branch that is forked from the cloned repository’s currently active branch. I had created a branch (origin\master) but I did the mistake of using this branch for my development, so I pushed my first few changes to this branch. It implies a relationship with some other, unnamed entity, but it doesn’t represent the unique status of the initial branch. 41 I just started on a new project and I'm using GitLab with SourceTree. Aside from any offense it may cause, master isn’t a particularly descriptive name anyway. The Git maintainers have worked with the wider development community to address these concerns. However, the term has become somewhat outdated for its association with colonialism. Other version control systems such as BitKeeper, a predecessor to Git, have also used the term. The master/slave terminology has a long history in computing, especially in reference to hardware such as disk drives. The just-created branch can be renamed via this command: git branch -m To configure the initial branch name to use in all of your new repositories, which will suppress this warning, call: git config -global faultBranch Names commonly chosen instead of 'master' are 'main', 'trunk' and 'development'. If youve been waiting to rename your default branch from master to main, we now recommend doing so using this feature. This default branch name is subject to change. You can now rename any branch, including the default branch, from the web. Using 'master' as the name for the initial branch. Recent versions of Git (2.28 and later) produce the following hint when you create a new repository using git init: Branch Naming and Why Master Is Being Phased Out
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |