DEV Community

Harsh Pandhe
Harsh Pandhe

Posted on

GitHub Bootcamp: Day 2 - Setting Up GitHub

Welcome to Day 2 of our 5-day GitHub series! Today we’re setting up GitHub, the digital garage where developers store, collaborate on, and show off their code. If GitHub were a superhero, it’d be Batman: mysterious, powerful, and full of cool gadgets (like Actions and Pull Requests). Let's get you set up and ready to push code like a pro.


Step 1: Create a GitHub Account

Go to github.com and hit Sign up

Github

  • Pick a memorable username (bonus points for geeky puns).
  • Add your email and a strong password.
  • Choose your plan (the free one is plenty to get started).

You're officially a GitHubber now. 🎉


Step 2: Create Your First Repository

A repository (or “repo”) is where your project lives—kind of like a folder, but cooler.

How to Create a Repo:

  1. Click the + icon on the top-right → New repository.
  2. Give it a name like awesome-project.
  3. Add a description (optional but classy).
  4. Choose public (anyone can see) or private (for your eyes only).
  5. Check “Initialize this repository with a README” if you want to add one.
  6. Click Create repository.

Github

Boom. Your project home is ready.


Step 3: Install Git Locally

To push code from your computer to GitHub, you’ll need Git installed.

Install Git:

  • Windows: Download Git
  • macOS: Use Homebrew → brew install git
  • Linux: Use your package manager → sudo apt install git (for Debian/Ubuntu)

Github

Configure Git:

git config --global user.name "Your Name" git config --global user.email "your@email.com" 
Enter fullscreen mode Exit fullscreen mode

This tells Git who you are (like a signature on your code).


Step 4: Push Your Code to GitHub

Let’s say you created a project on your computer called hello-github.

Push it to GitHub:

cd hello-github git init git add . git commit -m "Initial commit" git branch -M main git remote add origin https://github.com/yourusername/hello-github.git git push -u origin main 
Enter fullscreen mode Exit fullscreen mode

Github

And boom 💥 your code is now live on GitHub!


GitHub UI Tips for Beginners

  • README.md: A welcome message for your repo. Make it fun and informative.
  • Commits Tab: Shows your code history like a time-travel diary.
  • Branches: Parallel universes for your code. We’ll talk more tomorrow!

Bonus: Learn Git Basics

Here are a few must-know Git commands:

Command Description
git status Check what’s going on
git add . Stage all changes
git commit -m "message" Save changes
git push Upload changes to GitHub
git pull Fetch latest code

Conclusion

Today you created a GitHub account, made a repo, and learned how to push your first code. You’re officially dangerous (in a good way).

What’s Coming Next?

Tomorrow, we dive into Branching and Merging—aka how not to break stuff while working with others. Stay tuned!

#GitHub #Git #DeveloperTools #VersionControl #OpenSource #Day2

Top comments (0)