Merge "add reference-repo option to scm git submodule"
This commit is contained in:
commit
e3c5203bc1
@ -171,6 +171,8 @@ def git(parser, xml_parent, data):
|
||||
* **tracking** (`bool`) - Retrieve the tip of the configured
|
||||
branch in .gitmodules (Uses '\-\-remote' option which requires
|
||||
git>=1.8.2)
|
||||
* **reference-repo** (`str`) - Path of the reference repo to use
|
||||
during clone (optional)
|
||||
* **timeout** (`int`) - Specify a timeout (in minutes) for
|
||||
submodules operations (default: 10).
|
||||
* **timeout** (`str`) - Timeout for git commands in minutes (optional)
|
||||
@ -369,6 +371,8 @@ def git(parser, xml_parent, data):
|
||||
data['submodule'].get('recursive', False)).lower()
|
||||
XML.SubElement(ext, 'trackingSubmodules').text = str(
|
||||
data['submodule'].get('tracking', False)).lower()
|
||||
XML.SubElement(ext, 'reference').text = str(
|
||||
data['submodule'].get('reference-repo', ''))
|
||||
XML.SubElement(ext, 'timeout').text = str(
|
||||
data['submodule'].get('timeout', 10))
|
||||
if 'timeout' in data:
|
||||
|
@ -49,6 +49,7 @@
|
||||
<disableSubmodules>false</disableSubmodules>
|
||||
<recursiveSubmodules>true</recursiveSubmodules>
|
||||
<trackingSubmodules>false</trackingSubmodules>
|
||||
<reference/>
|
||||
<timeout>10</timeout>
|
||||
</hudson.plugins.git.extensions.impl.SubmoduleOption>
|
||||
</extensions>
|
||||
|
@ -36,6 +36,7 @@
|
||||
<disableSubmodules>true</disableSubmodules>
|
||||
<recursiveSubmodules>true</recursiveSubmodules>
|
||||
<trackingSubmodules>true</trackingSubmodules>
|
||||
<reference>/jenkins_home/.gitcache/submodules</reference>
|
||||
<timeout>15</timeout>
|
||||
</hudson.plugins.git.extensions.impl.SubmoduleOption>
|
||||
<hudson.plugins.git.extensions.impl.WipeWorkspace/>
|
||||
|
@ -5,4 +5,5 @@ scm:
|
||||
disable: true
|
||||
recursive: true
|
||||
tracking: true
|
||||
reference-repo: /jenkins_home/.gitcache/submodules
|
||||
timeout: 15
|
||||
|
Loading…
Reference in New Issue
Block a user