UC Berkeley IEEE Public Spaces
TechOps
TechOps
  • Home
    • History
    • Members
    • Projects
      • IEEE Time
      • SIEEECURE
  • Getting Started Projects
    • Getting Started with TechOps Projects
      • GitHub Setup
      • Git Workflow
      • Git Practice Assignment
      • Hardware Projects Setup
    • Web Demo Project
      • Assignment 1: HTTP Requests
      • Assignment 2: MongoDB
        • MongoDB Setup
      • Assignment 3: Frontend
        • Going through the Files
        • Modifying your Frontend
      • Assignment 4: Starting with Full Stack
        • Part 1: Adding A Form
        • Part 2: Connecting to a Live Database
    • Beginner VLSI Design Project
      • Initial Exercise: ALU
Powered by GitBook
On this page
  1. Getting Started Projects
  2. Getting Started with TechOps Projects

Git Workflow

PreviousGitHub SetupNextGit Practice Assignment

Last updated 1 year ago

Here's the general Git workflow that you will run into:

  1. Pull from origin main/master: git pull origin main

  2. Create your own development branch: git checkout -b <your branch name>

  3. Make your edits

  4. Commit and push your changes to your branch:

git add <file changed> <file changed>
git commit -m "commit message"
git push --set-upstream origin <your branch name>
  1. Open a pull request (PR) in the GitHub interface to merge into main:

Remember to never commit and push directly to main. The purpose of git is to create a way for many people to work on the same code at the same time without major conflicts.

We also would like to see a clean git history. This means:

  • Rebase often: try to pull the latest changes from main as needed

  • Make PRs for features and try not to run into conflicts

  • Make commits linear if possible:

As a first assignment, please complete Git Practice Assignment