GitHub fast and simple set up tutorial for developers v1
Hey there my gorgeous developer ✌️. How are you today?
I’m sure you’ve got some projects on your PC and you must be very proud of ’em, ’cause I’m proud of mine 😉. But have you actually wondered loosing them, maybe your younger one deleted some if not all by mistake, I mean permanent deletion or you sold your PC without copying them to a disk or hard drive? 🙆🏻♂️
Well, all thanks to GitHub for saving us from such terrible scenarios. 💞
Briefly, let’s learn how to set up GitHub for usage. Sit back and read.
Create a GitHub account if you haven’t.
Give the Repository a name you want, best to use a name similar to that of the app you want to push to GitHub. Give it a description if you wish to. Then proceed to clicking “Create repository” at the bottom
Getting excited?? Yeah, me too. 🤸🏻
Next up, head to your code editor.
Open the command line and ensure you are in the folder you want to upload to GitHub. Done that already? 👍 Let’s move on. Type the following:
Ensure you are connected to the internet
git init -this initializes a .git in your folder
git config — global user.name “enter your GitHub username”
git config — global user.email “enter the email you created GitHub with”
git status -to know the status of the file
git add . -this adds all the file within that folder to the repository
git commit -m “enter a message about your upload e.g initial commit”
git remote -here we are now trying to connect.
git remote add origin the_link_you_copied
git push -u origin master -this will push it to the master folder within GitHub
git push -just for confirmation 😋
And there you have it. Head to GitHub, within your newly created repository, refresh it, then you’ll see the files there 🥳🥳
Just in case you aren’t seeing it, and the upload was successful in the terminal, you’ve got something important to do, you will have to change the . Follow the procedure below:
There you have it.
I’ll be making a post on how to pull(download) codes from GitHub very soon.
Thank you for reading through, I hope it helped.
Bye 👋🏿