-
Notifications
You must be signed in to change notification settings - Fork 1
/
Day3&4 gitcommands.txt
36 lines (28 loc) · 1.37 KB
/
Day3&4 gitcommands.txt
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
27
28
29
30
31
32
33
34
35
36
Day-3 & 4 Commands:
-------------------
Initial Registering Commands:
-----------------------------
- git config --global user.name "Your_Name": This is for registering your name initial time
- git config --global user.email "Your_Email": This is for registering your email initial time
Initialise Git in Local System for Push or Pull:
------------------------------------------------
1. git init: For initialise the git for tracking and version control purpose
2. git add File_Names(f1,f2,...) : For adding files into staging area
2. git add .
3. git commit -m "Type_Message_Here" : For moving files into tracking Area
4. git remote add Remote_Name Branch_Name : For Creating remote b/w local Git and Github Server
5(a). git push Remote_Name Branch_Name : For adding files from local to Github Server
5(b). git pull Remote_Name Branch_Name : For getting files from Github Server to local
Other Commands:
--------------
- git status : For checking our file location status
- git diff : Identifing modification before and after updating the file
- git checkout key: Moving one version to another version
- git config --global --get-all user.name
- git config --global --get-all user.email
- git log
- git log --oneline
Downloading Total Project into Local System:
--------------------------------------------
- git clone "Url_From_Github"
- git clone "Url_From_Github" "User_Required_ProjectName"