diff options
| author | Stefan Kangas <stefankangas@gmail.com> | 2022-10-30 14:30:56 +0100 |
|---|---|---|
| committer | Stefan Kangas <stefankangas@gmail.com> | 2022-10-30 14:32:24 +0100 |
| commit | 2fa8f1b77a66a486d67aaa0ced062b1eb4ff9f88 (patch) | |
| tree | dd95b45fe4662b9f54ed7768f15785a43665c9c8 | |
| parent | b1fa7974bb416b3b44234966ff14c6a4719d7997 (diff) | |
| download | emacs-2fa8f1b77a66a486d67aaa0ced062b1eb4ff9f88.tar.gz | |
elide-head: Make trailing "/" in URL optional
* lisp/elide-head.el (elide-head-headers-to-hide): Make trailing
"/" in the gnu.org URL optional for the GPL.
* test/lisp/elide-head-tests.el
(elide-head--test-headers-to-hide/gpl3-5): New test.
| -rw-r--r-- | lisp/elide-head.el | 4 | ||||
| -rw-r--r-- | test/lisp/elide-head-tests.el | 21 |
2 files changed, 18 insertions, 7 deletions
diff --git a/lisp/elide-head.el b/lisp/elide-head.el index 90bf1fe35b5..75a3612df91 100644 --- a/lisp/elide-head.el +++ b/lisp/elide-head.el @@ -53,8 +53,8 @@ `(;; GNU GPL ("is free software[:;] you can redistribute it" . ,(rx (or (seq "If not, see " (? "<") - "http" (? "s") "://www.gnu.org/licenses/" - (? ">") (? " ")) + "http" (? "s") "://www.gnu.org/licenses" + (? "/") (? ">") (? " ")) (seq "Boston, MA " (? " ") "0211" (or "1-1307" "0-1301") (or " " ", ") "USA") diff --git a/test/lisp/elide-head-tests.el b/test/lisp/elide-head-tests.el index 6f351170f1d..429ef266572 100644 --- a/test/lisp/elide-head-tests.el +++ b/test/lisp/elide-head-tests.el @@ -3,7 +3,6 @@ ;; Copyright (C) 2020-2022 Free Software Foundation, Inc. ;; Author: Simen Heggestøyl <simenheg@gmail.com> -;; Keywords: ;; This file is part of GNU Emacs. @@ -20,10 +19,6 @@ ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs. If not, see <https://www.gnu.org/licenses/>. -;;; Commentary: - -;; - ;;; Code: (require 'elide-head) @@ -169,6 +164,22 @@ ***************************************************************************/ " "This program is distributed in the hope that") +;; from mentor.el [no "/" in the gnu.org URL] +(elide-head--add-test gpl3-5 "\ +;; Mentor is free software; you can redistribute it and/or modify it +;; under the terms of the GNU General Public License as published by +;; the Free Software Foundation; either version 3, or (at your option) +;; any later version. +;; +;; Mentor is distributed in the hope that it will be useful, but WITHOUT +;; ANY WARRANTY; without even the implied warranty of MERCHANTABILITY +;; or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public +;; License for more details. +;; +;; You should have received a copy of the GNU General Public License +;; along with Mentor. If not, see <https://www.gnu.org/licenses>. +" "Mentor is distributed in the hope that") + ;;; GPLv2 |
