From a46da4272fbc5312061b4cd392dc7a698d2a6eb9 Mon Sep 17 00:00:00 2001 From: Chris Markiewicz Date: Wed, 24 Apr 2024 16:55:17 -0400 Subject: [PATCH 1/3] chore(code-style): Rewrite f-strings in print_contributors.py to outrage flake8 less --- tools/print_contributors.py | 20 +++++++++----------- 1 file changed, 9 insertions(+), 11 deletions(-) diff --git a/tools/print_contributors.py b/tools/print_contributors.py index c49ca6f823..29db86a39c 100644 --- a/tools/print_contributors.py +++ b/tools/print_contributors.py @@ -15,8 +15,9 @@ def contributor_table_header(max_name_length, max_contrib_length): - return f"""| name{" " * (max_name_length-4)} | contributions{" " * (max_contrib_length-13)} | -| {"-" * max_name_length} | {"-"*max_contrib_length} | + return f"""\ +| {"name":<{max_name_length}} | {"contributions":<{max_contrib_length}} | +| {"":-<{max_name_length}} | {"":-<{max_contrib_length}} | """ @@ -24,16 +25,13 @@ def create_line_contributor( contributor: dict[str, str], max_name_length: int, max_contrib_length: int ): name = contributor["name"] + emap = emoji_map() + contributions = "".join( + emoji.emojize(emap[cont]) for cont in contributor["contributions"] + ) - line = f"| {name}{' '*(max_name_length-len(name))} | " - - nb_contrib = len(contributor["contributions"]) * 2 - for contrib in contributor["contributions"]: - line += emoji.emojize(emoji_map()[contrib]) - - line += f"{' '*(max_contrib_length-nb_contrib)} |\n" - - return line + pad = max_contrib_length - len(contributor["contributions"]) * 2 + return f"| {name:<{max_name_length}} | {contributions}{'':<{pad}} |\n" def main(): From f68d6cc950dcbd7f51944d6eca9c5e8e707a03f2 Mon Sep 17 00:00:00 2001 From: Chris Markiewicz Date: Wed, 24 Apr 2024 16:55:55 -0400 Subject: [PATCH 2/3] chore(render): Rerender contributors.md --- src/appendices/contributors.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/appendices/contributors.md b/src/appendices/contributors.md index 2ffab4740f..315523a1a5 100644 --- a/src/appendices/contributors.md +++ b/src/appendices/contributors.md @@ -121,7 +121,7 @@ If you contributed to the BIDS ecosystem and your name is not listed, please add | Dianne Patterson | πŸ“– | | Dimitri Papadopoulos Orfanos | πŸ“–πŸ’‘πŸ€”πŸ’¬πŸ’» | | Dmitry Petrov | πŸ“–πŸ’» | -| Dora Hermes | πŸ“–πŸ’»βœ…πŸ”πŸ€” | +| Dora Hermes | πŸ“–πŸ’»βœ…πŸ”πŸ€” | | Dorien Huijser | πŸ“– | | Douglas N. Greve | πŸ“– | | Duncan Macleod | πŸ“–πŸš‡ | @@ -194,7 +194,7 @@ If you contributed to the BIDS ecosystem and your name is not listed, please add | Jeanette Mumford | πŸ“– | | Jefferson Casimir | πŸ”§ | | Jeffrey G. Ojemann | πŸ“– | -| Jeffrey S. Grethe | πŸ’¬πŸ›βœ…πŸ“’πŸ’» | +| Jeffrey S. Grethe | πŸ’¬πŸ›βœ…πŸ“’πŸ’» | | JegouA | πŸ’» | | Jelle Dalenberg | πŸ“– | | Jeremy Moreau | πŸ“–πŸ’‘ | @@ -211,7 +211,7 @@ If you contributed to the BIDS ecosystem and your name is not listed, please add | Jose Manuel Saborit | πŸ“– | | Joseph Wexler | πŸ“–πŸ’‘ | | Joseph Woods | πŸ“– | -| Julia Guiomar Niso GalΓ‘n | πŸ€”πŸŽ¨πŸ”πŸ‘€πŸ“‹πŸ“πŸ”§πŸ›πŸ’»πŸ”£βœ…πŸ’¬πŸ“–πŸ’‘πŸ“’ | +| Julia Guiomar Niso GalΓ‘n | πŸ€”πŸŽ¨πŸ”πŸ‘€πŸ“‹πŸ“πŸ”§πŸ›πŸ’»πŸ”£βœ…πŸ’¬πŸ“–πŸ’‘πŸ“’ | | Julia Sprenger | πŸ“– | | Julien Cohen-Adad | πŸ“–πŸ”£πŸ€” | | Julius Welzel | πŸ“–πŸ’‘πŸ›πŸ’»πŸ”£πŸ€”πŸ’¬πŸ““ | @@ -269,7 +269,7 @@ If you contributed to the BIDS ecosystem and your name is not listed, please add | Michael Hanke | πŸ“–πŸ€”πŸ”§πŸ›πŸ“’ | | Michael P. Harms | πŸ“–βš οΈπŸ”§ | | Michael P. Milham | πŸ’‘πŸ” | -| Michael P. Notter | πŸ’¬πŸ“βœ…πŸ“’πŸ“– | +| Michael P. Notter | πŸ’¬πŸ“βœ…πŸ“’πŸ“– | | Michael Schirner | πŸ“– | | MikaΓ«l Naveau | πŸ› | | Nader Pouratian | πŸ“– | @@ -288,7 +288,7 @@ If you contributed to the BIDS ecosystem and your name is not listed, please add | Patricia Clement | πŸ’¬πŸ›πŸ’»πŸ“–πŸ”£πŸ’‘πŸ“‹πŸ€”πŸ“†βš οΈπŸ“’ | | Patrick Park | πŸ“–πŸ’‘πŸ’¬πŸ’» | | Paule-Joanne Toussaint | πŸ“– | -| Peer Herholz | πŸ’¬πŸ“–πŸ‘€πŸ”§βœ…πŸ“’ | +| Peer Herholz | πŸ’¬πŸ“–πŸ‘€πŸ”§βœ…πŸ“’ | | Petra Ritter | πŸ“– | | Pierre Rioux | πŸ“– | | Pieter Vandemaele | πŸ“–πŸ’» | @@ -318,7 +318,7 @@ If you contributed to the BIDS ecosystem and your name is not listed, please add | Shashank Bansal | πŸ“– | | Sjoerd B. Vos | πŸ“– | | Soichi Hayashi | πŸ“–πŸ”§πŸ› | -| Stefan Appelhoff | πŸ“–πŸ’¬πŸ€”πŸ›πŸ’‘πŸ’»πŸ‘€βš οΈπŸ“’βœ…πŸ”§πŸ”ŒπŸ“πŸš§πŸ”£ | +| Stefan Appelhoff | πŸ“–πŸ’¬πŸ€”πŸ›πŸ’‘πŸ’»πŸ‘€βš οΈπŸ“’βœ…πŸ”§πŸ”ŒπŸ“πŸš§πŸ”£ | | Stephan Bickel | πŸ“– | | Steven Meisler | πŸ›πŸ’»πŸ’¬πŸ”§πŸ““ | | Suyash Bhogawar | πŸ“–πŸ’‘βš οΈπŸ”§πŸ’¬ | From 916ed71b825a2599d58e9b1d4052f6c55c1d35eb Mon Sep 17 00:00:00 2001 From: Chris Markiewicz Date: Wed, 24 Apr 2024 23:04:04 -0400 Subject: [PATCH 3/3] chore(style): Ignore linting errors in auto-generated table --- src/appendices/contributors.md | 1 + 1 file changed, 1 insertion(+) diff --git a/src/appendices/contributors.md b/src/appendices/contributors.md index 315523a1a5..f48586f04d 100644 --- a/src/appendices/contributors.md +++ b/src/appendices/contributors.md @@ -37,6 +37,7 @@ ecosystem (in alphabetical order). If you contributed to the BIDS ecosystem and your name is not listed, please add it. + | name | contributions | | ---------------------------------------------------- | -------------------------------------- |