summaryrefslogtreecommitdiff
path: root/rules
diff options
context:
space:
mode:
authorPeter Hutterer <peter.hutterer@who-t.net>2023-12-20 14:23:01 +1000
committerPeter Hutterer <peter.hutterer@who-t.net>2023-12-20 14:30:11 +1000
commit3998ddde5bda96538fadd7de42a63f0b7c43d85d (patch)
tree168ac1082bfefbb177d7529c5ecf6c44ef44204f /rules
parent6cd55ec6ecbdd25d2ec13ccae60cf67eb47d162f (diff)
CI: drop black, use ruff-format instead
black is getting increasingly more difficult to use in the CI across distribution versions (thanks to Python's messy packaging) so let's replace it with ruff format which produces largely the same results.
Diffstat (limited to 'rules')
-rwxr-xr-xrules/compat/map-variants.py18
1 files changed, 15 insertions, 3 deletions
diff --git a/rules/compat/map-variants.py b/rules/compat/map-variants.py
index 5f4b5e6f..3bf44d42 100755
--- a/rules/compat/map-variants.py
+++ b/rules/compat/map-variants.py
@@ -71,7 +71,11 @@ def write_layout_n(dest, mappings, number, write_header):
second_layout = (
str(l2) if l2.variant else "{}%(v[{}])".format(l2.layout, number)
)
- dest.write(" * {} = {}+{}{}\n".format(l1, base, second_layout, suffix))
+ dest.write(
+ " * {} = {}+{}{}\n".format(
+ l1, base, second_layout, suffix
+ )
+ )
# mlv_s
@@ -79,13 +83,21 @@ def write_fixed_layout_variant(dest, mappings, write_header):
if write_header:
dest.write("! model layout variant = symbols\n")
for l1, l2 in mappings:
- dest.write(" * {} {} = pc+{}\n".format(l1.layout, l1.variant, l2))
+ dest.write(
+ " * {} {} = pc+{}\n".format(
+ l1.layout, l1.variant, l2
+ )
+ )
# mlnvn_s
def write_layout_n_variant_n(dest, mappings, number, write_header):
if write_header:
- dest.write("! model layout[{}] variant[{}] = symbols\n".format(number, number))
+ dest.write(
+ "! model layout[{}] variant[{}] = symbols\n".format(
+ number, number
+ )
+ )
# symbols is
# +layout(variant):2