mirror of https://gitee.com/openkylin/libvirt.git
ci: helper: Add Python code hangling git clones
This helper will be utilized by a future patch which will add the lcitool container execution logic. The reason why the required_deps decorator isn't being used here is because this is a property. Signed-off-by: Erik Skultety <eskultet@redhat.com> Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
This commit is contained in:
parent
05d65767cf
commit
24319b2cca
|
@ -159,9 +159,18 @@ class Parser:
|
|||
|
||||
|
||||
class Application:
|
||||
@property
|
||||
def repo(self):
|
||||
if self._repo is None:
|
||||
from git import Repo
|
||||
|
||||
self._repo = Repo(search_parent_directories=True)
|
||||
return self._repo
|
||||
|
||||
def __init__(self):
|
||||
self._basedir = pathlib.Path(__file__).resolve().parent
|
||||
self._args = Parser().parse()
|
||||
self._repo = None
|
||||
|
||||
def _make_run(self, target):
|
||||
args = [
|
||||
|
|
Loading…
Reference in New Issue