Skip to main content

First steps

Youtube messes up the audio quality sometimes here is a HD version of the video. HD Version This is a .mov file. Play it either using VLC or Quicktime This video is from CMPT 295 for illustration. CMPT 750 will not include continuous integration or artifact logs

Check Yourself

  • WE CANNOT GRADE ANY OF YOUR ASSIGNMENTS OR LABS IN THIS COURSE IF YOUR DO NOT COMPLETE THIS STEP
  • Make sure you have read Tutorials page and have VM set up or CSIL access
  • Steps below assume VM; you have to adapt it for CSIL.

Step 1 Create github

  • Create github account If you already have github account; upgrade to education by following instructions on site.

Step 2 Fill github form

https://docs.google.com/forms/d/e/1FAIpQLScsqhO3EVXNW4kNb5fjDLmZXHFQRFveH_3Z4hLNQb-mCv8c4w/viewform?usp=sf_link

Step 3 Passwordless github access

Method 1 : Default filename

cd ~/.ssh
ssh-keygen # Generates SSH keys (creates two files id_rsa and id_rsa.pub)
# By default id_rsa is used for authenticating with github.
# Copy id_rsa.pub to github
chmod 600 id_rsa
ssh -T git@github.com
# If things went correct.
Hi..... You've successfully authenticated..

Method 2: Filename 7ARCH_key

DO NOT FOLLOW STEP IF METHOD 1 worked. If you watched the video and created key with a different filename (e.g., 7ARCH_key instead of id_rsa) then follow steps below

$ cd ~/.ssh
$ ssh-keygen # Choose the filename as 7ARCH_key
# This will create two files 7ARCH_key and 7ARCH_key.pub.
$ chmod 600 7ARCH_key
# Copy 7ARCH_key.pub to github

# Run the following to add to your ~/.ssh/config
# If you do not have a ~/.ssh/config. Create one echo "" > ~/.ssh/config
$ echo "\n\n Host github.com\n HostName github.com\n User git\n IdentityFile ~/.ssh/7ARCH_key" > ~/.ssh/config

# IF the above worked then you should see the following in your config file
$ cat ~/.ssh/config
....
Host github.com
HostName github.com
User git
IdentityFile ~/.ssh/7ARCH_key
ssh -T git@github.com
# If everything works.
# If things went correct.
Hi..... You've successfully authenticated..

(does not include generation of ssh keys.).

Lab 0

The purpose of lab 0 is to illustrate the flow of programming assignments/homeworks.

The steps below assume the following.

  • Assignment Name: lab-0
  • Github id: course-test Replace with appropriate github id.

Step 1 : Create a your repository

You will be provided an assignment-specific starter code. Use this link to clone and create a private repository (visible to you and TA only) for you to work with.

Assignment Link

Once you create the repository you will have a respository with the following name https://github.com/CMPT-7ARCH-SFU/[Assignment]-[GithubID]

In steps below replace "course-test" with your github username

git@github.com:CMPT-7ARCH-SFU/lab-0-course-test.git

Step 2 : Clone your specific repository

WARNING: Replace course-test with your username

git config --global user.email "course-test@sfu.ca"
git config --global user.name "Course Test"
GIT_USER="course-test" ; git clone git@github.com:CMPT-7ARCH-SFU/lab-0-$GIT_USER

Step 3 : Check initial build

cd lab-0-course-test
ls

Step 4 : Complete assignment tasks

cd lab-0-course-test
echo "blueberry" >> fruit.txt
echo "mango" >> fruit.txt
git add fruit.txt

Step 5 : Commit repository

git commit -am "Added fruits"
git push

Step 6: Check github.com

Github tutorial

Github Overview