Table of contents
IN SIMPLE STEPS, HOW TO UPLOAD YOUR PROJECT IN GITHUB USING GIT?
Here are the basic steps to push your project to Github using Git:
Initialize a Git repository in your local project directory:
# CREATE A FOLDER IN YOUR OPERATING SYSTEM AS SHOWN ABOVE # PASTE ALL THE FILES TO THAT FOLDER # --------- USE THIS COMMAND------------ $ git init
Add all files in the project directory to the repository:
# AFTER PASTING ALL THE FILES TO THAT FOLDER USE THE BELOW COMMAND # --------- USE THIS COMMAND------------ $ git add .
Commit the changes with a descriptive message:
# AFTER ADDING THE FILES # BRIEF OUT WHAT HAS BEEN DONE IN THAT COMMIT SO THAT OTHERS & YOU CAN KNOW. # --------- USE THIS COMMAND------------ $ git commit -m "Initial commit"
Create a new repository on GitHub and copy the repository URL:
# NOW GO TO GITHUB # GO TO REPOSITORIES # CLICK ON NEW AS SHOWN BELOW
# CLICK ON NEW BUTTON # NOW GIVE A REPOSITORY NAME #EXAMPLE: I GAVE NAME AS BLOGS
Add the GitHub repository as a remote to your local repository:
# SO AS SHOWN ABOVE A HTTPS LINK WILL BE CREATED # COPY THE URL # --------- USE THIS COMMAND------------ $ git remote add origin <repository-URL> # EXAMPLE: $ git remote add origin https://github.com/k1427/BLOGS.git
Push the changes to Github:
$ git push -u origin master
You can verify that your project is now on Github:
I HOPE THIS BLOG HELPES YOU TO GET AN IDEA OF HOW TO PUSH YOUR PROJECTS TO GITHUB.
I will be back again with some amazing content soon!!!.