{"id":7983,"date":"2005-12-15T17:12:00","date_gmt":"2005-12-15T17:12:00","guid":{"rendered":"https:\/\/blogs.msdn.microsoft.com\/visualstudioalm\/2005\/12\/15\/understanding-branching\/"},"modified":"2019-02-14T17:53:34","modified_gmt":"2019-02-15T01:53:34","slug":"understanding-branching","status":"publish","type":"post","link":"https:\/\/devblogs.microsoft.com\/devops\/understanding-branching\/","title":{"rendered":"Understanding Branching"},"content":{"rendered":"<p>Branching is a feature that allows a collection of files to\nevolve in two or more divergent paths. Branching is frequently used when teams\nhave to maintain two or more similar code bases, as can occur when a product is\nreleased and work must begin on the next version.<\/p>\n<p>Branching in Team Foundation source control is analogous to\na file system copy operation. Branching will preserve the history of the\nfolders and files that you are branching and will allow changes to be merged\nfrom the old files to the new ones. Branching\ncan be conducted through Source Control Explorer, or from the command line\nusing the Branch Command.<\/p>\n<p>A branch operation has a source and a target. The source\nprovides the name and version of the file or folder being branched and the\ntarget provides the location of the destination file or folder. If the\nspecified target is the name of a folder that exists in the server, the actual\ntarget will be created within that folder; otherwise, the actual target is as\nspecified.<\/p>\n<p>Branching creates a pending change operation in Team\nFoundation source control. The branch is not actually created until the pending\nchange in changesets is committed to the server.<\/p>\n<p>Before checking in the branch to the server, files and\nfolders can be modified, renamed, deleted, and undone.<\/p>\n<p>A folder or file must be in a non-deleted state to be\nbranched. Branching a tree of files will not cause the deleted items within\nthat tree also being branched. At a future point, if the deleted item is\nundeleted in the source tree, a merge operation can branch that file into the\ntarget branch.<\/p>\n<p><b>Tip<\/b>&nbsp;&nbsp;&nbsp;You can see a source control items branch history by viewing its properties.<\/p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Branching is a feature that allows a collection of files to evolve in two or more divergent paths. Branching is frequently used when teams have to maintain two or more similar code bases, as can occur when a product is released and work must begin on the next version. Branching in Team Foundation source control [&hellip;]<\/p>\n","protected":false},"author":125,"featured_media":45953,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[1],"tags":[],"class_list":["post-7983","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-devops"],"acf":[],"blog_post_summary":"<p>Branching is a feature that allows a collection of files to evolve in two or more divergent paths. Branching is frequently used when teams have to maintain two or more similar code bases, as can occur when a product is released and work must begin on the next version. Branching in Team Foundation source control [&hellip;]<\/p>\n","_links":{"self":[{"href":"https:\/\/devblogs.microsoft.com\/devops\/wp-json\/wp\/v2\/posts\/7983","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/devblogs.microsoft.com\/devops\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/devblogs.microsoft.com\/devops\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/devops\/wp-json\/wp\/v2\/users\/125"}],"replies":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/devops\/wp-json\/wp\/v2\/comments?post=7983"}],"version-history":[{"count":0,"href":"https:\/\/devblogs.microsoft.com\/devops\/wp-json\/wp\/v2\/posts\/7983\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/devops\/wp-json\/wp\/v2\/media\/45953"}],"wp:attachment":[{"href":"https:\/\/devblogs.microsoft.com\/devops\/wp-json\/wp\/v2\/media?parent=7983"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/devops\/wp-json\/wp\/v2\/categories?post=7983"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/devops\/wp-json\/wp\/v2\/tags?post=7983"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}