Skip to content

A list of commonly used Git commands

Notifications You must be signed in to change notification settings

Linicks/Git-Commands

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 

Repository files navigation

Git Commands

A list of commonly used Git commands:

Command Description
git init Initialize a local Git repository
git status Check status
git add [file-name.txt] Add a file to the staging area
git commit -m "[commit message]" Commit changes
git log View changes
git log --summary View changes (detailed)
git remote add origin ssh://[email protected]/joshnh/[repository-name].git Add a remote repository
git remote set-url origin ssh://[email protected]/joshnh/[repository-name].git Set a repository's origin branch to SSH
git push -u origin [branch name] Push changes to remote repository (first time)
git push Push changes to remote repository (subsequent times)
git pull origin [branch name] Pull changes from remote repository
git clone ssh://[email protected]/joshnh/[repository-name].git Create a local copy of a remote repository
git push origin --delete [branch name] Delete a remote branch
git rm -r [file-name.txt] Remove a file (or folder)

About

A list of commonly used Git commands

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published