Thuta Learning
ProjectsDevOps & Toolsbeginner

Project: Portfolio Website — Part 1 (Setup)

Relax. We'll talk through this in plain words — no textbook voice.

What you'll walk away with

  • Apply Project: Portfolio Website — Part 1 (Setup) in a real, hands-on project
  • Write and run your own code
  • Build out an entire project step by step

Let's think about it this way for a second

In this section, we'll revisit Git's core workflow using a real project. We'll start from a brand-new folder called portfolio-site and create a local repository with git init. Then we'll put Git's three states (Working Directory, Staging Area, Repository) into practice with actual files and start building up our commit history. We'll keep expanding this project in Part 2 and Part 3 with branches, merges, and remotes, so it's important to get this foundation solid first.

Let's build it for real

First, create a new folder called portfolio-site and run git init inside it. Then create two files: index.html (a simple HTML page with your name and a short bio) and README.md (a description of the project). Add a .gitignore file too, to ignore node_modules/ and .DS_Store. Check the untracked files with git status, then stage them with git add .. Finally, commit with the message 'Initial commit: project structure' and view the history with git log.

Code Example

bash
# Step 1: project folder ဖန်တီးပြီး Git repository initialize လုပ်ပါ
mkdir portfolio-site
cd portfolio-site
git init

# Step 2: files များ ဖန်တီးပါ
echo "# My Portfolio Website" > README.md
echo "<html><body><h1>Hello, I'm a developer</h1></body></html>" > index.html

# Step 3: .gitignore file ဖန်တီးပါ
printf "node_modules/\n.DS_Store\n*.log\n" > .gitignore

# Step 4: status စစ်ပြီး stage လုပ်ပါ
git status
git add .

# Step 5: commit လုပ်ပါ
git commit -m "Initial commit: project structure"

# Step 6: history ကြည့်ပါ
git log --oneline
You should see
After running git log --oneline, a commit called 'Initial commit: project structure' shows up in the history.

Try it in 5 minutes

Add one more paragraph tag to index.html and practice the git status → git add → git commit workflow again (5 minutes).

A quick word of caution

Always write clear commit messages — later, when you're looking back through the history, a message like 'Initial commit: project structure' tells you far more about what actually happened than something like 'update'.

Easy traps

  • Creating files before running git init, then trying to commit without checking whether a .git folder even exists
  • Forgetting to create the .gitignore file before running git add ., so files like node_modules end up getting tracked

Now try it yourself

Add one more paragraph tag to index.html and practice the git status → git add → git commit workflow again (5 minutes).

You'll know it worked when: After running git log --oneline, a commit called 'Initial commit: project structure' shows up in the history.

Project: Portfolio Website — Part 1 (Setup) | Thuta Learning