Git is a free & open source, distributed version control system designed to handle everything from small to very large projects with speed and efficiency.
Every Git clone is a full-fledged repository with complete history and full revision tracking capabilities, not dependent on network access or a central server. Branching and merging are fast and easy to do. Git is free software distributed under the terms of the GNU General Public License version 2.
To install ‘Git’ in your fedora, open your console and use the following command.
$ yum install git
Now in your machine, we must setup the “Global Setup”, for this use the open following commands:
$ git config --global user.name "Your Name" $ git config --global user.email firstname.lastname@example.org
“your name” = “yourname”
email@example.com = yourmailid.
Now Create a new directory (This directory name is, which we have to give as “project name” in on-line repo creating)
$ mkdir example
Go to that directory using,
$ cd example $ git init
In this directory, add your codes or your data, which you have to connect with github.
$ touch README $ git add README $ git commit -m 'first commit' (here in quote we must have give some comments)
Creating “github” account on-line:
Go to https://github.com/ and select the “pricing and signup”
Here they are giving some plans. Select one plan as your wish.
For example if you are selecting “create a free account”
create an account and login.
After login, select the “create a new Repository“.
here you have to give “project name” and some details. Then click the “create repository”
Now, here you can see the procedures, which now we done.
Finally, you can see the commands like this,
$ git remote add origin firstname.lastname@example.org:thasuresh/example.git $ git push origin master
now, lets see how will step you through the process of generating a keypair on linux and uploading it to GitHub. We use Ubuntu and bash in this guide, command may vary depending on your linux flavor and shell.
Generating an SSH key on linux is a fairly straightforward process.
$ ssh-keygen -t rsa Generating public/private rsa key pair. Enter file in which to save the key (/home/abcd/.ssh/id_rsa): Enter passphrase (empty for no passphrase): Enter same passphrase again: Your identification has been saved in /home/abcd/.ssh/id_rsa. Your public key has been saved in /home/abcd/.ssh/id_rsa.pub. The key fingerprint is: 01:0f:f4:3b:ca:85:d6:17:a1:7d:f0:68:9d:f0:a2:db
Now open your .ssh/id_rsa.pub using,
$ gedit .ssh/id_rsa.pub
Then, go to your on-line github account and select the “Account Settings”
Here select the “SSH Public Keys”, In key box add your content of “id_rsa.pub”
Now, you can pushup your projects into github account.
That’s all. !!!
Feel free to ask me, if you have any doubts.