Tools: Unify string quoting in the Python sources

This commit is contained in:
Dmitry D. Chernov 2019-07-14 11:15:36 +10:00
commit c4ad3480bd
2 changed files with 9 additions and 9 deletions

View file

@ -11,9 +11,9 @@ def remove_old_files():
os.remove(file)
def download():
repos = subprocess.Popen(['osc', 'repositories'], stdout=subprocess.PIPE)
repos = subprocess.Popen(["osc", "repositories"], stdout=subprocess.PIPE)
for line in repos.stdout:
command = ['osc', 'buildlog', '--last'] + line.split()
command = ["osc", "buildlog", "--last"] + line.split()
filename = "-".join(line.split()) + ".log"
print("Downloading logs using: {}".format(" ".join(command)))
buildlog = subprocess.Popen(command, stdout=subprocess.PIPE)

View file

@ -23,7 +23,7 @@ def get_cflags(language, std, compiler):
"scilab":"-Werror " + c_common,
"tcl":"-Werror " + c_common,
}
if compiler == 'clang':
if compiler == "clang":
cflags["guile"] += " -Wno-attributes" # -Wno-attributes is for clang LLVM 3.5 and bdw-gc < 7.5 used by guile
if language not in cflags:
@ -54,7 +54,7 @@ def get_cxxflags(language, std, compiler):
"scilab":"-Werror " + cxx_common,
"tcl":"-Werror " + cxx_common,
}
if compiler == 'clang':
if compiler == "clang":
cxxflags["guile"] += " -Wno-attributes" # -Wno-attributes is for clang LLVM 3.5 and bdw-gc < 7.5 used by guile
if language not in cxxflags:
@ -64,12 +64,12 @@ def get_cxxflags(language, std, compiler):
import argparse
parser = argparse.ArgumentParser(description="Display CFLAGS or CXXFLAGS to use for testing the SWIG examples and test-suite.")
parser.add_argument('-l', '--language', required=True, help='set language to show flags for')
parser.add_argument("-l", "--language", required=True, help="set language to show flags for")
flags = parser.add_mutually_exclusive_group(required=True)
flags.add_argument('-c', '--cflags', action='store_true', default=False, help='show CFLAGS')
flags.add_argument('-x', '--cxxflags', action='store_true', default=False, help='show CXXFLAGS')
parser.add_argument('-s', '--std', required=False, help='language standard flags for the -std= option')
parser.add_argument('-C', '--compiler', required=False, help='compiler used (clang or gcc)')
flags.add_argument("-c", "--cflags", action="store_true", default=False, help="show CFLAGS")
flags.add_argument("-x", "--cxxflags", action="store_true", default=False, help="show CXXFLAGS")
parser.add_argument("-s", "--std", required=False, help="language standard flags for the -std= option")
parser.add_argument("-C", "--compiler", required=False, help="compiler used (clang or gcc)")
args = parser.parse_args()
if args.cflags: