diff options
| author | Ilya Zhuravlev <whatever@xyz.is> | 2024-04-21 15:03:34 -0600 |
|---|---|---|
| committer | Ilya Zhuravlev <whatever@xyz.is> | 2024-04-21 15:03:34 -0600 |
| commit | 2847ee23f89ced97f7305f18f4db216d2195e201 (patch) | |
| tree | 8a09511e7a4b37a6fbf79958f05dddc493c2171f /lib/python/qmk/cli/format | |
| parent | e67fce6811476e58b64929f5b5ac096426c8f015 (diff) | |
| parent | 20710456a9c0a037cbdeb07efefd01f58f92d9c5 (diff) | |
Merge branch 'merge-2024-04-15' into vial
Diffstat (limited to 'lib/python/qmk/cli/format')
| -rwxr-xr-x | lib/python/qmk/cli/format/json.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/python/qmk/cli/format/json.py b/lib/python/qmk/cli/format/json.py index 283513254c..87a3837d10 100755 --- a/lib/python/qmk/cli/format/json.py +++ b/lib/python/qmk/cli/format/json.py @@ -92,8 +92,8 @@ def format_json(cli): output = json.dumps(json_data, cls=json_encoder, sort_keys=True) if cli.args.inplace: - with open(cli.args.json_file, 'w+', encoding='utf-8') as outfile: - outfile.write(output) + with open(cli.args.json_file, 'w+', encoding='utf-8', newline='\n') as outfile: + outfile.write(output + '\n') # Display the results if print was set # We don't operate in-place by default, so also display to stdout |
