Useful Commands work with Github SCM

91 Likes Comment
Install git on Macbook via Homebrew:
brew install git

Verify the installation:

git --version

Connect to the github account. By using github username and personal access tokens

git config --global "your_github_username"
git config --global "[email protected]"

To create the personal access tokens as github password : From page, hit your github account avatar , then select Settings -> Developer Settings -> Personal Access Tokens -> Generate new token -> Configure the permission and copy the key.

Working with github from your local computer

echo "# mylabtest" >>
git init
git add
git commit -m "first commit"
git branch -M main
git remote add origin
git push -u origin main

push an existing repository from the command line

git remote add origin
git branch -M main
git push -u origin main

You might like

About the Author: Toc Xoan

This guy likes taking photos, hunting cheap tours, exploring the unique culture of every cities of Vietnam. Contact: [email protected]. I've created a dogecoin wallet to receive blog funding: DE6F5FisSCy7yz5rpHY1ChMSGYnDMpFZ1Q

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.