Skip to main content

Command Palette

Search for a command to run...

Github Fundamentals

Updated
1 min read

Step #1 — git init

This command initializes a new Git repository in your project directory. It creates a hidden .git folder to track changes in your project.

Step #2 — git status

The git status command shows the current state of your project, listing any untracked files or changes that have not yet been staged for commit.

Step #3 — git add .

The git add . command stages all modified or newly added files in your project, preparing them for a commit.

Step #4 — git commit -m “message”

This command commits the staged changes and includes a message describing what changes were made. Be sure to write meaningful messages that summarize the work done.

Step #5 — git pull

The git pull command fetches updates from a remote repository and merges them into your local branch. This is useful to ensure your local work is up-to-date with the remote project.

Step #6 — git push

The git push command uploads your local commits to a remote repository. Make sure you've committed all changes locally before pushing.

Step #7 — git log

This command displays the commit history of the repository, showing commit IDs, messages, and authors. You can scroll through the log to review past commits.