Get your API key

Lesson 4 of 6

Build screen by screen, with save points

One screen per prompt, test it, then save a Git checkpoint you can always go back to.

8 min Log in to open
One step at a time, like flipping pages.

By the end of this lesson your Daily Routine app will have working screens, each built with one prompt, tested in the browser, and saved as a Git checkpoint you can always go back to.

You need: the project from lesson 3 (with PRD.md, SCREENS.md, DESIGN.md and mockup.html), Git installed, your coding agent · Time: 8 minutes

  1. Git saves snapshots of your project called commits. A commit is a save point in a game: whatever happens later, you can come back to it. Make one now, before the AI writes any screen.

    First time only, tell Git your name and email (change them to yours; they are stored on your computer and shown in your project history):

    Terminal · macOS / Linux
    git config --global user.name "Your Name"
    git config --global user.email "you@example.com"

    Then, inside your project folder (check with pwd), make the first save point. These commands are the same in PowerShell, Terminal and Linux:

    Terminal · macOS / Linux
    git init
    git add -A
    git commit -m "Project created with PRD and design"

    git init turns the folder into a Git project (if it says "Reinitialized", the create command already did it; that is fine). git add -A picks every changed file. git commit -m "..." saves them with a short message.

    Why?

    AI agents sometimes rewrite files you did not ask about. Without a save point, a bad answer can wipe hours of work. With one, going back takes one command.

    Tip

    Open the file .gitignore in VS Code. It should list node_modules and files starting with .env. Those must never be saved in Git: one is huge, the other will hold secrets in lesson 5.

Log in free to read the rest of this lesson

Every lesson is free. A free account unlocks all of them and saves your progress.

Still to come in this lesson:

  1. One screen per prompt
  2. Run it and test it in the browser
  3. Save a checkpoint
  4. Repeat for the next screens
  5. Go back when something breaks
  6. Recap