![]() ![]() ![]() As you can see in the graphic below, you push your changes to the shared repository. As the word “clone” implies, you clone the whole repository with the whole history. With Git, you simply clone a shared repository or you can also start with your local repository. DistributedĪs I already have written in the basic section, there is no check-out or map local folder with Git. ![]() In this post we will only cover a high-level overview of how Git works, if you need some detailed information, please refer to the Git website or have a look into the Pro Git book. Only if you push or pull changes or publish your branch to or from a shared repository you need to have a connection to the shared repository. With Git, you are always working against your local repository which means you commit the changes (and commit and commit…) locally as well as you create branches locally. But for committing changes or creating new branches you need to be connected to the server. With local workspaces you can work on you files without any connection to the server. So isn’t there any difference in the offline functionality between TFVC and Git? Yes, there is. You then work disconnected until you commit the changes back to the server. With local workspaces the model was changed to “Edit Commit” which means that you get a specific version of your repository and do all changes locally without checking-out the files. The server knows about each file being edited and can also control those actions on a per-file basis. After editing, you check-in the files with your commit. Before you had the classic “Check-in Check-out” model which means that you check-out each file you are currently editing. In TFVC there has been a change with version 2012 when local workspaces were introduced. Locally you are working on a representation of a specific version. TFVC is a centralized version control system which means that the repository with its history is located on a centralized server. In contrast to the short explanation of the distributed version control system, what about TFVC. So how am I going to collaborate with my colleagues? If you want to share your changes you can push them from your local repository to a shared repository or you pull changes from the shared repository to your local repository. Or in other words, you are always working with your local repository and all commits are always made to your local repository. So what does distributed then mean? Simply said, you have a local copy of the repository including the whole history. But of course you have you have a full offline experience with a distributed version control system. The common assumption that “Offline” means “Distributed” is completely wrong. But so does TFS (at least since version 2012). If you think that Git enables you to work work offline, you are right.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |