-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathGit commnds
26 lines (17 loc) · 853 Bytes
/
Git commnds
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
upload files /folders to existing repository github
1) cd to the folder where you want to add the git repo
2) initialize Git so you can start using Git commands inside the folder.
git init
3) To display the state of the working directory (which changes have been staged)
git status
4) Add them to your local Git repository
git add <file/folder_path>
5) Commit the added files
git commit -m "commmit first"
6) Since you haven’t connected to the GitHub repo yet, your computer doesn’t even know this exists.
So tell your local repository about it:
git remote add origin <git_url>
7) And double check to make sure it knows:
git remote -v
8) upload the files :
git push -u origin master