From 6f11783f7c1e90d52200865902bd4a204a3f309e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Guilhem=20Faur=C3=A9?= Date: Tue, 16 May 2023 17:15:43 +0200 Subject: [PATCH] flag empty articles --- spip2md/main.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/spip2md/main.py b/spip2md/main.py index 10c2651..8b1e7cc 100755 --- a/spip2md/main.py +++ b/spip2md/main.py @@ -43,8 +43,10 @@ for counter, article in Articles(maxexport): f"\n{BOLD}Exporting {R}{counter['remaining']+1}{RESET}" + f"{BOLD} SPIP articles to Markdown & YAML files{RESET}\n" ) + empty: str = "EMPTY " if len(article.text) < 1 else "" print( - f"{BOLD}{counter['exported']}.{RESET} " + highlight_unknown_chars(article.title) + f"{BOLD}{counter['exported']}. {empty}{RESET}" + + highlight_unknown_chars(article.title) ) fullpath: str = config.output_dir + "/" + article.get_path() print(f"{BOLD}>{RESET} {fullpath}{article.get_filename()}")