Guide

beginner

Git and GitHub for vibe coders

Updated 2026-10-15. Sourced from vendor docs · verified 15 Oct 2026 · hands-on test pending wherever a sentence depends on a vendor page.

Git remembers versions of your files. GitHub is a website that stores that history and lets you propose a change.

Answer

A repo is a project plus its history. A commit is a saved checkpoint with a sentence about what changed. GitHub hosts the repo. You can vibe-code without git for an afternoon, and you should add it before a second person, or a second agent, touches the files.

Beginner path

The five words

  • Repo. The project folder plus the history of changes.
  • Commit. A checkpoint. It has a message, such as "Add the tip jar button."
  • Branch. A side copy of the history so an experiment does not wreck the main line.
  • Push. Upload your commits to GitHub.
  • Pull request. Ask to merge a branch, and look at the diff first.

GitHub's own getting-started docs are the reference if a word here is too short. This page is the vibe-coder version.

Commands you can type

Run these in the project folder after Git is installed:

git status
git add .
git commit -m "Add the tip jar page"
git push

git add . stages everything git can see. If status shows a file named .env, do not add it. Skip to the keys guide.

Ask an agent to commit
Look at git status.
Commit only the homepage change.
Do not stage .env or any file you do not mention in the message.
Use the message "Update the tip jar headline."
  • git status shows only files I expect.
  • No .env in the commit.
  • The commit message says what changed.
  • I can open the repo on GitHub.

Advanced path

Agents and history

Tell the agent which branch it may use. "Work on a branch named fix-headline" beats "clean this up" on main.

GitHub secret scanning runs automatically on public repositories and looks through git history for known credential types. A key in an old commit still counts. Rotating the key matters more than rewriting history. The keys guide links the docs.

If two agents edit the same branch, you will get a mess of overlapping diffs. One branch, one agent, then a commit, then the next agent.

Next step

Questions

Can the agent commit for me?

Yes, if you ask it to, and only after you have looked at git status. Tell it not to add files you do not recognize, and never to commit a secret.

What is a pull request?

A pull request is a proposal to merge one branch into another, usually with a page of comments on GitHub. It is a review step, not a deploy.

Sources