git commands
cflow_list
CFLOW_LIST_B
present working directory---PWD
git version control
bucky video
----------
video link
-----------
https://www.youtube.com/watch?v=mYjZtU1-u9Y&list=PLcaPT6_oTzIclQQjRLU6t3sm5vvWIlrG2
=======1.9 version ==========
commands
git --version
ssh-keygen
password : 123456
enter some where it ask pwd
commands
ls --show list of files
git config --global user.name "narendrae"
git config --global user.email "narendraenamala@gmail.com"
git config --global user.email "narendrae@sathguru.com"
ssh://narendrae@192.9.200.13:29418/ErpAdmin.git
ssh://narendrae@sathguru.com@192.9.200.13:29418/ErpAdmin.git
git clone http://narendrae@192.9.200.13:8585/gitblit/r/ErpAdmin.git
git init gitproject
git add octocat.txt -- <file or>
git add . ( it will add all files to the project folder)
git status -- . this time you notice in green and both these are new files.
git rm --cached octocat.txt ( If you want to remove from satging area )
git status
then it shows the changes with red color
If we want to commit
git commit -m "initial commit"
git log
git status ( it is still showing red mark that removed and also we commited)
git add octocat.txt
git status ( added new file )
git commit -m "start tracking octocat.txt"
git log
go to C:\Documents and Settings\narendrae\Desktop\GitPortable\Data\home\gitproject
above path and change the add some data in readme.txt file
git status ( red color modified)
git commit -m "change readme"
it fails in the reason why?
-- here it says no changes added to commit because
we couldn't move to that staging area. Every commit that staging area cleaned again.
-- so you have to do is
git add .
git commit -m "change readme"
-- go and modify the octocat.txt file
git status
it says modified octocat.txt
-- go and modify the readme.txt
git status
now you notice that both files are modifed
git add . ( If u want to commit you need to adding to the staging area)
git commit -m "another commit"
you go to the folder add a Knew.txt file
git status
( it says new file added)
you go to the folder add a new line into readme.txt file
git status
( it says one file modifed readme.txt and untracked fiel is knew.txt)
git diff
( it shows what are the new lines added in the readme.txt file)
git add readme.txt
git diff
( it doesn't show anything for htat we use below query)
git diff --cahced
( here it shows the diff with staging area)
git status
git add .
git status
git commit -m "new file and changes"
git log
-- go and quickly modify both files and say
git status
( two files modified)
If you want do add to the staging area and commit at a time we use below command
git commit -a -m "Short cut"
( 2 files changed, 2 insertions, 2deletions)
git status
( nothing to commit(working directory clean)
1 last shortcut
go and modify both files and say
git status -s
==
step 1 : git init <project> -- project now repository
step 2 : git add . add all files to staging
step 3 : git commit -m "message" snapshot
git status -- . status of files
git log -- commit history
git diff -- view differences
git diff --cached differecnes in staging
Remote repository
up direction
local repository
up direction
index
up direction
Working directory
===
it will generate a key
ssh-keygen -t rsa -C "narendraenamala@gmail.com"
go to the .ssh folder and copy (C:\Documents and Settings\narendrae\Desktop\GitPortable\Data\home\.ssh)
id_rsa.pub --> copy the ssh key and paste in
github.com --> settings --> ssh key
If you want to check at cmd prompt
type
ssh -T git@github.com
====
-------
git hub
-------
or create a new repository on the command line
echo "# demoproj" >> README.md
git init
git add README.md
git commit -m "first commit"
git remote add origin git@github.com:narendrae/demoproj.git
git push -u origin master
…or push an existing repository from the command line
git remote add origin git@github.com:narendrae/demoproj.git
git push -u origin master
git remote add origin git clone ssh://narendrae@192.9.200.13:29418/ErpComMst.git
-------
git blitt
-------
cd "C:\Users\narendrae\Desktop\jacks"
git config --global user.name "narendra"
git config --global user.email "narendraenamala@gmail.com"
git remote -v ( to check what is the origin server)
to add a server from cmd prompt
git remote add mygit ssh://narendrae@192.9.200.13:29418/Demo2.git
-- git remote add mygitjk ssh://narendrae@192.9.200.13:29418/jacks.git
git remote add gitjk ssh://narendrae@192.9.200.13:29418/~narendrae/Jacks.git
git remote add gitlocal ssh://narendrae@192.9.200.13:29418/Demo2.git
http://narendrae@192.9.200.13:8585/gitblit/r/~narendrae/Jacks.git
source tree clone
jk_fa
------
cd "C:\Users\narendrae\Desktop\fa"
git remote add gitjkfa ssh://narendrae@192.9.200.13:29418/~narendrae/JK_FA.git
git remote add ssh://narendrae@192.9.200.13:29418/ErpComMst.git
git push gitjkfa master
source tree
sourcetree://cloneRepo/
http://narendrae@192.9.200.13:8585/gitblit/r/~sureshp/JK_FA.git
git remote -v
push to the server
you can pull the files from server
git pull mygit master
git push mygit master
git push mygit ui
git checkout master ( u can switch to msater or branch
git checkout ui ( branch)
-- source tree
https://www.youtube.com/watch?v=1I3X8yOvMJ4
sourcetree://cloneRepo/
http://narendrae@192.9.200.13:8585/gitblit/r/~sureshp/Jacks.git
-- new forms upload
git branch forms
git checkout forms
git push mygit forms
( all forms and reprots are uploaded)
removed forms folder at my local drive
git checkout ui
git pull mygit forms
C:\Users\narendrae\Desktop\jk\purinv\BECF007_UNIT_MST.fmb
C:\Users\narendrae\Documents\JK_FA\Desktop\fa\BEFF113_ASSETCATG_MST.fmb
specific fiel update
------------------
git checkout forms -- Narenv/UM_COMP_MST.fmb
after this
last commit checkout files
----------------------------
git checkout ui ( another branch)
git branch ( to know how many branches are available in the project)
---
clone
git clone ssh://sureshp@192.9.200.13:29418/Demo2.git
=====
git commit -m "msg"
git status
git log
git diff
git diff --cashed
msysgit.github.io
http://git-scm.com
/
bitbucket.org
=============================================
ls -la ( to see hidden files)
git log --author="narendraE"
git diff first.txt (to check diffrence)
renaming a file in both areas
git mv first.txt home.txt
/
git help
clone
init
add
mv
reset
rm
bisect
grep
log
show
status
branch
checkout
commit
diff
merge
rebase
tag
fetch
pull
push
git help pull
remove from statging area
-----------------------
git reset HEAD filename.txt
git log -p -1
git log --pretty=online
hash number -- first 6 charc
git log
touch .gitignore -- to ingnore .extension files(will give in gitignore)
git add .gitignore
git remote
git push
press I ---it comes in insert mode
Esc
:wq
CFLOW_LIST_B
present working directory---PWD
git version control
bucky video
----------
video link
-----------
https://www.youtube.com/watch?v=mYjZtU1-u9Y&list=PLcaPT6_oTzIclQQjRLU6t3sm5vvWIlrG2
=======1.9 version ==========
commands
git --version
ssh-keygen
password : 123456
enter some where it ask pwd
commands
ls --show list of files
git config --global user.name "narendrae"
git config --global user.email "narendraenamala@gmail.com"
git config --global user.email "narendrae@sathguru.com"
ssh://narendrae@192.9.200.13:29418/ErpAdmin.git
ssh://narendrae@sathguru.com@192.9.200.13:29418/ErpAdmin.git
git clone http://narendrae@192.9.200.13:8585/gitblit/r/ErpAdmin.git
git init gitproject
git add octocat.txt -- <file or>
git add . ( it will add all files to the project folder)
git status -- . this time you notice in green and both these are new files.
git rm --cached octocat.txt ( If you want to remove from satging area )
git status
then it shows the changes with red color
If we want to commit
git commit -m "initial commit"
git log
git status ( it is still showing red mark that removed and also we commited)
git add octocat.txt
git status ( added new file )
git commit -m "start tracking octocat.txt"
git log
go to C:\Documents and Settings\narendrae\Desktop\GitPortable\Data\home\gitproject
above path and change the add some data in readme.txt file
git status ( red color modified)
git commit -m "change readme"
it fails in the reason why?
-- here it says no changes added to commit because
we couldn't move to that staging area. Every commit that staging area cleaned again.
-- so you have to do is
git add .
git commit -m "change readme"
-- go and modify the octocat.txt file
git status
it says modified octocat.txt
-- go and modify the readme.txt
git status
now you notice that both files are modifed
git add . ( If u want to commit you need to adding to the staging area)
git commit -m "another commit"
you go to the folder add a Knew.txt file
git status
( it says new file added)
you go to the folder add a new line into readme.txt file
git status
( it says one file modifed readme.txt and untracked fiel is knew.txt)
git diff
( it shows what are the new lines added in the readme.txt file)
git add readme.txt
git diff
( it doesn't show anything for htat we use below query)
git diff --cahced
( here it shows the diff with staging area)
git status
git add .
git status
git commit -m "new file and changes"
git log
-- go and quickly modify both files and say
git status
( two files modified)
If you want do add to the staging area and commit at a time we use below command
git commit -a -m "Short cut"
( 2 files changed, 2 insertions, 2deletions)
git status
( nothing to commit(working directory clean)
1 last shortcut
go and modify both files and say
git status -s
==
step 1 : git init <project> -- project now repository
step 2 : git add . add all files to staging
step 3 : git commit -m "message" snapshot
git status -- . status of files
git log -- commit history
git diff -- view differences
git diff --cached differecnes in staging
Remote repository
up direction
local repository
up direction
index
up direction
Working directory
===
it will generate a key
ssh-keygen -t rsa -C "narendraenamala@gmail.com"
go to the .ssh folder and copy (C:\Documents and Settings\narendrae\Desktop\GitPortable\Data\home\.ssh)
id_rsa.pub --> copy the ssh key and paste in
github.com --> settings --> ssh key
If you want to check at cmd prompt
type
ssh -T git@github.com
====
-------
git hub
-------
or create a new repository on the command line
echo "# demoproj" >> README.md
git init
git add README.md
git commit -m "first commit"
git remote add origin git@github.com:narendrae/demoproj.git
git push -u origin master
…or push an existing repository from the command line
git remote add origin git@github.com:narendrae/demoproj.git
git push -u origin master
git remote add origin git clone ssh://narendrae@192.9.200.13:29418/ErpComMst.git
-------
git blitt
-------
cd "C:\Users\narendrae\Desktop\jacks"
git config --global user.name "narendra"
git config --global user.email "narendraenamala@gmail.com"
git remote -v ( to check what is the origin server)
to add a server from cmd prompt
git remote add mygit ssh://narendrae@192.9.200.13:29418/Demo2.git
-- git remote add mygitjk ssh://narendrae@192.9.200.13:29418/jacks.git
git remote add gitjk ssh://narendrae@192.9.200.13:29418/~narendrae/Jacks.git
git remote add gitlocal ssh://narendrae@192.9.200.13:29418/Demo2.git
http://narendrae@192.9.200.13:8585/gitblit/r/~narendrae/Jacks.git
source tree clone
jk_fa
------
cd "C:\Users\narendrae\Desktop\fa"
git remote add gitjkfa ssh://narendrae@192.9.200.13:29418/~narendrae/JK_FA.git
git remote add ssh://narendrae@192.9.200.13:29418/ErpComMst.git
git push gitjkfa master
source tree
sourcetree://cloneRepo/
http://narendrae@192.9.200.13:8585/gitblit/r/~sureshp/JK_FA.git
git remote -v
push to the server
you can pull the files from server
git pull mygit master
git push mygit master
git push mygit ui
git checkout master ( u can switch to msater or branch
git checkout ui ( branch)
-- source tree
https://www.youtube.com/watch?v=1I3X8yOvMJ4
sourcetree://cloneRepo/
http://narendrae@192.9.200.13:8585/gitblit/r/~sureshp/Jacks.git
-- new forms upload
git branch forms
git checkout forms
git push mygit forms
( all forms and reprots are uploaded)
removed forms folder at my local drive
git checkout ui
git pull mygit forms
C:\Users\narendrae\Desktop\jk\purinv\BECF007_UNIT_MST.fmb
C:\Users\narendrae\Documents\JK_FA\Desktop\fa\BEFF113_ASSETCATG_MST.fmb
specific fiel update
------------------
git checkout forms -- Narenv/UM_COMP_MST.fmb
after this
last commit checkout files
----------------------------
git checkout ui ( another branch)
git branch ( to know how many branches are available in the project)
---
clone
git clone ssh://sureshp@192.9.200.13:29418/Demo2.git
=====
git commit -m "msg"
git status
git log
git diff
git diff --cashed
msysgit.github.io
http://git-scm.com
/
bitbucket.org
=============================================
ls -la ( to see hidden files)
git log --author="narendraE"
git diff first.txt (to check diffrence)
renaming a file in both areas
git mv first.txt home.txt
/
git help
clone
init
add
mv
reset
rm
bisect
grep
log
show
status
branch
checkout
commit
diff
merge
rebase
tag
fetch
pull
push
git help pull
remove from statging area
-----------------------
git reset HEAD filename.txt
git log -p -1
git log --pretty=online
hash number -- first 6 charc
git log
touch .gitignore -- to ingnore .extension files(will give in gitignore)
git add .gitignore
git remote
git push
press I ---it comes in insert mode
Esc
:wq
git config --global user.name
Comments
Post a Comment