[tin-dev] [PATCH] batch_mode + verbosity

Dennis Preiser dennis at d--p.de
Fri Nov 10 16:26:23 CET 2023


If I'm not mistaken, the behavior when calling with '-v -Z' has changed
recently. Previously, only groups with unread articles were displayed.

| Checking for news...
| 1001 unread (   0 hot) articles in gmane.network.tin.devel
|   27 unread (   0 hot) articles in gmane.editors.vim.devel
| 1496 unread (   0 hot) articles in gmane.comp.encryption.openssl.user


Now tin displays a lot of "Reading $GROUP" and "Writing $GROUP".

| Checking for news...
| Reading gmane.ietf.nntp
| Reading gmane.ietf.usenet.format
| Reading gmane.network.tin.devel
| 1001 unread (   0 hot) articles in gmane.network.tin.devel
| Reading gmane.network.slrn.user
| Reading gmane.editors.vim
| Reading gmane.editors.vim.devel
| Writing gmane.editors.vim.devel
|   27 unread (   0 hot) articles in gmane.editors.vim.devel
| Reading gmane.editors.vim.mac
| Reading gmane.network.stunnel.user
| Reading gmane.comp.encryption.openssl.user
| 1496 unread (   0 hot) articles in gmane.comp.encryption.openssl.user

I would like to suggest to restore the old behavior and display the
"Reading $GROUP" and "Writing $GROUP" only with increased verbosity
('-vv -Z').

Dennis
-------------- next part --------------
--- a/include/extern.h
+++ b/include/extern.h
@@ -1190,6 +1190,7 @@ extern constext txt_reading_arts[];
 extern constext txt_reading_attributes_file[];
 extern constext txt_reading_config_file[];
 extern constext txt_reading_filter_file[];
+extern constext txt_reading_group[];
 extern constext txt_reading_groups[];
 extern constext txt_reading_input_history_file[];
 extern constext txt_reading_keymap_file[];
@@ -1418,6 +1419,7 @@ extern constext txt_warn_unrecognized_version[];
 extern constext txt_warn_wrong_sig_format[];
 extern constext txt_warn_xref_not_supported[];
 extern constext txt_writing_attributes_file[];
+extern constext txt_writing_group[];
 extern constext txt_x_resp[];
 extern constext txt_yanked_groups[];
 extern constext txt_yanked_none[];
--- a/src/art.c
+++ b/src/art.c
@@ -419,8 +419,8 @@ index_group(
 	if (!batch_mode)
 		show_art_msg(group->name);
 	else {
-		if (verbose) /* -> lang.c */
-			wait_message(0, _("Reading %s\n"), group->name);
+		if (verbose > 1)
+			wait_message(0, _(txt_reading_group), group->name);
 	}
 
 	signal_context = cArt;			/* Set this only once curr_group is valid */
@@ -2537,8 +2537,8 @@ write_overview(
 	}
 #endif /* CHARSET_CONVERSION */
 
-	if (verbose && batch_mode) /* -> lang.c */
-		wait_message(0, _("Writing %s\n"), group->name);
+	if (batch_mode && verbose > 1)
+		wait_message(0, _(txt_writing_group), group->name);
 
 	for_each_art(i) {
 		char *p, *q, *ref;
--- a/src/lang.c
+++ b/src/lang.c
@@ -794,6 +794,7 @@ constext txt_reading_arts[] = N_("Reading %s articles...");
 constext txt_reading_attributes_file[] = N_("Reading %sattributes file...\n");
 constext txt_reading_config_file[] = N_("Reading %sconfig file...\n");
 constext txt_reading_filter_file[] = N_("Reading filter file...\n");
+constext txt_reading_group[] = N_("Reading %s\n");
 constext txt_reading_groups[] = N_("Reading %s groups...");
 constext txt_reading_input_history_file[] = N_("Reading input history file...\n");
 constext txt_reading_keymap_file[] = N_("Reading keymap file...\n");
@@ -1032,6 +1033,7 @@ constext txt_warn_suspicious_mail[] = N_("Warning: this mail address may contain
 constext txt_warn_unprintable_char[] = N_("Warning: line %d contains unprintable chars:\n%s\n");
 constext txt_warn_wrong_sig_format[] = N_("\nWarning: Signatures should start with '-- \\n' not with '--\\n'.\n");
 constext txt_writing_attributes_file[] = N_("Writing attributes file...");
+constext txt_writing_group[] = N_("Writing %s\n");
 
 constext txt_x_resp[] = N_("%4d Responses");
 


More information about the tin-dev mailing list