Installing Git on your Machine

Windows users

Download and install git bash for windows: https://gitforwindows.org/ Once downloaded and installed, open gitbash. You will be in your home directory. Create a .ssh directory (if you don’t already have one). Nnote that any directory that starts with a dot (.) is a hidden directory. Copy your id_rsa file from hopper to your machine. You can use this linux command for it: scp <SLUNetId>@hopper.slu.edu:/student/SLUNetId/.ssh/id_rsa ./ You’ll be prompted for your password, enter your linux account password. After installing gitbash, you can use it as if it were a linux terminal with git installed:
  1. mkdir csci2300
  2. cd csci2300
  3. git clone git@git.cs.slu.edu:courses/spring20/csci_2300/<SLUNet ID>.git
  4. cd <SLUNet ID>
  5. mkdir lab0
  6. put your HelloWorld.java into lab0 directory
  7. git add lab0
  8. git commit lab0 -m “committing lab 0”
  9. git push
  10. Verify that your commit worked by logging in to git.cs.slu.edu via the web browser.

Mac users

Download and install git for mac: https://git-scm.com/download/mac Once installed, open a mac terminal. Create a .ssh directory (if you don’t already have one). Copy your id_rsa file from hopper to your machine: scp <SLUNetId>@hopper.slu.edu:/student/SLUNetId/.ssh/id_rsa ./ You’ll be prompted for your password, enter your linux account password. After this, you should be able to use the commands we discussed in class:
  1. mkdir csci2300
  2. cd csci2300
  3. git clone git@git.cs.slu.edu:courses/spring20/csci_2300/<SLUNet ID>.git
  4. cd <SLUNet ID>
  5. mkdir lab0
  6. put your HelloWorld.java into lab0 directory
  7. git add lab0
  8. git commit lab0 -m “committing lab 0”
  9. git push
  10. Verify that your commit worked by logging in to git.cs.slu.edu via the web browser.