[Soc-2014-dev] sharing some git aliases

Campbell Barton ideasman42 at gmail.com
Sat Jul 26 13:22:15 CEST 2014


Some I found handy:

----
Find out what I did over the last week - using media-wiki syntax for
GitCommit & BugReport (nice for writing weekly logs)

  git log --stat --decorate --format="%C(yellow){{GitCommit|%h}}%n
%C(green) %B%Creset" --author="Campbell Barton" --since=1.weeks | perl
-e "s/\bT(\d+)\b/\{\{BugReport\|\$1\}\}/" -pi

----
Aggressive gc, (remove rubbish from stashes and deleted branches)

  git -c gc.reflogExpire=0 -c gc.reflogExpireUnreachable=0 -c
gc.rerereresolved=0 -c gc.rerereunresolved=0 -c gc.pruneExpire=now gc
--aggressive

On Fri, Jul 25, 2014 at 2:29 AM, Grigory Revzin <revzingg at gmail.com> wrote:
> Lovely stuff, thanks
>
>
> On Thu, Jul 24, 2014 at 3:31 PM, brita <britalmeida at gmail.com> wrote:
>>
>> hey all,
>> these are some aliases I use everyday with git that may be useful for
>> you/other students:
>>
>> [alias]
>>
>>         ## run on fridays to make the report of my weekly progress
>>         lgme = log --graph --pretty=tformat:'%h
>> %C(cyan)[%ar]%C(reset)%Cgreen%d%Creset %s - %C(yellow dim)%an%C(reset)'
>> --all --since 1week --author Ines
>>
>>         ## morning merge (stash first if needed)
>>         socmerge = "!git fetch;git submodule foreach git pull origin
>> master;git merge origin/master"
>>
>>         ## these I used previously to gsoc, to pull the addons repos and
>> translations too
>>         pullb = "!git pull;git submodule foreach git pull origin master"
>>         fs = submodule foreach git
>>
>>         ## usage like > git lg 3days --more --parameters --here
>>         lg = log --graph --pretty=tformat:'%h
>> %C(cyan)[%ar]%C(reset)%Cgreen%d%Creset %s - %C(yellow dim)%an%C(reset)'
>> --all --since
>>         lg1 = log --graph --pretty=tformat:'%h
>> %C(cyan)[%ar]%C(reset)%Cgreen%d%Creset %s - %C(yellow dim)%an%C(reset)'
>> --all --since 1days
>>
>> The rest of my gitconfig is at
>> http://wiki.blender.org/index.php/User:Brita/configs/git
>>
>> --Inês
>>
>> _______________________________________________
>> Soc-2014-dev mailing list
>> Soc-2014-dev at blender.org
>> http://lists.blender.org/mailman/listinfo/soc-2014-dev
>>
>
>
>
> --
> Г. Г. Ревзин
>
> _______________________________________________
> Soc-2014-dev mailing list
> Soc-2014-dev at blender.org
> http://lists.blender.org/mailman/listinfo/soc-2014-dev
>



-- 
- Campbell


More information about the Soc-2014-dev mailing list