Quickstart Publish your first site with Claude Code

Step 2 · Set up your agent

Git, Node & GitHub CLI

Three free tools let the agent save versions of your site, build it, and handle GitHub for you. You ask, and the agent installs them.

Time: 15 minVS Code path

What each tool is for

ToolWhat it does for youDo you need it?
GitSaves versions of your files and sends them to GitHub.Yes.
Node.jsRuns the build script some starters use: startup-india-guide, the multi-page starter, builds with node build.mjs. history-of-tampa, the one-page story, needs no build.Install it anyway. It's quick.
GitHub CLI (gh)Lets the agent create and fork repos for you, and handles Git's sign-in to GitHub so pushes work. It can also turn on GitHub Pages, as an optional shortcut for the setting you click on github.com.Optional, but recommended. Without it, you create and fork repos yourself on github.com.

Have the agent install them

  1. Ask for the installs

    Say this
    Install whatever is missing from git, node and the GitHub CLI (gh). Use the right method for this computer: winget on Windows; on a Mac, Homebrew if I have it, or xcode-select --install for git. If a step needs my password or a click in an installer window, stop and tell me exactly what to do.
  2. Approve and click through

    The agent may ask before each install. Read the command, then allow it. Windows may ask whether to allow changes to your device, and a Mac may ask for your password. Both are normal for an install.

    If an installer window opens, keep the defaults.

  3. Restart VS Code

    Close every VS Code window, then open VS Code again. It only finds new tools when it starts.

  4. Sign the GitHub CLI in to your account

    Open the terminal with View → Terminal. Type this and press Enter:

    Terminal
    gh auth login

    Answer with the arrow keys and Enter. Choose GitHub.com, then HTTPS. Say yes when it offers to use your GitHub login for Git. Choose to log in with a web browser. It shows a one-time code. Note it, press Enter to open GitHub in your browser, enter the code there and authorize.

    Not sure what to pick? Ask the agent to walk you through it:

    Say this
    Walk me through signing in to the GitHub CLI with gh auth login, one question at a time.
  5. Set main, then check everything

    Say this
    Set git's default branch for new repos to main. Then show me the versions of git, node and gh, and confirm gh is logged in.

If the agent can't install them

Mac

Windows

If it goes wrong

It says git, node or gh is "not recognized" or "not found", but I just installed it

VS Code is still using the old settings from before the install. Close every VS Code window and open it again. On Windows, if that doesn't help, restart the computer.

What the agent runs for you

The exact commands depend on your computer. They look like this:

# Windows (the --accept flags answer winget's yes/no questions,
# which the agent can't type)
winget install --id Git.Git -e --source winget --accept-source-agreements --accept-package-agreements
winget install --id OpenJS.NodeJS.LTS -e --source winget --accept-source-agreements --accept-package-agreements
winget install --id GitHub.cli -e --source winget --accept-source-agreements --accept-package-agreements

# Mac
xcode-select --install
brew install node
brew install gh

# After the restart: new repos start on main, then the check
git config --global init.defaultBranch main
git --version
node -v
gh --version
gh auth status

Saved only in this browser.

On a Mac? Skip the Windows page and go to Trusted folders