]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
maint: use short form bug URLs
authorPádraig Brady <P@draigBrady.com>
Tue, 12 Aug 2025 13:31:03 +0000 (14:31 +0100)
committerPádraig Brady <P@draigBrady.com>
Tue, 12 Aug 2025 16:50:40 +0000 (17:50 +0100)
* cfg.mk (sc_prohibit-long-form-bug-urls): Disallow long form in code.
* scripts/git-hooks/commit-msg: Disallow long form in commit messages.
* NEWS: Shorten long urls.
* bootstrap.conf: Likewise.
* configure.ac: Likewise.
* scripts/git-hooks/commit-msg: Likewise.
* src/csplit.c: Likewise.
* src/fmt.c: Likewise.
* src/make-prime-list.c: Likewise.
* src/nohup.c: Likewise.
* tests/od/od-float.sh: Likewise.
* tests/rm/r-root.sh: Likewise.
* tests/tail/inotify-race.sh: Likewise.
* tests/tail/inotify-race2.sh: Likewise.

13 files changed:
NEWS
bootstrap.conf
cfg.mk
configure.ac
scripts/git-hooks/commit-msg
src/csplit.c
src/fmt.c
src/make-prime-list.c
src/nohup.c
tests/od/od-float.sh
tests/rm/r-root.sh
tests/tail/inotify-race.sh
tests/tail/inotify-race2.sh

diff --git a/NEWS b/NEWS
index e4575d0db721449afb11894b066adc572942c878..bfde1e62d41ea8285fa716409c5073f3698af560 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -19,7 +19,7 @@ GNU coreutils NEWS                                    -*- outline -*-
 
   cp, install, and mv now avoid possible data corruption on
   glibc 2.41 and 2.42 systems when copy_file_range is used with ranges > 2GiB,
-  avoiding https://sourceware.org/bugzilla/show_bug.cgi?id=33245
+  avoiding https://sourceware.org/PR33245
   [bug triggered since coreutils-9.0]
 
   'install -d' now produces the correct diagnostic upon failure
index 99d4df90bfdb9085133f44aa3d5cd0b7330d4750..49fcf30f3263d2cd8e7fe48620bc58961529a5da 100644 (file)
@@ -420,7 +420,7 @@ bootstrap_epilogue()
 
   # Add dummy 'install-html' target, required for packages using
   # non-recursive makefiles with older gettext.
-  # See https://debbugs.gnu.org/25690
+  # See https://bugs.gnu.org/25690
   if ! grep -w 'install-html' po/Makefile.in.in ; then
     printf 'install-%s:;\n' dvi ps pdf html >> po/Makefile.in.in
   fi
diff --git a/cfg.mk b/cfg.mk
index 4c634f663c04dba6c1e3090323d33580f66b5b63..2db427012f1f81fc47d0a8ec0cccf290bb906625 100644 (file)
--- a/cfg.mk
+++ b/cfg.mk
@@ -863,6 +863,15 @@ sc_prohibit-form-feed:
        halt='Form Feed (^L) detected' \
          $(_sc_search_regexp)
 
+# debbugs.gnu.org/cgi/bugreport.cgi?bug=... ->   bugs.gnu.org/...
+# bugzilla.redhat.com/show_bug.cgi?id=... ->     bugzilla.redhat.com/...
+# sourceware.org/bugzilla/show_bug.cgi?id=... -> sourceware.org/PR...
+# gcc.gnu.org/bugzilla/show_bug.cgi?id=... ->    gcc.gnu.org/PR...
+sc_prohibit-long-form-bug-urls:
+       @prohibit='http.*(bugreport|show_bug)\.cgi' \
+       halt='use short form bug url' \
+         $(_sc_search_regexp)
+
 # Override the default Cc: used in generating an announcement.
 announcement_Cc_ = $(translation_project_), \
   coreutils@gnu.org, coreutils-announce@gnu.org
index b44687204359f5eb07d5fb5ac9d2b23ec705261e..bcd41a71ca9b207e6e89c39fe38538dcbdeb3001 100644 (file)
@@ -204,7 +204,7 @@ if test $gl_gcc_warnings != no; then
 
   # Using -Wstrict-overflow is a pain, but the alternative is worse.
   # For an example, see the code that provoked this report:
-  # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=33498
+  # https://gcc.gnu.org/PR33498
   # Code like that still infloops with gcc-4.6.0 and -O2.  Scary indeed.
 
   gl_MANYWARN_ALL_GCC([ws])
index da094c95af4c378be7b29b92dd34eaa978244f58..bdea8c38d376bb893d73e08dd73c98687d643b12 100755 (executable)
@@ -136,6 +136,12 @@ sub check_msg($$)
   $buf =~ m!https://lists\.gnu\.org/archive/html/!s
     and return "use '/r/' in place of '/archive/html/' in lists.gnu.org URLs";
 
+  $buf =~ m!https?://(?:.*\.)?sourceware\.org/bugzilla/show_bug\.cgi\?id=(\d+)!s
+    and return "use shorter https://sourceware.org/PR$1";
+
+  $buf =~ m!https?://gcc\.gnu\.org/bugzilla/show_bug\.cgi\?id=(\d+)!s
+    and return "use shorter https://gcc.gnu.org/PR$1";
+
   return '';
 }
 
