Each exercise (demo, lab, and MP) follows the same procedure for fetching, working on, and submitting content. As part of the exercise, you need to note which branch on release you can find the exercise.

The Workflow

Fetching the Initial Content

Form the exercise, find the name of the branch that the content for the excrise is on. This is usually the name of the exerise (eg: demo_Welcome). Then:

  1. In a comand prompt, navigate to your CS 205 Workbook directory
  2. Run git fetch release to fetch the latest version of the release files
  3. Run git merge release/BRANCH_NAME master, where BRANCH_NAME is replaced with the name of the branch for the exercise

Upon success, your CS 205 Workbook directory will now contain a new directory with the exercise!

The following branches currently contain exercises:

Committing your Changes

After working on your exercise, you want to commit the changes to your local repository. This requires you to add the files you changed and then commit those files.

  1. In your CS 205 Workbook directory, run git add -u to add all changed files
  2. Run git status to view what files are about to be committed
  3. Run git commit -m "MESSAGE", where MESSAGE is a message to assoicate your commit.

At this point, your changes are committed to your local repository, but ARE NOT turned in for grading.

Publishing Your Changes

After you have committed your changes to your local repository, you must push them to your repository on gitlab in order to give the CS 205 course staff access to grade your work.

  1. In your CS 205 Workbook directory, run git push origin master

Upon success, your files are committed. You can double ckeck that it got committed by going to gitlab and finding your CS 205 workbook.