nsis installer: List emulators in alphabetical order
authorPeter Maydell <peter.maydell@linaro.org>
Sat, 5 Mar 2022 10:57:41 +0000 (10:57 +0000)
committerPeter Maydell <peter.maydell@linaro.org>
Fri, 18 Mar 2022 10:55:15 +0000 (10:55 +0000)
We currently list the emulators in the Windows installer's dialog
in an essentially random order (it's whatever glob.glob() returns
them to, which is filesystem-implementation-dependent). Add a
call to sorted() so they appear in alphabetical order.

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Stefan Weil <sw@weilnetz.de>
Reviewed-by: John Snow <jsnow@redhat.com>
Message-id: 20220305105743.2384766-2-peter.maydell@linaro.org

scripts/nsis.py

index 5135a0583167ea8a386a97f160e5350611e48d7c..383bef703326408700085a5102e51bb40175ea66 100644 (file)
@@ -34,9 +34,9 @@ def main():
         with open(
             os.path.join(destdir + args.prefix, "system-emulations.nsh"), "w"
         ) as nsh:
-            for exe in glob.glob(
+            for exe in sorted(glob.glob(
                 os.path.join(destdir + args.prefix, "qemu-system-*.exe")
-            ):
+            )):
                 exe = os.path.basename(exe)
                 arch = exe[12:-4]
                 nsh.write(