[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

[lintian] 01/01: checks/cruft.pm: Ignore TeX \section (etc.) titles when checking for GFDL license. Thanks, Norbert Preining for the report. (Closes: #863384)



This is an automated email from the git hooks/post-receive script.

lamby pushed a commit to branch master
in repository lintian.

commit 41bb73396b9a203598295c8c290ff0b322119f0a
Author: Chris Lamb <lamby@debian.org>
Date:   Fri Jan 12 11:03:12 2018 +0530

    checks/cruft.pm: Ignore TeX \section (etc.) titles when checking for GFDL license. Thanks, Norbert Preining for the report. (Closes: #863384)
---
 checks/cruft.pm                                       | 2 ++
 debian/changelog                                      | 3 +++
 t/tests/cruft-gfdl-invariants/debian/src/dvipdfmx.tex | 6 ++++++
 3 files changed, 11 insertions(+)

diff --git a/checks/cruft.pm b/checks/cruft.pm
index f1790a3..cad619d 100644
--- a/checks/cruft.pm
+++ b/checks/cruft.pm
@@ -1406,6 +1406,8 @@ sub _clean_block {
 
     # Texinfo end tag (could be more clever but brute force is fast)
     $text =~ s/}/ /gxms;
+    # Tex section titles
+    $text =~ s/^\s*\\(sub)*section\*?\{\s*\S+/ /gxms;
     # single char at end
     # String, C-style comment/javadoc indent,
     # quotes for strings, pipe and backslash, tilde in some txt
diff --git a/debian/changelog b/debian/changelog
index 9ac4a5e..80a29cf 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -2,6 +2,9 @@ lintian (2.5.69) UNRELEASED; urgency=medium
 
   XXX: generate tag summary
 
+  * checks/cruft.pm:
+    + [CL] Ignore TeX \section (etc.) titles when checking for GFDL
+      license. Thanks, Norbert Preining for the report.  (Closes: #863384)
   * checks/python.{pm,desc}:
     + [CL] Don't emit new-package-should-not-package-python2-module if
       the maintainer justifies its inclusion in the changelog entry.
diff --git a/t/tests/cruft-gfdl-invariants/debian/src/dvipdfmx.tex b/t/tests/cruft-gfdl-invariants/debian/src/dvipdfmx.tex
new file mode 100644
index 0000000..a0a6634
--- /dev/null
+++ b/t/tests/cruft-gfdl-invariants/debian/src/dvipdfmx.tex
@@ -0,0 +1,6 @@
+\section*{GNU Free Documentation License}\label{SEC:FDL}
+\subsection*{GNU Free Documentation License}\label{SEC:FDL}
+ \subsubsection{GNU Free Documentation License}\label{SEC:FDL}
+
+This document is distributed under the term of the GNU Free Documentation
+License. See, the attached file for copying conditions.

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/lintian/lintian.git


Reply to: