Skip to content

muhammedmarwan/BasicGitGuide

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 

Repository files navigation

Git Basics
----------

Git config --global user.name "yourname"                  --Set your Git username
git config --global user.email "your_email"               --Set your Git email

git init                                                  --Start a new Git project
git status                                                --View changes status
git branch -m (branch_name)                               --Rename/Create a branch
git add .                                                 --Add all files to staging
git add (file_name)                                       --To add a specific file to staging
git commit -m "message"                                   --Commit changes
git log                                                   --View commit logs

git remote add (remote_name) (remote_url)                 --Add a remote (GitHub/GitLab)
git push (remote_name) (branch_name)                      --Push commits to remote repo
git clone (link)                                          --Clone a repository
git checkout (branch_name)                                --Switch branches


git pull                                                  --Download and merge latest remote changes
git fetch                                                 --Download remote changes without merging
git merge origin/main                                     --Merge fetched changes into current branch

About

GIT BASICS :

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors