From 5e9e756f5322c69932fe9b1bdfcf24f358a32da7 Mon Sep 17 00:00:00 2001 From: sfan5 Date: Mon, 23 Sep 2024 19:20:05 +0200 Subject: [PATCH] TOOLS/gen-interface-changes: small usability improvement --- TOOLS/gen-interface-changes.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/TOOLS/gen-interface-changes.py b/TOOLS/gen-interface-changes.py index 3a415192af..e7747630f0 100755 --- a/TOOLS/gen-interface-changes.py +++ b/TOOLS/gen-interface-changes.py @@ -78,6 +78,7 @@ if __name__ == "__main__": ver_line = " --- mpv 0." + major_version + ".0 ---" next_ver_line = " --- mpv 0." + str(int(major_version) + 1) + ".0 ---" + found = False with open(interface_changes, "w", newline="\n") as f: for line in lines: if line == ver_line: @@ -85,3 +86,6 @@ if __name__ == "__main__": f.write(line + "\n") if line == ver_line: add_new_entries(docs_dir, f, git) + found = True + if not found: + print(f"Nothing changed! The following line was not found:\n{ver_line}")