mirror of
https://git.yoctoproject.org/poky
synced 2026-05-31 00:39:46 +00:00
oeqa.utils.git: use --verify in rev_parse()
We use rev-parse for turning git object names into SHA-1 and checking their existence. Using --verify option makes sure git-rev-parse does what we expect. (From OE-Core rev: f5b420c7f07a008c11d492b055c7cc8869f644d3) 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>
This commit is contained in:
committed by
Richard Purdie
parent
a7c686cfe6
commit
0aafcddab0
@@ -64,7 +64,7 @@ class GitRepo(object):
|
|||||||
def rev_parse(self, revision):
|
def rev_parse(self, revision):
|
||||||
"""Do git rev-parse"""
|
"""Do git rev-parse"""
|
||||||
try:
|
try:
|
||||||
return self.run_cmd(['rev-parse', revision])
|
return self.run_cmd(['rev-parse', '--verify', revision])
|
||||||
except GitError:
|
except GitError:
|
||||||
# Revision does not exist
|
# Revision does not exist
|
||||||
return None
|
return None
|
||||||
|
|||||||
Reference in New Issue
Block a user