Editing files safely with commits, branches, and merge requests
In the last chapter, you learned about using branches and commits in Git, where a branch is a series of commits, and a commit is a snapshot that consists of edits to one or more files. Because GitLab is in some senses a wrapper around a Git repository (although of course, it’s much more than that), branches and commits are also an important part of using GitLab. There’s a third, related concept that you’ll use frequently in GitLab: the merge request (often referred to as an MR). In this section, we’ll explain what an MR is and show you how to work with all three components in GitLab.
GitLab often gives you more than one way to do something, and that’s true of working with commits and branches. You can either type commands into a terminal or use the GitLab GUI to perform most of the operations you’re likely to need for these two components. Because MRs are a concept that’...