Archive for the ‘Git’ Category

Git Internals – a diagram

March 31, 2010 Leave a comment

A beautiful diagram from Git Internals:

Highly recommended! Both PDF and screencast are really good.

Categories: Git Tags:

Hudson: Git and Maven plugins

March 27, 2010 7 comments

Suddenly, something went wrong .. 😦
A usual Hudson job pulling sources from Git repository started to fail with NPE:

Parsing POMs
[nexttags-CI] $ c:\Winny\java\jdk1.6.0_18\/bin/java -Xmx1024m -XX:MaxPermSize=512m -cp c:\dev\hudson-slave\maven-agent.jar;C:\Winny\java\apache-maven-2.2.1\boot\classworlds-1.1.jar hudson.maven.agent.Main C:\Winny\java\apache-maven-2.2.1 C:\dev\hudson-slave\slave.jar c:\dev\hudson-slave\maven-interceptor.jar 3841 c:\dev\hudson-slave\maven2.1-interceptor.jar
<===[HUDSON REMOTING CAPACITY]===>channel started
channel stopped
ERROR: Processing failed due to a bug in the code. Please report this to
	at java.util.Hashtable.put(
	at java.util.Hashtable.putAll(
	at hudson.maven.MavenModuleSetBuild$
	at hudson.maven.MavenModuleSetBuild$
	at hudson.remoting.UserRequest.perform(
	at hudson.remoting.UserRequest.perform(
	at hudson.remoting.Request$
	at java.util.concurrent.Executors$
	at java.util.concurrent.FutureTask$Sync.innerRun(
	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(
	at java.util.concurrent.ThreadPoolExecutor$

What ?! But it worked half an hour ago. Hmm, that’s interesting …

After re-installing Hudson from scratch, installing it locally on my machine, going back and forward with versions, creating simple jobs doing absolutely nothing except pulling sources from various Git projects and running "mvn clean" .. I still couldn’t git rid of this error.

Well, it was clearly time for some debugging and .. here we go!

For some reason Git plugin started to pass null value for GIT_BRANCH environment variable.
This caused Maven plugin to fail in System.getProperties().putAll(systemProps) call.

The solution was to use "master" as default Git branch instead of "**" or empty String:

My versions were: Hudson v1.352, Git plugin v0.8.1

Some Hudson links:

Categories: Git, Hudson, Maven Tags: , ,

Git GUI Here

March 20, 2010 Leave a comment

Rather than right-clicking the folder and choosing “Git GUI Here” ..


@echo off
start d:\winny\Git\bin\wish.exe d:\winny\Git\libexec\git-core\git-gui --working-dir %*

assuming msysgit is installed at "d:\winny\Git"

Now, I only need to type "git-gui ." to launch it:

Much better. Hate it when someone forces me to use a mouse ..

Categories: Git, PC Tags: