aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDonald Hunter <[email protected]>2023-12-15 09:37:18 +0000
committerJakub Kicinski <[email protected]>2023-12-18 14:39:44 -0800
commite8c32339cf49cd9c2626e143c548f5897aa58b17 (patch)
treeed29ddcd2dcfac982753a056e7d4c43556c0540f
parent6235b3d8bc3f81e81561c151237503fcf7868a98 (diff)
tools/net/ynl-gen-rst: Sort the index of generated netlink specs
The index of netlink specs was being generated unsorted. Sort the output before generating the index entries. Reviewed-by: Jakub Kicinski <[email protected]> Reviewed-by: Breno Leitao <[email protected]> Signed-off-by: Donald Hunter <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Jakub Kicinski <[email protected]>
-rwxr-xr-xtools/net/ynl/ynl-gen-rst.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/net/ynl/ynl-gen-rst.py b/tools/net/ynl/ynl-gen-rst.py
index 6825db92c899..68f9a9cd57cb 100755
--- a/tools/net/ynl/ynl-gen-rst.py
+++ b/tools/net/ynl/ynl-gen-rst.py
@@ -383,7 +383,7 @@ def generate_main_index_rst(output: str) -> None:
index_dir = os.path.dirname(output)
logging.debug("Looking for .rst files in %s", index_dir)
- for filename in os.listdir(index_dir):
+ for filename in sorted(os.listdir(index_dir)):
if not filename.endswith(".rst") or filename == "index.rst":
continue
lines.append(f" {filename.replace('.rst', '')}\n")