How to use Github Ubuntu

GitHub is a web-based hosting service for software development projects that use the Git revision control system. GitHub offers both paid plans for private repositories, and free accounts for open source projects. As of May 2011, GitHub was the most popular open source code repository site. And I’ve started using it lately on both on Ubuntu and Windows and from my personal expirience I want to say that here the windows (8) app is a lot easier to use and saves a lot of time. But how ever I think there is no need for a tutorial on how to use Github with the windows app so I am going to explain to you how to use it through Ubuntu.

Ubuntu:
First you need to configurate your user name and email by using the commands:
git config –global user.name “username”
git config –global user.email “Email”

https://powerworr.wordpress.com/gallery/#jp-carousel-127

The next thing is to initialize an empty repository and copy yours there. This is made by using using the HTTP link and the following commands:
git init
git clone “repositoryURL”



https://powerworr.wordpress.com/gallery/#jp-carousel-128
https://powerworr.wordpress.com/gallery/#jp-carousel-130

After that you need to enter your cloned repository and copy your files inside or just start working there, which is the better option in my opinion.

https://powerworr.wordpress.com/gallery/#jp-carousel-131

And we are just few steps away from the end. When you have done this just add the files to your commit, actually commit and push everything to your online repository:

git add . (where the dot is used to add all new files to the commit)
git commit -m “theReason” (you need to use -m “text”, where text is the reason for your commit)
git push


https://powerworr.wordpress.com/gallery/#jp-carousel-135

When you use “git push” you’ll get a message that tells you to write your Github username and password. When you write them both you are ready with everything and you can go to your repository in Github.com and look the new added files.

https://powerworr.wordpress.com/gallery/#jp-carousel-136

Advertisements