In this blog post, I am writing how you can set up
git a version control system in your computer system and connect and authenticate it with github.
open terminal and check if git is already installed
if it is already installed, git version will be the output:
git version 2.5.0
If not installed Download and install git from https://git-scm.com/download/linux -you will find the command for your distro accordingly, some common are listed here:
yum install git
dnf install git
apt-get install git
If git is already installed we can get/update latest version of git by git itself
git clone https://github.com/git/git
Setting Git username
In terminal, lets setup username
git config --global user.name "username"
This will be written in a file
You can check username with
git config --global user.name
Setting email address
in terminal add your github email address
git config --global user.email "[email protected]"
git config --global user.email
note: we are adding username and email address for every repository on our computer
Authenticating with GitHub from Git
There are two ways to connect with Github from our computer with git.
- With HTTPS
- With ssh
Here I am explaining about the HTTPS
We can push/commit/pull or do any operations on our github repo.
- go to github.com
- create a new repository
add the changes
git add .
git commit -m "your message"
add remote by
git remote add origin https://github.com/username/repository_name.git
we can get origin address in repo’s setting too while creating repo
after adding origin,we are ready to push to github
git push -u origin master
Posts you might like
Quick how to guide on withdrawing your Google Adsense payment via Western Union remittance payment in Nepal. read more
A curated list of ecommerce sites currently operating in Nepal providing different online shopping experience to Nepalese in different sectors. read more
Sharing a piece of my story on how Google Photos eased my photo management. read more
International Space Apps 2017 held in Kathmandu, Nepal, Why should you participate in hackathons like NASA Space Apps, about the event blog and more. read more
all you need to know starting from very basic to advanced level of administrating Oracle Database 11g R2 edition. Also, this will be a supplement resource for TU Bsc CSIT... read more
Installing Oracle Database 11g R2 with Docker on Linux is pretty easy and saves time and effort. In a matter of few minutes, you will have your Oracle database up... read more
Now, you don't need a credit/debit card to buy Viber Out Credits in Viber to make call to different numbers even when they don't have viber. read more
Github's navbar is black now! And yeah it didn't appeal me. More design changes coming soon. read more
Nepal Telecom just launched 4g service for the first time in Nepal today. To actiate 4G in your mobile follow these steps read more
Clash Royale gaming app becomes app of the year in app store. Read who made to the top 10 best games of the year 2016. read more
Prisma a fancy photo editing app becomes app of the year in app store. Read who made to the top 10 best apps of the year 2016. read more
Explaining to you, how you can configure DNS for sub domains in site5 site to github page sites in easiest manner. read more
The most used and liked technological products and innovations either developed in Nepal or the general public platforms that have brought major changes in the lifestyle of Nepalese people. Also,... read more
Remove 360cn Chinese malware from your computer in easiest manner read more
Install the biggest update from apple to your iphone, ipad or any iOS device, the new iOS 10 is out now to the public. Install it today. read more
Live stream to facebook from your laptop or desktop computer in easiest way using OBS read more
Internet/3g/GPRS/4G/LTE Configuration setting for Nepal Telecom(NTC) and Ncell in an iphone in easiest way read more
fbstatic-a.akamaihd.net is a Content Delivery Network(CDN) used by facebook read more
You might have got irritated everytime seeing two windows of Sublime Text Editor being opened every time you open Sublime. Here is a quick fix to it. read more