aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild/templates
diff options
context:
space:
mode:
authorEli Schwartz <eschwartz@archlinux.org>2021-03-04 17:16:11 -0500
committerEli Schwartz <eschwartz@archlinux.org>2021-03-04 17:16:11 -0500
commit6a0fabc6472f49621260de215f128a31ae70219b (patch)
tree6a67908358a2c5e5baa215fe0201dfe213dd8a01 /mesonbuild/templates
parent4340bf34faca7eed8076ba4c388fbe15355f2183 (diff)
downloadmeson-6a0fabc6472f49621260de215f128a31ae70219b.zip
meson-6a0fabc6472f49621260de215f128a31ae70219b.tar.gz
meson-6a0fabc6472f49621260de215f128a31ae70219b.tar.bz2
mass rewrite of string formatting to use f-strings everywhere
performed by running "pyupgrade --py36-plus" and committing the results
Diffstat (limited to 'mesonbuild/templates')
-rw-r--r--mesonbuild/templates/mesontemplates.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/mesonbuild/templates/mesontemplates.py b/mesonbuild/templates/mesontemplates.py
index 68f9769..4c4d66f 100644
--- a/mesonbuild/templates/mesontemplates.py
+++ b/mesonbuild/templates/mesontemplates.py
@@ -46,12 +46,12 @@ def create_meson_build(options: argparse.Namespace) -> None:
default_options += ['cpp_std=c++14']
# If we get a meson.build autoformatter one day, this code could
# be simplified quite a bit.
- formatted_default_options = ', '.join("'{}'".format(x) for x in default_options)
- sourcespec = ',\n '.join("'{}'".format(x) for x in options.srcfiles)
+ formatted_default_options = ', '.join(f"'{x}'" for x in default_options)
+ sourcespec = ',\n '.join(f"'{x}'" for x in options.srcfiles)
depspec = ''
if options.deps:
depspec = '\n dependencies : [\n '
- depspec += ',\n '.join("dependency('{}')".format(x)
+ depspec += ',\n '.join(f"dependency('{x}')"
for x in options.deps.split(','))
depspec += '],'
if options.language != 'java':