Skip to content

place to learn how to better cooperate for coding tasks

Notifications You must be signed in to change notification settings

UmichSIM/UmichSIM_Pragmatics

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 

Repository files navigation

UmichSIM_Pragmatics

Place to learn how to better cooperate for coding tasks.

Introduction

This repo contains tutorials on some basic tools that you will use intensively in our project. The name comes from EECS201, which contains a more comprehensive version of these tutorials (highly recommend taking this course).

Shells

Obtaining a Unix Shell

Windows

Natively, Windows use another type of shell called CMD/PowerShell. Fortunately, with the help of Windows Subsystem for Linux (WSL), it's easy to access a linux shell within the subsystem. Check this link to install WSL.

macOS&Linux

Belonging to the family of "Unix Like" operating systems, macOS and Linux supports Unix Shell natively. Just open a terminal software (like Terminal.app on MacOS) and you are ready to go.

first to remember

  • basic shell command structure image
  • [TAB] - the most important key you need
    • helps complete your unfinished command or path
    • can even list available candidates

Surfing in the file system

  • pwd
    • print working directory associated with your shell session
  • cd
    • change directory
    • usage: cd /place/you/want
    • cd .. will take you to the parent directory
  • ls
    • list contents in current directory
    • some options:
      • -l: display in list format
      • -a: also show hidden files (file start with .)

Other useful commands and keys

  • man: see manual for commands
  • ctrl+r: search command history in bash
  • ctrl+l: clear the screen
  • ctrl+d: send EOF, can be used to close the current shell program

Gitting Started

Installation

  • Windows(WSL)
    • inside WSL, run sudo apt install git
  • macOS
    • install homebrew, a package manager for macOS
    • run brew install git
  • Linux
    • use your package manager

Files status in git

image

Basic commands

  • git init: initialize git repo
  • git status: check repo status
  • git log: show log
  • git add: stage files
  • git checkout: change location of HEAD
  • git commit: commit staged changes
    • make sure your commit message is meaningful! image

Branching

  • git branch: show branches
  • git branch <branch-name>: create a new branch
  • git checkout <branch-name>: switch to another branch

Remotes

  • git clone <URL>: clone from a remote repo
  • git remote -v: will list your remotes
  • git pull: pull from remote for new changes
  • git push: send commits to the remote

Github

Issues

Issues let you track your work on GitHub, where development happens. I'll introduce some useful components in an issue.

  • Assignees - assign the task to someone!

image

  • Labels - define your task!

image

  • Development - Link your working branch to the issue!

image

  • issue link - refer to other issues/PRs here!

image

Pull Requests

Pull requests let you tell others about changes you've pushed to a branch in a repository on GitHub. It serve as a buffer for others to review your changes.

  • merge, squash, or rebase?
    • merge - merge all commits in both branch and create another "merge commit" to solve possible conflicts
    • squash - squash all incoming commits into a single commit and add to main branch
    • rebase - add all incoming commits "linearly" into the main branch
    • we prefer squash for a clean history

image

Do it yourself!

  • create an issue called first issue - [your name] in this repo
  • refer your issue in Master issue list
  • create a new branch in the Development tab
  • in your branch, add your name (and perhaps a link) in the Who finished this tutorial? section.
  • add, commit, push
  • create a pull request for your branch to merge into main branch

Python

Finally... Python is the main language we'll use for our project. Since most people have experience with Python we won't spend too much time on it. If you have no previous experience, you can use this website to learn (and also other languages!).

IPython

IPython is an REPL for Python. It's a very handy interactive environment for you to test and learn Python. Do checkout if you haven't.

Useful Links

Who finished this tutorial?

  • Andy Yang
  • C.C
  • Fengyuan Hu
  • Hanxi Wan
  • Howard Yang
  • Yuxuan Liu
  • Aditi Locula

About

place to learn how to better cooperate for coding tasks

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published