This guide assumes that you're working in the SLU CS Linux environment: Assume project owner has created a repository "sandbox" under their GitLab username. This will be the “central” repo where you’ll merge in changes, do pull requests and code reviews. Each developer will need a “fork” of this repo. To do this, log in to GitLab, visit the page for sandbox, and click “Fork”. Then, to the command line! If prompted for a namespace, select your name. After the fork, click on the "Clone" button and copy the value from "Clone with SSH". Note that this SHOULD NOT refer to the original repository under csci5030. $ git clone https://github.com/OthersGitHubUserName/OurProjectName.git $ cd OurProjectName $ git remote add upstream https://github.com/OwnersGitHubUserName/OurProjectName.git $ git status $ git branch $ git branch -a Daily workflow! Essential that you follow this process! Merge in any changes made by other team members into the central repo: $ git fetch upstream $ git diff master..upstream/master $ git merge upstream/master $ git push $ git checkout -b newfeature [ don’t experiment on your local master!! even small changes require a branch ] $ git branch [ you will see your new branch selected with an * ] [code, test, etc. when done, you will push your new branch back up to the remote] $ git add file1.cpp file2.cpp $ git commit $ git push origin newfeature [ go to GitLab and do a “merge request” (also known as a "pull request" on the upstream repo, this notifies the maintainer of the original repository that you'd like to contribute code to their project. You can use the "Search or Jump To..." box to navigate- type "sandbox" to find these repos.] [ Go back to the original repository at courses/fall19/csci_5030/sandbox and click on "Merge Requests" in the left hand navigation bar. You should see your merge request- you can click on it and see spaces for discussion, and GitLab automatically generates a log of all commits and a diff of all changes you can browse. If you are satisfied this is a good merge, then click "Merge." When that’s been accepted and merged into upstream/master, you want to get the changes onto your fork's local master too - remember they’re only on a local branch. Instead of merging the local branch to local master, best to do this: ] $ git checkout master $ git fetch upstream $ git merge upstream/master $ git branch -d newfeature (-D to force delete, but shouldn’t need to if all changes make it cleanly into your master)