Roy Vanegas

Submitting Assignments Using GitHub Desktop

Burden: ~30 minutes

Follow every step of these instructions carefully and avoid submitting your assignment in haste or with distractions around you, as these will no doubt hinder your ability to submit successfully.

Note: Before proceeding, make sure you’re using the latest stable release of GitHub Desktop. As of this writing, version 223, Hasty Things Done Hastily, is the latest. Do not use the beta version. If you need to download GitHub Desktop, go here and scroll all the way to the bottom of the page for the latest stable version.

Note: Replace assignment-1 with the name of the assignment repo to which you need to submit your work.

  1. Log in to GitHub and visit the assignment’s repository, or repo, page. For this example, I’ll use a dummy, or slug, repo called assignment-1, https://github.com/code-warrior/assignment-1.
  2. Fork the assignment-1 repo by clicking the word fork in the upper right hand corner.
  3. You’ll see something aking to the following.
  4. Once the fork is done, you’ll be taken to the fork’s page in your account. Note the URL and the info in the top left corner to verify that you now have a fork of your own:
  5. Now copy, or clone, the repo to your computer by (1) clicking the green Clone or download button, then (2) clicking Open in Desktop, which will launch the GitHub Desktop client.
  6. In the GitHub Desktop client, leave the entry for Clone As: alone, then choose where you want to save the fork. (I’m saving in a folder called GitHub.) Click Clone in the lower right corner.
  7. Every student in any assignment repository has their own branch, formatted as FIRSTNAME-LASTNAME--GITHUB-USERNAME. Click master in the GitHub Desktop client, at the top, along the left, then choose your branch.
  8. Along the left column, under GitHub, you should see your cloned repository. Context click it and choose Open in Finder or Open in Explorer if you’re using Windows.
  9. Do all your work in this folder, committing and syncing often.
  10. Return to the GitHub Desktop client. Your changes should appear as uncommitted changes next to History. In the screenshot below, for example, I added IMG_0456.jpg and made a change to index.html. Both are considered 2 Uncommitted Changes.
  11. Commit your changes by (1) creating a commit message, (2) clicking the Commit to BRANCH_NAME button, and (3) clicking Sync. For example, I’m committing the addition of a picture of a llama.
  12. Click History along the top. You should see your commit message along the left.
  13. Click Pull Request, then click the left light blue box, then choose the target repo and branch. For example, I need to choose code-warrior/roy-vanegas--roy-vanegas as the target.
  14. Expand the GitHub Desktop box so you can read and verify the to and from repos.
  15. Add a descriptive message, then click Pull Request.
  16. You’ll get a confirmation that your pull request was successfully submitted. Also, in the confirmation will be a link to view the pull request at GitHub’s web site.