Git Tutorial


Installation:

Not Windows:
  1. Open up terminal
  2. Depending on your operating system, type in the following command:
               Mac - brew install git
               Ubuntu - sudo apt-get install git
               Fedora - sudo dnf install git

Git Workflows:


Essential Git Commands:

  1. git clone <link> - Clone a remote repository into your working directory. 
        Ex. git clone https://github.com/RIT-Launch-Initiative/2020-SPICA-Flight-Computer.git
  2. git pull - get updates from the remote repository directly.
  3. git add <file> add modified files to the staging area.
       Ex. git add . or git add src/main.c
  4. git commit -m "commit message" add all files from the staging area to the local repository.
  5. git push - add all committed files from the local repository to the remote repository.
  6. git branch -a - view all git branches
  7. git checkout <branch_name> switch to a new development branch
       Ex. git checkout my_branch
Drop here!