[gnome-continuous-yocto/gnomeostree-3.28-rocko: 2086/8267] oeqa.utils.git: implement init() method
- From: Emmanuele Bassi <ebassi src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-continuous-yocto/gnomeostree-3.28-rocko: 2086/8267] oeqa.utils.git: implement init() method
- Date: Sat, 16 Dec 2017 22:44:11 +0000 (UTC)
commit 6d9c52fe4b6c8789bb81bbc469c9f418edaef244
Author: Markus Lehtonen <markus lehtonen linux intel com>
Date: Mon Aug 15 15:19:44 2016 +0300
oeqa.utils.git: implement init() method
Method for doing 'git init'.
(From OE-Core rev: c848e1dac68cd859a563a82286f8bc5ddabaa423)
Signed-off-by: Markus Lehtonen <markus lehtonen linux intel com>
Signed-off-by: Ross Burton <ross burton intel com>
Signed-off-by: Richard Purdie <richard purdie linuxfoundation org>
meta/lib/oeqa/utils/git.py | 6 ++++++
1 files changed, 6 insertions(+), 0 deletions(-)
---
diff --git a/meta/lib/oeqa/utils/git.py b/meta/lib/oeqa/utils/git.py
index ca84680..ae85d27 100644
--- a/meta/lib/oeqa/utils/git.py
+++ b/meta/lib/oeqa/utils/git.py
@@ -35,6 +35,12 @@ class GitRepo(object):
cmd_str, ret.status, ret.output))
return ret.output.strip()
+ @staticmethod
+ def init(path):
+ """Initialize a new Git repository"""
+ GitRepo._run_git_cmd_at('init', cwd=path)
+ return GitRepo(path, is_topdir=True)
+
def run_cmd(self, git_args, env_update=None):
"""Run Git command"""
env = None
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]