Skip to content. | Skip to navigation

Sections
Personal tools
What is this?
Hi, my name is Tom Lazar and I'm a Plone and Zope developer based in Berlin, Germany and this is my personal and professional (no big difference, really...) website.
 

Git command aliases

Filed Under:

Not everything in svn is worse than in git!

One of the nice features of subversion are its built-in command aliases, i.e. instead of having to type svn commit you can just use svn ci, instead of propertyedit just type pe.

git doesn't have those, which some find annoying. However, you can easily remedy this by adding an [alias] section to your ~/.gitconfig file. Upon request and because it's really a nice feature here's an example for that from my own configuration. I've copied it myself mostly from Andi, who is as much more prolific than I as he is lazier to blog ;-)

Anyway, here it goes:

[core]
    excludesfile = /Users/tomster/.gitignore
    pager = "/opt/local/bin/less -RciqMSj5"
    editor = mate -w

[color]
    diff = auto
    branch = auto
    status = auto

[diff]
    renames = true

[alias]
    st = status
    d = diff
    ci = commit -v
    cia = commit -v -a
    co = checkout
    cp = cherry-pick
    l = log
    ll = log -p
    lt = log trunk..
    llt = log -p trunk..
    lm = log master..
    llm = log -p master..
    b = branch

The .gitignore file referenced above looks like this (and should look rather familiar to svn users):

.svn
*.egg-info
*.pyc
.DS_Store
tmtags

Update: @philikon found the FM :-)

Thanks!

Posted by Anonymous User at Jan 12, 2009 09:37 AM
With those Git aliases I no longer find it annoying :). It's a bit tedious having to configure these on every machine, but I can live with that.
philiKON

additional data

Posted by Anonymous User at Jan 12, 2009 12:25 PM

it is also nice to have user data in .gitconfig [user] name = Rok Garbas email = my.super@email.com

RENTAL

Posted by Anonymous User at Jul 13, 2009 08:10 AM

Some critics complain that it creates the potential for landlords to set price floors, even during the most volatile housing market in living memory. Though those fears are valid, Rentometer can be a tool for tenants as well, as they could find out they shouldn't need to getting payday cash loans for an apartment, and keep landlords honest.

replica watches

Posted by Anonymous User at Nov 11, 2009 02:18 AM

Fakes Watches|Replica Soccer Jersey| Replica Watches,Fake Watches,Replica Watch,Fake Watch,Wholesale Watches,Wholesale Replica Watches,Jewelry Watches,Replica Jewelry Watches. Replica Watches|Vacheron Fake Watches|Fake Patek Philippe Watches|Titoni Replica Watch|Swiss Fake Watches|English uniform|National Jersey|Soccer Jersey Wholesale|Replica Mexico Jersey|

Re:

Posted by Anonymous User at Feb 27, 2010 10:55 AM

thanks

Posted by Anonymous User at Mar 12, 2010 09:15 AM

This article is very helpful, thank you ! classified ads |job listings|faucets