Last active
October 26, 2017 18:36
-
-
Save banhaclong20/cbb807cef742bff3fc200620ae6ed5b3 to your computer and use it in GitHub Desktop.
Adding an existing project to GitHub using the command line
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1. Create a new repository on GitHub. | |
2. In Terminal, change the current working directory to your local project. | |
git init | |
git add . | |
or: | |
git add --all | |
git commit -m 'First commit' | |
git remote add origin <remote repository URL> | |
Sets the new remote: | |
git remote -v origin | |
Push the changes in your local repository to GitHub. | |
git push origin master |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment