From 7c40b0017ef98c03e9f934db1e26276993d8c9d4 Mon Sep 17 00:00:00 2001 From: Denis Silakov Date: Wed, 18 Feb 2015 14:44:49 +0300 Subject: [PATCH] abf rpmbuild: do not fetch if there is no .abf.yml --- abf.py | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/abf.py b/abf.py index 4cdb196..1c1fe01 100755 --- a/abf.py +++ b/abf.py @@ -587,10 +587,13 @@ def localbuild_rpmbuild(): if os.path.exists(src_dir): shutil.rmtree(src_dir) src = get_root_git_dir() - cmd = ['abf', 'fetch'] - if command_line.verbose: - cmd.append('-v') - execute_command(cmd, print_to_stdout=True, exit_on_error=True) + + if os.path.isfile(".abf.yml"): + cmd = ['abf', 'fetch'] + if command_line.verbose: + cmd.append('-v') + execute_command(cmd, print_to_stdout=True, exit_on_error=True) + shutil.copytree(src, src_dir, symlinks=True) spec_path = find_spec(src_dir)