]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
moveconfig: Use an encoding with open()
authorSimon Glass <sjg@chromium.org>
Sat, 23 Sep 2023 19:44:04 +0000 (13:44 -0600)
committerSimon Glass <sjg@chromium.org>
Wed, 4 Oct 2023 15:25:21 +0000 (09:25 -0600)
Fix pylint warnings about needing an explicit character encoding.

Signed-off-by: Simon Glass <sjg@chromium.org>
tools/moveconfig.py

index d46433c6d8f5950e4585f641fc9034b870a8355b..9b716596956b193f856c901ca6c5d2501a20aed5 100755 (executable)
@@ -1457,12 +1457,14 @@ def do_scan_source(path, do_update):
 
     # Write out the updated information
     if do_update:
-        with open(os.path.join(path, 'scripts', 'conf_nospl'), 'w') as out:
+        with open(os.path.join(path, 'scripts', 'conf_nospl'), 'w',
+                  encoding='utf-8') as out:
             print('# These options should not be enabled in SPL builds\n',
                   file=out)
             for item in sorted(spl_not_found):
                 print(item, file=out)
-        with open(os.path.join(path, 'scripts', 'conf_noproper'), 'w') as out:
+        with open(os.path.join(path, 'scripts', 'conf_noproper'), 'w',
+                  encoding='utf-8') as out:
             print('# These options should not be enabled in Proper builds\n',
                   file=out)
             for item in sorted(proper_not_found):