Recover --name-only and properly fix Python 3.5 syntax

This commit is contained in:
Jochen Sprickerhof 2022-09-15 08:47:43 +02:00 committed by Hans-Christoph Steiner
parent 490e3a3bdb
commit 049add8dd8
No known key found for this signature in database
GPG key ID: 3E177817BA1B9BFA

View file

@ -14,11 +14,10 @@ target_ref = os.getenv('TARGET_REF')
source_ref = os.getenv('SOURCE_REF') source_ref = os.getenv('SOURCE_REF')
for appid in sorted(changed): for appid in sorted(changed):
metadata_file = 'metadata/' + appid +'.yml' metadata_file = 'metadata/{appid}.yml'.format(**locals())
diff = subprocess.check_output( diff = subprocess.check_output(
( (
'git diff --no-color --diff-filter=d ' + target_ref + 'git diff --no-color --diff-filter=d {target_ref}...{source_ref} -- {metadata_file}' .format(**locals())
'...' + source_ref + ' -- ' + metadata_file
).split(' ') ).split(' ')
) )
@ -83,8 +82,7 @@ for appid in sorted(changed):
signatures_dir = 'metadata/%s/signatures/' % appid signatures_dir = 'metadata/%s/signatures/' % appid
diff = subprocess.check_output( diff = subprocess.check_output(
( (
'git diff --no-color --diff-filter=d ' + target_ref + 'git diff --name-only --no-color --diff-filter=d {target_ref}...{source_ref} -- {signatures_dir}'.format(**locals())
'...' + source_ref + ' -- ' + signatures_dir
).split(' ') ).split(' ')
) )
for f in diff.split(): for f in diff.split():