Difference between revisions of "Git"

From YobiWiki
Jump to navigation Jump to search
m
Line 5: Line 5:
 
* [http://www-cs-students.stanford.edu/~blynn/gitmagic/ Git Magic] tips compilation
 
* [http://www-cs-students.stanford.edu/~blynn/gitmagic/ Git Magic] tips compilation
 
* [http://sysmonblog.co.uk/misc/git_by_example/ Git by example]
 
* [http://sysmonblog.co.uk/misc/git_by_example/ Git by example]
  +
* [http://utsl.gen.nz/talks/git-svn/intro.html An introduction to git-svn for Subversion/SVK users and deserters]
   
 
==Install==
 
==Install==

Revision as of 22:01, 16 September 2008

Links

Install

sudo apt-get install git-svn git-doc git-gui tig

Writing to global ~/.gitconfig file:

git config --global user.name "Your Name Comes Here"
git config --global user.email you@yourdomain.example.com
git config --global color.diff auto
git config --global color.status auto
git config --global color.branch auto

Creating a .git in the current (project) directory:

git init

Using a Subversion server

Getting the full project:

git-svn clone http://subversion.server.com/project -T trunk -b branches -t tags
(git-gc to compress if it took a big room)

Updating the local repository according to the subversion server:

git-svn rebase

Sending the local changes to the subversion server:

git-svn dcommit

Ignoring some files

cat > .gitignore <<EOF
*.pyc
*~
EOF
git add .gitignore