Have you seen 
https://github.com/huxi/huxi-gradle-plugins/tree/master/git-state-plugin ?
It uses jgit to retrieve the commit id and (e.g. in case of a release build) 
makes sure that the local git repository does not contain any uncommitted 
changes.

As always, feel free to take whatever you consider useful.

Cheers,
Jörn.

On 08.10.2012, at 14:09, Szczepan Faber <[email protected]> wrote:

> Hey Russel,
> 
> Yeah, there're few improvements that determineCommitId still needs.
> For now, you can work around by -x'ing this task.
> 
> Cheers!
> 
> On Thu, Oct 4, 2012 at 1:16 PM, Russel Winder <[email protected]> wrote:
>> After a period awayI tried updating my clone of the Gradle repository
>> and building from it.  Sadly I get:
>> 
>>        […]
>>        :cli:jar
>>        :determineCommitId FAILED
>> 
>>        FAILURE: Build failed with an exception.
>> 
>>        * Where:
>>        Script '/home/Checkouts/Git/Git/Gradle/gradle/buildReceipt.gradle' 
>> line: 72
>> 
>>        * What went wrong:
>>        Execution failed for task ':determineCommitId'.
>>> java.io.FileNotFoundException: 
>>> /home/Checkouts/Git/Git/Gradle/.git/refs/heads/master (No such file or 
>>> directory)
>> 
>>        * Try:
>>        Run with --stacktrace option to get the stack trace. Run with --info 
>> or --debug option to get more log output.
>> 
>>        BUILD FAILED
>> 
>>        Total time: 41.741 secs
>> 
>> The file is definitely not there, and my checkout is up to date, so I
>> guess there is an assumption made about Git, which has to be a bad move
>> in a build?
>> 
>> --
>> Russel.
>> =============================================================================
>> Dr Russel Winder      t: +44 20 7585 2200   voip: sip:[email protected]
>> 41 Buckmaster Road    m: +44 7770 465 077   xmpp: [email protected]
>> London SW11 1EN, UK   w: www.russel.org.uk  skype: russel_winder
> 
> 
> 
> -- 
> Szczepan Faber
> Principal engineer@gradleware
> Lead@mockito
> 
> ---------------------------------------------------------------------
> To unsubscribe from this list, please visit:
> 
>    http://xircles.codehaus.org/manage_email
> 
> 


---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply via email to