CS 31: Lab 0

Due: before Lab on Wednesday


Everybody do the following:

  1. Read the class webpage CS31

  2. Try out (and set up) your Swarthmore GitHub account:

    Read the Git Overview and Setup and Configuration sections of the Git Help page , and then try cloning a copy of the Lab0 repo from the CS31-F17 GitHub organization for our class.

    If this is your first time using the college's GitHub server for CS, follow the ssh-keys or config steps link from the Setup and Configuration directions for information on how to generate ssh keys and upload your public ssh key (generated from your CS account) that is necessary to clone repos on our system.

    We will go over these steps quickly in lab on Wednesday, but please try this on your own before lab.

    NOTE: you need a CS account to do this. If you don't have one, I will hand out new accounts at the end of class on Tuesday, or see Jeff Knerr outside of class to get your account.

  3. Try out the class piazza page (do Assignment 1 off this page)
  4. CS31'F17 piazza page. You will receive an email with information about how to connect. Let us know in lab on Wednesday if you encountered problems using our piazza page.

Students who have not taken CS21 do this first:

  1. Go to a CS lab and login with your new account. It will ask you to reset your password. Read and sign the user agreement form and return to me or to Jeff Knerr. Read the lab rules and user rules off the CS help pages.

    To logout, choose the logout icon logout and choose "log out".

  2. Attend one of the Using Unix Sessions:
      Monday, 7-8 Sci Cntr 256
      Tuesday, 7-8 Sci Cntr 256
  3. After going through the Using Unix material: create a cs31 subdirectory in your home directory. Start an xterm and at the unix prompt ($) enter the following command sequence (#'s are explainations of each command):
  4.   $  cd                 # change current working directory to your home directory 
      $  pwd                # print current working directory
      $  mkdir cs31         # create a new subdirectory named cs31
      $  ls                 # list contents of current working directory (your home directory)
      $  cd cs31            # change current working directory to cs31
      $  pwd                # print current working directory 
    
    Here is some information about the Unix directory structure.

  5. Learn an editor (vim). Unless you already know emacs, I recommend that you learn and use the vim editor on our system.

    From within your cs31 subdirectory run the vim tutorial:

      $  cd ~/cs31
      $  pwd
      $  vimtutor           # start the vim tutorial
    
    Just go through the following sections of vimtutor (the other sections cover more obscure features that are not necessary):
    * all of Lesson 1 (moving around, x, i, A, :wq)
    * Lesson 2.6 (dd)
    * Lesson 2.7 (undo)
    * Lesson 3.1 (p) and 3.2 (r)
    * Lesson 4.1 (G) and 4.2 (searching)
    * Lesson 6.2 (a), 6.3 (R), and 6.4 (y and p)
    
    This tutorial will take about 20-30 minutes.

As you work in a CS lab, if you plan to leave the lab for just a few minutes and then come right back to work, you do not need to log out, but it is a good idea to lock your machine while you are gone. You can lock your screen by clicking on the lock icon xlock. You should not lock a machine if you plan to be gone for more than about 10 minutes, and you should not lock main lab machines during times when classes are held in the lab.