gittip: Use Meson's capture: true for Python 3.6 compatibility (#2869)
This commit is contained in:
parent
48bed79824
commit
2588aa8a1a
3 changed files with 3 additions and 3 deletions
|
|
@ -4067,6 +4067,7 @@ RZ_API char *rz_str_version(const char *program) {
|
|||
if (!gittip || !*rz_str_trim_head_ro(gittip)) {
|
||||
goto done;
|
||||
}
|
||||
rz_str_trim(gittip);
|
||||
rz_strbuf_append(sb, "\n");
|
||||
rz_strbuf_appendf(sb, "commit: %s", gittip);
|
||||
done:
|
||||
|
|
|
|||
|
|
@ -540,6 +540,7 @@ if git_exe.found() and fs.exists('.git')
|
|||
build_by_default: true,
|
||||
output: 'gittip',
|
||||
command: [py3_exe, git_exe_repo_py, git_exe, repo, 'rev-parse', 'HEAD'],
|
||||
capture: true,
|
||||
install: true,
|
||||
install_dir: rizin_bindir
|
||||
)
|
||||
|
|
|
|||
|
|
@ -25,9 +25,7 @@ def isCArgSupported(executable, path):
|
|||
|
||||
def simple_git_execution(args):
|
||||
try:
|
||||
called = subprocess.run(args, check=True, capture_output=True)
|
||||
with open("gittip", "w", encoding="utf8") as f:
|
||||
f.write(called.stdout.decode("utf8").strip())
|
||||
called = subprocess.run(args, check=True)
|
||||
sys.exit(called.returncode)
|
||||
except subprocess.CalledProcessError as e:
|
||||
sys.exit(e.returncode)
|
||||
|
|
|
|||
Loading…
Reference in a new issue