From bc96b491d675ccc74486bd36ae27c181940e84d2 Mon Sep 17 00:00:00 2001 From: Simone Date: Sun, 3 May 2026 02:45:45 +0200 Subject: [PATCH] fix: replace nested double-quote f-strings for Python <3.12 compatibility --- tools/legacy/build_plugin_2501_vs2022.py | 12 ++++++------ tools/legacy/build_plugin_2501_vs2026.py | 12 ++++++------ tools/legacy/build_plugin_2601_vs2026.py | 12 ++++++------ tools/legacy/build_plugin_vs2022.py | 12 ++++++------ tools/legacy/build_plugin_vs2026.py | 12 ++++++------ tools/legacy/build_plugin_zstd_vs2026.py | 12 ++++++------ 6 files changed, 36 insertions(+), 36 deletions(-) diff --git a/tools/legacy/build_plugin_2501_vs2022.py b/tools/legacy/build_plugin_2501_vs2022.py index c6c2a22..b563d82 100644 --- a/tools/legacy/build_plugin_2501_vs2022.py +++ b/tools/legacy/build_plugin_2501_vs2022.py @@ -789,9 +789,9 @@ Examples: configs_to_build = [CONFIGS[name] for name in args.configs] # Print header - print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}{"="*60}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}{'='*60}{Colors.RESET}") print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}Building nsis7z plugin (7-Zip 25.01){Colors.RESET} - {Colors.BRIGHT_WHITE}{len(configs_to_build)}{Colors.RESET} configuration(s)") - print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}{"="*60}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}{'='*60}{Colors.RESET}") print(f"{Colors.CYAN}Visual Studio:{Colors.RESET} {Colors.BRIGHT_WHITE}{vs_version_name} (toolset {platform_toolset}){Colors.RESET}") print(f"{Colors.CYAN}MSBuild:{Colors.RESET} {Colors.BRIGHT_WHITE}{msbuild_path}{Colors.RESET}") print(f"{Colors.CYAN}Project:{Colors.RESET} {Colors.BRIGHT_WHITE}{project_file}{Colors.RESET}") @@ -895,9 +895,9 @@ Examples: all_success = all(success for _, success, _, _, _ in build_results) if all_success: - print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}{"="*50}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}{'='*50}{Colors.RESET}") print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}ALL BUILDS SUCCESSFUL!{Colors.RESET}") - print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}{"="*50}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}{'='*50}{Colors.RESET}") print("\nPlugins copied to:") for config, _, build_time, file_size, dest_path in build_results: dest = dest_path if dest_path else plugins_dir / config.dest_dir / 'nsis7z.dll' @@ -908,9 +908,9 @@ Examples: print() clean_build_artifacts(project_dir, configs_to_build) else: - print(f"{Colors.BOLD}{Colors.RED}{"="*50}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.RED}{'='*50}{Colors.RESET}") print(f"{Colors.BOLD}{Colors.RED}SOME BUILDS FAILED!{Colors.RESET}") - print(f"{Colors.BOLD}{Colors.RED}{"="*50}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.RED}{'='*50}{Colors.RESET}") print("\nFailed configurations:") for config, success, build_time, file_size, dest_path in build_results: if not success: diff --git a/tools/legacy/build_plugin_2501_vs2026.py b/tools/legacy/build_plugin_2501_vs2026.py index 1bf8916..73b4811 100644 --- a/tools/legacy/build_plugin_2501_vs2026.py +++ b/tools/legacy/build_plugin_2501_vs2026.py @@ -816,9 +816,9 @@ Examples: configs_to_build = [CONFIGS[name] for name in args.configs] # Print header - print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}{"="*60}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}{'='*60}{Colors.RESET}") print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}Building nsis7z plugin (7-Zip 25.01, VS2026){Colors.RESET} - {Colors.BRIGHT_WHITE}{len(configs_to_build)}{Colors.RESET} configuration(s)") - print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}{"="*60}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}{'='*60}{Colors.RESET}") print(f"{Colors.CYAN}Visual Studio:{Colors.RESET} {Colors.BRIGHT_WHITE}{vs_version_name} (toolset {platform_toolset}){Colors.RESET}") print(f"{Colors.CYAN}MSBuild:{Colors.RESET} {Colors.BRIGHT_WHITE}{msbuild_path}{Colors.RESET}") print(f"{Colors.CYAN}Project:{Colors.RESET} {Colors.BRIGHT_WHITE}{project_file}{Colors.RESET}") @@ -922,9 +922,9 @@ Examples: all_success = all(success for _, success, _, _, _ in build_results) if all_success: - print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}{"="*50}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}{'='*50}{Colors.RESET}") print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}ALL BUILDS SUCCESSFUL!{Colors.RESET}") - print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}{"="*50}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}{'='*50}{Colors.RESET}") print("\nPlugins copied to:") for config, _, build_time, file_size, dest_path in build_results: dest = dest_path if dest_path else plugins_dir / config.dest_dir / 'nsis7z.dll' @@ -935,9 +935,9 @@ Examples: print() clean_build_artifacts(project_dir, configs_to_build) else: - print(f"{Colors.BOLD}{Colors.RED}{"="*50}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.RED}{'='*50}{Colors.RESET}") print(f"{Colors.BOLD}{Colors.RED}SOME BUILDS FAILED!{Colors.RESET}") - print(f"{Colors.BOLD}{Colors.RED}{"="*50}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.RED}{'='*50}{Colors.RESET}") print("\nFailed configurations:") for config, success, build_time, file_size, dest_path in build_results: if not success: diff --git a/tools/legacy/build_plugin_2601_vs2026.py b/tools/legacy/build_plugin_2601_vs2026.py index f06bfed..2ffcc9e 100755 --- a/tools/legacy/build_plugin_2601_vs2026.py +++ b/tools/legacy/build_plugin_2601_vs2026.py @@ -672,9 +672,9 @@ Examples: configs_to_build = [CONFIGS[name] for name in args.configs] # Print header - print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}{"="*60}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}{'='*60}{Colors.RESET}") print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}Building nsis7z plugin (7-Zip ZS, VS2026){Colors.RESET} - {Colors.BRIGHT_WHITE}{len(configs_to_build)}{Colors.RESET} configuration(s)") - print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}{"="*60}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}{'='*60}{Colors.RESET}") print(f"{Colors.CYAN}Visual Studio:{Colors.RESET} {Colors.BRIGHT_WHITE}{vs_version_name} (toolset {platform_toolset}){Colors.RESET}") print(f"{Colors.CYAN}MSBuild:{Colors.RESET} {Colors.BRIGHT_WHITE}{msbuild_path}{Colors.RESET}") print(f"{Colors.CYAN}Project:{Colors.RESET} {Colors.BRIGHT_WHITE}{project_file}{Colors.RESET}") @@ -724,9 +724,9 @@ Examples: all_success = all(success for _, success, _, _, _ in build_results) if all_success: - print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}{"="*50}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}{'='*50}{Colors.RESET}") print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}ALL BUILDS SUCCESSFUL!{Colors.RESET}") - print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}{"="*50}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}{'='*50}{Colors.RESET}") print("\nPlugins copied to:") for config, _, build_time, file_size, dest_path in build_results: dest = dest_path or plugins_dir / config.dest_dir / 'nsis7z.dll' @@ -735,9 +735,9 @@ Examples: print() clean_build_artifacts(project_dir, configs_to_build) else: - print(f"{Colors.BOLD}{Colors.RED}{"="*50}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.RED}{'='*50}{Colors.RESET}") print(f"{Colors.BOLD}{Colors.RED}SOME BUILDS FAILED!{Colors.RESET}") - print(f"{Colors.BOLD}{Colors.RED}{"="*50}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.RED}{'='*50}{Colors.RESET}") print("\nFailed configurations:") for config, success, build_time, file_size, dest_path in build_results: if not success: diff --git a/tools/legacy/build_plugin_vs2022.py b/tools/legacy/build_plugin_vs2022.py index 2831786..de98c9e 100644 --- a/tools/legacy/build_plugin_vs2022.py +++ b/tools/legacy/build_plugin_vs2022.py @@ -789,9 +789,9 @@ Examples: configs_to_build = [CONFIGS[name] for name in args.configs] # Print header - print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}{"="*60}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}{'='*60}{Colors.RESET}") print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}Building nsis7z plugin{Colors.RESET} - {Colors.BRIGHT_WHITE}{len(configs_to_build)}{Colors.RESET} configuration(s)") - print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}{"="*60}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}{'='*60}{Colors.RESET}") print(f"{Colors.CYAN}Visual Studio:{Colors.RESET} {Colors.BRIGHT_WHITE}{vs_version_name} (toolset {platform_toolset}){Colors.RESET}") print(f"{Colors.CYAN}MSBuild:{Colors.RESET} {Colors.BRIGHT_WHITE}{msbuild_path}{Colors.RESET}") print(f"{Colors.CYAN}Project:{Colors.RESET} {Colors.BRIGHT_WHITE}{project_file}{Colors.RESET}") @@ -895,9 +895,9 @@ Examples: all_success = all(success for _, success, _, _, _ in build_results) if all_success: - print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}{"="*50}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}{'='*50}{Colors.RESET}") print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}ALL BUILDS SUCCESSFUL!{Colors.RESET}") - print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}{"="*50}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}{'='*50}{Colors.RESET}") print("\nPlugins copied to:") for config, _, build_time, file_size, dest_path in build_results: dest = dest_path if dest_path else plugins_dir / config.dest_dir / 'nsis7z.dll' @@ -908,9 +908,9 @@ Examples: print() clean_build_artifacts(project_dir, configs_to_build) else: - print(f"{Colors.BOLD}{Colors.RED}{"="*50}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.RED}{'='*50}{Colors.RESET}") print(f"{Colors.BOLD}{Colors.RED}SOME BUILDS FAILED!{Colors.RESET}") - print(f"{Colors.BOLD}{Colors.RED}{"="*50}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.RED}{'='*50}{Colors.RESET}") print("\nFailed configurations:") for config, success, build_time, file_size, dest_path in build_results: if not success: diff --git a/tools/legacy/build_plugin_vs2026.py b/tools/legacy/build_plugin_vs2026.py index 187db22..3c1b826 100644 --- a/tools/legacy/build_plugin_vs2026.py +++ b/tools/legacy/build_plugin_vs2026.py @@ -816,9 +816,9 @@ Examples: configs_to_build = [CONFIGS[name] for name in args.configs] # Print header - print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}{"="*60}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}{'='*60}{Colors.RESET}") print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}Building nsis7z plugin (VS2026){Colors.RESET} - {Colors.BRIGHT_WHITE}{len(configs_to_build)}{Colors.RESET} configuration(s)") - print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}{"="*60}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}{'='*60}{Colors.RESET}") print(f"{Colors.CYAN}Visual Studio:{Colors.RESET} {Colors.BRIGHT_WHITE}{vs_version_name} (toolset {platform_toolset}){Colors.RESET}") print(f"{Colors.CYAN}MSBuild:{Colors.RESET} {Colors.BRIGHT_WHITE}{msbuild_path}{Colors.RESET}") print(f"{Colors.CYAN}Project:{Colors.RESET} {Colors.BRIGHT_WHITE}{project_file}{Colors.RESET}") @@ -922,9 +922,9 @@ Examples: all_success = all(success for _, success, _, _, _ in build_results) if all_success: - print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}{"="*50}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}{'='*50}{Colors.RESET}") print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}ALL BUILDS SUCCESSFUL!{Colors.RESET}") - print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}{"="*50}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}{'='*50}{Colors.RESET}") print("\nPlugins copied to:") for config, _, build_time, file_size, dest_path in build_results: dest = dest_path if dest_path else plugins_dir / config.dest_dir / 'nsis7z.dll' @@ -935,9 +935,9 @@ Examples: print() clean_build_artifacts(project_dir, configs_to_build) else: - print(f"{Colors.BOLD}{Colors.RED}{"="*50}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.RED}{'='*50}{Colors.RESET}") print(f"{Colors.BOLD}{Colors.RED}SOME BUILDS FAILED!{Colors.RESET}") - print(f"{Colors.BOLD}{Colors.RED}{"="*50}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.RED}{'='*50}{Colors.RESET}") print("\nFailed configurations:") for config, success, build_time, file_size, dest_path in build_results: if not success: diff --git a/tools/legacy/build_plugin_zstd_vs2026.py b/tools/legacy/build_plugin_zstd_vs2026.py index 20794d5..01c69e0 100644 --- a/tools/legacy/build_plugin_zstd_vs2026.py +++ b/tools/legacy/build_plugin_zstd_vs2026.py @@ -672,9 +672,9 @@ Examples: configs_to_build = [CONFIGS[name] for name in args.configs] # Print header - print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}{"="*60}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}{'='*60}{Colors.RESET}") print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}Building nsis7z plugin (7-Zip ZS, VS2026){Colors.RESET} - {Colors.BRIGHT_WHITE}{len(configs_to_build)}{Colors.RESET} configuration(s)") - print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}{"="*60}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.BRIGHT_CYAN}{'='*60}{Colors.RESET}") print(f"{Colors.CYAN}Visual Studio:{Colors.RESET} {Colors.BRIGHT_WHITE}{vs_version_name} (toolset {platform_toolset}){Colors.RESET}") print(f"{Colors.CYAN}MSBuild:{Colors.RESET} {Colors.BRIGHT_WHITE}{msbuild_path}{Colors.RESET}") print(f"{Colors.CYAN}Project:{Colors.RESET} {Colors.BRIGHT_WHITE}{project_file}{Colors.RESET}") @@ -724,9 +724,9 @@ Examples: all_success = all(success for _, success, _, _, _ in build_results) if all_success: - print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}{"="*50}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}{'='*50}{Colors.RESET}") print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}ALL BUILDS SUCCESSFUL!{Colors.RESET}") - print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}{"="*50}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.BRIGHT_GREEN}{'='*50}{Colors.RESET}") print("\nPlugins copied to:") for config, _, build_time, file_size, dest_path in build_results: dest = dest_path or plugins_dir / config.dest_dir / 'nsis7z.dll' @@ -735,9 +735,9 @@ Examples: print() clean_build_artifacts(project_dir, configs_to_build) else: - print(f"{Colors.BOLD}{Colors.RED}{"="*50}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.RED}{'='*50}{Colors.RESET}") print(f"{Colors.BOLD}{Colors.RED}SOME BUILDS FAILED!{Colors.RESET}") - print(f"{Colors.BOLD}{Colors.RED}{"="*50}{Colors.RESET}") + print(f"{Colors.BOLD}{Colors.RED}{'='*50}{Colors.RESET}") print("\nFailed configurations:") for config, success, build_time, file_size, dest_path in build_results: if not success: