Git and GitHub for Tanzanian Beginners: A Practical Introduction
Git is a version control system that tracks changes to your code. GitHub is a platform where you store your Git repositories online, collaborate with others, and showcase your work to employers. To get started: install Git, create a GitHub account, learn five essential commands (git init, git add, git commit, git push, git pull), and start pushing your projects. Your GitHub profile is your professional portfolio in the tech industry. Employers in Dar es Salaam and international companies alike check GitHub when evaluating candidates.
Why Git and GitHub Matter
Git is like a save system for your code, but far more powerful than pressing Ctrl+S. It tracks every change you make, who made it, and when. If you break something, you can go back to a working version. If you want to try a new feature without risking your main code, you create a branch, work on it separately, and merge it back when it works.
GitHub is where you store your Git repositories online. Think of it as Google Drive for code, but with collaboration features designed for software development. Other developers can see your code, suggest changes, report issues, and contribute.
For you as a Tanzanian developer, Git and GitHub serve three critical purposes:
1. Professional standard. Every tech company in Dar es Salaam and globally uses Git. If you cannot use Git, you cannot work on a professional team. It is not optional.
2. Portfolio. Your GitHub profile is your portfolio. Employers look at your repositories, your commit history, and your README files. A strong GitHub profile can get you interviews even without a traditional resume.
3. Deployment. Services like Vercel, Netlify, and Railway deploy directly from GitHub. Push your code to GitHub, and your application updates automatically on the internet.
Setting Up Git and GitHub
Step 1: Install Git.
- Windows: Download from git-scm.com and run the installer. Accept defaults.
- Mac: Open Terminal and type
git --version. If not installed, follow the prompt to install Xcode Command Line Tools. - Linux: Open terminal and run
sudo apt install git(Ubuntu/Debian) or the equivalent for your distribution.
Step 2: Configure Git. Open your terminal (Command Prompt on Windows, Terminal on Mac/Linux) and run:
git config --global user.name "Your Name"
git config --global user.email "your.email@example.com"
Step 3: Create a GitHub account. Go to github.com and sign up. Use a professional username (your real name or a clean variation). Add a profile photo and a short bio: "Software developer based in Dar es Salaam. React, Node.js, TypeScript."
Step 4: Connect Git to GitHub. When you push code for the first time, GitHub will prompt you to authenticate. The easiest method in 2026 is the GitHub CLI (gh auth login) or setting up a personal access token. Follow the prompts.
The Five Commands That Cover 90% of Daily Work
You do not need to memorize dozens of Git commands. These five handle most situations:
1. git init - Start tracking a project. Run this once in your project folder to initialize Git. Creates a hidden .git folder that tracks your changes.
2. git add . - Stage your changes. Tells Git which files to include in the next save point (commit). The dot means "all changed files." You can also add specific files: git add index.html.
3. git commit -m "your message" - Save a snapshot. Creates a permanent record of your staged changes. The message describes what changed. Example: git commit -m "feat: add M-Pesa payment form".
4. git push - Upload to GitHub. Sends your commits to the remote repository on GitHub. Your code is now backed up online and visible to others.
5. git pull - Download changes. Gets the latest code from GitHub. Essential when working with others or across multiple computers.
The daily workflow: Make changes to your code. git add . to stage. git commit -m "description" to save. git push to upload. Repeat. That is 90% of professional Git usage.
Write good commit messages. "fixed stuff" is unhelpful. "fix: resolve M-Pesa callback timeout in payment processing" tells everyone exactly what changed. Employers read commit messages as evidence of your professionalism.
Building a GitHub Profile That Impresses Employers
Your GitHub profile is your technical resume. Here is how to make it impressive:
Pin your best repositories. GitHub lets you pin up to 6 repositories on your profile. Choose your strongest, most complete projects. These should be deployed, documented, and demonstrate different skills.
Write README files for every project. A README is the first thing someone sees when they visit your repository. Include: what the project does, the tech stack, a link to the live deployment, how to run it locally, and screenshots. A good README takes 30 minutes and makes the difference between a recruiter spending 10 seconds or 5 minutes on your project.
Keep a consistent commit history. Regular commits show that you are actively coding. Hiring managers notice the green contribution graph on your profile. You do not need to commit daily, but consistent weekly activity signals dedication.
Use branches for features. Even on personal projects, create branches for new features and merge them when complete. This demonstrates that you understand collaborative workflows, which is essential for team-based development.
Clean up old or abandoned projects. Archive or delete repositories that are embarrassing or incomplete. Your pinned repos should represent your current skill level, not your first "Hello World."
For a deeper guide on building your full developer portfolio, see our articles on portfolio projects for Tanzanian employers and globally competitive portfolios.
Key Takeaways
- ✓Git tracks every change to your code, letting you undo mistakes, work on features without breaking your main code, and collaborate with others.
- ✓GitHub is where your code lives online. It is your professional portfolio, your backup, and your collaboration platform.
- ✓Five commands cover 90% of daily Git usage: init, add, commit, push, and pull. Start with these and learn advanced commands as you need them.
- ✓Your GitHub profile is checked by employers before interviews. A clean profile with pinned projects, meaningful commit messages, and README files makes a strong first impression.
Frequently Asked Questions
- Do I need to use the command line, or can I use a GUI?
- Start with the command line. It forces you to understand what each command does, and every professional environment uses command-line Git. VS Code has built-in Git integration that shows changes visually while using Git commands underneath. GitHub Desktop is a GUI alternative that simplifies common operations. Use a GUI to visualize changes, but understand the commands.
- What is the difference between Git and GitHub?
- Git is the version control tool that runs on your computer and tracks changes to your code. GitHub is a website that hosts Git repositories online, adds collaboration features (pull requests, issues, project boards), and serves as your public portfolio. You can use Git without GitHub (storing everything locally), but GitHub adds backup, collaboration, and visibility.
- How often should I commit?
- Commit whenever you complete a meaningful piece of work: a new feature, a bug fix, a refactored function. This might be several times per hour during active coding or once at the end of a focused session. Avoid committing broken code to your main branch. Each commit should leave the project in a working state.
Ready to build real-world apps?
Join the McTaba Labs full-stack marathon (4 months full-time · 6 months part-time). Learn M-Pesa, USSD, and WhatsApp engineering while shipping 8 production apps.
Apply to the McTaba Marathon