Jul 20, 2015 04:04 AM
(This post was last modified: Jul 20, 2015 04:24 AM by ๖ꜦȳpƎƦ SƟƱƿ.)
MANAGE YOUR CODE WITH GIT AND GITHUB(linux)
In this tutorial you will learn how to manage version control with git.
First create a git directory to keep thing clean.
Code
mkdir ~/gitCode
cd ~/gitonce you are in your directory do:
Code
sudo apt-get install gitNow go to GitHub and create an account.
Once you have your account, create your repository.
In your repository copy your HTTPS clone url.
go back to your terminal and type :
Code
git config --global user.name "My Name"Code
git config --global user.email "[email protected]"Code
git clone "yourremoteHTTPSadress"And a folder with the name of your repository should be created!
goto your folder with "cd". if your files are in view only type in the terminal:
Code
chmod 7 "yourfile"Then you need to initialize your remote:
Code
git remote set-url origin "yourhttpscloneadress"now add the files you want git to track changes.
Code
git add "file"Now edit the file you want.
Once edited go to you terminal and type:
Code
git commitand then
Code
git pushyou should be prompted for an username and a password, Use your github credentials.
Done!
this is the end of this tutorial. if you want to know more about git PM me. ✌

