Re: scm.gitTool in Jenkinsfile

2016-07-28 Thread Nigel Magnay
Aha - I have found it. BTW - I was already expecting it to be the tool name itself in the manner you're describing (sorry if I wasn't clear about that). If I do the following: echo scm.gitTool; scm.gitTool = 'win-git'; echo scm.gitTool; ​The 1st run through I get Scripts not permitted to use

Re: scm.gitTool in Jenkinsfile

2016-07-28 Thread Mark Waite
I wonder if the sematnics of scm.gitTool are closer to the GitTool object semantics inside the git plugin. GitTool inside the git plugin allows job owner to choose which git implementation will be used. It doesn't allow the job owner to specify the destination of the git executable. You might tr

Re: scm.gitTool in Jenkinsfile

2016-07-27 Thread Nigel Magnay
The host it builds on is not under my control. Is manipulating fields in scm not supposed to work? On Thursday, 28 July 2016, nicolas de loof wrote: > Any reason you don't set git in default path ? Would be so simpler ;) > Le 27 juil. 2016 10:56 PM, "Nigel Magnay" > a écrit : > >> No, as it's

Re: scm.gitTool in Jenkinsfile

2016-07-27 Thread nicolas de loof
Any reason you don't set git in default path ? Would be so simpler ;) Le 27 juil. 2016 10:56 PM, "Nigel Magnay" a écrit : > No, as it's not on the path so would not be found. > > Oddly, if I do > scm.gitTool = 'win git' > echo scm.gitTool > > it responds with 'null' - so something is odd in the f

Re: scm.gitTool in Jenkinsfile

2016-07-27 Thread Nigel Magnay
No, as it's not on the path so would not be found. Oddly, if I do scm.gitTool = 'win git' echo scm.gitTool it responds with 'null' - so something is odd in the field setter :-/ On Wed, Jul 27, 2016 at 9:53 PM, Mark Waite wrote: > Have you tried configuring your git executable to be "git" rath

Re: scm.gitTool in Jenkinsfile

2016-07-27 Thread Mark Waite
Have you tried configuring your git executable to be "git" rather than "/usr/bin/git"? That's what I've used in multi-platform environments and it has worked well for me. Mark Waite On Wed, Jul 27, 2016 at 1:57 PM Nigel Magnay wrote: > In a bitbucket-sourced multibranch repository, I need to e

scm.gitTool in Jenkinsfile

2016-07-27 Thread Nigel Magnay
In a bitbucket-sourced multibranch repository, I need to ensure the git checkout doesn't occur with /usr/bin/git, but with a tool that stands a chance of executing on Windows. I had rather hoped it would simply be the case of doing scm.gitTool = 'win git'; before my checkout scm But it still se