On 2025-05-14 12:53, Collin Funk wrote:
I think that adding an email regardless would be good

Yes, now's a good time to revisit the decision in 2013 to remove the bug-reporting email address[1]. Plus, the current code is confusing.

How about the attached coreutils patch? It simplifies the code and goes back to the old way of doing things, which includes outputting the bug reporting address.

If this doesn't generate the output we want, surely we should change Gnulib's emit_bug_reporting_address rather than try to reinvent it.

[1]: https://git.savannah.gnu.org/cgit/coreutils.git/commit/?id=8b6d3c5700526f962b12cd5901b55961c5e18186
From 9fa1367b66027ad402f11441417449ba96db3c04 Mon Sep 17 00:00:00 2001
From: Paul Eggert <egg...@cs.ucla.edu>
Date: Wed, 14 May 2025 13:36:40 -0700
Subject: [PATCH] maint: --help now outputs bug reporting address
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

This changes the tail of "cat --help" output from:

GNU coreutils online help: <https://www.gnu.org/software/coreutils/>
Full documentation <https://www.gnu.org/software/coreutils/cat>
or available locally via: info '(coreutils) cat invocation'

to:

Report bugs to: bug-coreutils@gnu.org
GNU coreutils home page: <https://www.gnu.org/software/coreutils/>
General help using GNU software: <https://www.gnu.org/gethelp/>
Full documentation <https://www.gnu.org/software/coreutils/cat>
or available locally via: info '(coreutils) cat invocation'

* src/system.h (emit_bug_reporting_address): Don’t #define.
(emit_ancillary_info): Call emit_bug_reporting_address
instead of doing it by hand, which omitted the bug reporting address.
---
 man/local.mk |  2 +-
 src/system.h | 11 +----------
 2 files changed, 2 insertions(+), 11 deletions(-)

diff --git a/man/local.mk b/man/local.mk
index ae74bf6ce..9759eabce 100644
--- a/man/local.mk
+++ b/man/local.mk
@@ -54,7 +54,7 @@ mandeps =
 # Depend on this to get version number changes.
 mandeps += .version
 
-# This is required so that changes to e.g., emit_bug_reporting_address
+# This is required so that changes to e.g., emit_ancillary_info
 # provoke regeneration of all the manpages.
 mandeps += $(top_srcdir)/src/system.h
 
diff --git a/src/system.h b/src/system.h
index 4a47e15ca..ca223d547 100644
--- a/src/system.h
+++ b/src/system.h
@@ -333,9 +333,7 @@ enum
 #include "closein.h"
 #include "closeout.h"
 
-#define emit_bug_reporting_address unused__emit_bug_reporting_address
 #include "version-etc.h"
-#undef emit_bug_reporting_address
 
 #include "propername.h"
 /* Define away proper_name, since it's not worth the cost of adding ~17KB to
@@ -651,14 +649,7 @@ emit_ancillary_info (char const *program)
   if (map_prog->node)
     node = map_prog->node;
 
-  printf (_("\n%s online help: <%s>\n"), PACKAGE_NAME, PACKAGE_URL);
-
-#ifdef PACKAGE_PACKAGER
-# ifdef PACKAGE_PACKAGER_BUG_REPORTS
-  printf (_("Report %s bugs to: <%s>\n"), PACKAGE_PACKAGER,
-          PACKAGE_PACKAGER_BUG_REPORTS);
-# endif
-#endif
+  emit_bug_reporting_address ();
 
   /* Don't output this redundant message for English locales.
      Note we still output for 'C' so that it gets included in the man page.  */
-- 
2.49.0

Reply via email to