index 9119dcf5a32522796bd6e4e43dc803432097cf29..506f9248f95886a03c0c3715fe33b37e3b67bdf3 100644 (file)
@@ -378,7 +378,7 @@ record_line_starts (struct buffer_record *b)
   return lines;
 }
 
-/* Work around <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109614>.  */
+/* Work around <https://gcc.gnu.org/PR109614>.  */
 #if 13 <= __GNUC__
 # pragma GCC diagnostic ignored "-Wanalyzer-mismatching-deallocation"
 # pragma GCC diagnostic ignored "-Wanalyzer-use-after-free"
index 9419af64eac39178b3b4b8b78d95ea7ff9905ea2..408fe45a1ade8755f115e451093e83c8623de9f2 100644 (file)
--- a/src/fmt.c
+++ b/src/fmt.c
@@ -909,7 +909,7 @@ fmt_paragraph (void)
   word_limit->length = saved_length;
 }
 
-/* Work around <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109628>.  */
+/* Work around <https://gcc.gnu.org/PR109628>.  */
 #if __GNUC__ == 13
 # pragma GCC diagnostic ignored "-Wanalyzer-use-of-uninitialized-value"
 #endif
index 950aafcbcc9bb4e5cc2042dfe72f4bbb00954b70..5b72086609789a5c8bdd9ba4f91cebc963f6b6b4 100644 (file)
@@ -116,7 +116,7 @@ print_wide_uint (wide_uint n, int nesting, unsigned wide_uint_bits)
   printf ("0x%0*xU", hex_digits_per_literal, remainder);
 }
 
-/* Work around <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109635>.  */
+/* Work around <https://gcc.gnu.org/PR109635>.  */
 #if 13 <= __GNUC__
 # pragma GCC diagnostic ignored "-Wanalyzer-use-of-uninitialized-value"
 #endif
index d062d2cb8859f3970ac9725116df65c67d26cd61..d58fcc53f05aa21143dfe69c95034e9e94550b2a 100644 (file)
@@ -73,7 +73,7 @@ To save output to FILE, use '%s COMMAND > FILE'.\n"),
 }
 
 /* GCC 13 gets confused by the dup2 calls
-   <https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109839>.  */
+   <https://gcc.gnu.org/PR109839>.  */
 #if 13 <= __GNUC__
 # pragma GCC diagnostic ignored "-Wanalyzer-fd-leak"
 #endif
index b998769eea5ae25071253b666afd1271a5a16971..548a7944fe143497369d2cf428b81d993532564d 100755 (executable)
@@ -56,14 +56,14 @@ case $3,$4 in
 esac
 
 # Ensure od doesn't crash as it did on glibc <= 2.5:
-# https://sourceware.org/bugzilla/show_bug.cgi?id=4586
+# https://sourceware.org/PR4586
 set x $(printf 00000000ff000000 | tr 0f '\000\377' | od -t fL) || fail=1
 # With coreutils <= 8.7 we used to print "nan" for the above invalid value.
 # However since v8.7-22-ga71c22f we deferred to the system printf routines
 # through the use of the ftoastr module.  So the following check would only
 # be valid on x86_64 if we again handle the conversion internally or
 # if this glibc bug is resolved:
-# https://sourceware.org/bugzilla/show_bug.cgi?id=17661
+# https://sourceware.org/PR17661
 #case "$*" in
 #*nan*) ;;
 #*) fail=1;;
index 34e837b6d7a55e7ee7fde4d6f072d0bd67f7e381..63202ca2a6966b9d44d0be9d491aa96f054648f9 100755 (executable)
@@ -85,7 +85,7 @@ gcc_shared_ k.c k.so \
   || framework_failure_ 'failed to build shared library'
 
 # Note breakpoint commands don't work in batch mode
-# https://sourceware.org/bugzilla/show_bug.cgi?id=10079
+# https://sourceware.org/PR10079
 # So we use python to script behavior upon hitting the breakpoint
 cat > bp.py <<'EOF.py' || framework_failure_
 def breakpoint_handler (event):
index e6ab035f6aa5d80015db29711569906cecb1bfd7..bb7df48f95551cb60aaf8345c95e0b59cca6a2eb 100755 (executable)
@@ -53,7 +53,7 @@ break_line=$(echo "$break_line" | cut -d: -f1) || framework_failure_
 # has _intermittent_ issues with this.
 # Sending SIGCONT resulted in either delayed child termination,
 # or no child termination resulting in a hung test.
-# See https://sourceware.org/bugzilla/show_bug.cgi?id=18364
+# See https://sourceware.org/PR18364
 
 env sleep 10 & sleep=$!
 
index 0946022500df64a4562f238288b8b39bb223c42c..3db0cc74c60d3e3503c48359f5164ed7ae255d15 100755 (executable)
@@ -52,7 +52,7 @@ break_line=$(echo "$break_line" | cut -d: -f1) || framework_failure_
 # has _intermittent_ issues with this.
 # Sending SIGCONT resulted in either delayed child termination,
 # or no child termination resulting in a hung test.
-# See https://sourceware.org/bugzilla/show_bug.cgi?id=18364
+# See https://sourceware.org/PR18364
 
 env sleep 10 & sleep=$!