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

lintian: r666 - in trunk: checks debian testset testset/debconf/debian



Author: rra
Date: 2006-05-07 08:20:55 +0200 (Sun, 07 May 2006)
New Revision: 666

Added:
   trunk/testset/debconf/debian/debconf-test.templates.de
Modified:
   trunk/checks/po-debconf
   trunk/checks/po-debconf.desc
   trunk/debian/changelog
   trunk/testset/tags.debconf
Log:
  + [RA] Check for stray debconf-mergetemplate files in packages
    using po-debconf.  Thanks, Martin Quinson.  (Closes: #232442)

Modified: trunk/checks/po-debconf
===================================================================
--- trunk/checks/po-debconf	2006-05-07 06:18:24 UTC (rev 665)
+++ trunk/checks/po-debconf	2006-05-07 06:20:55 UTC (rev 666)
@@ -32,9 +32,13 @@
 opendir(DEB, 'debfiles')
 	or fail("Can't open debfiles directory.");
 my $has_template = my $has_depends = my $has_config = 0;
+my @lang_templates;
 for my $file (readdir(DEB)) {
 	if ($file =~ m/^(.+\.)?templates(\..+)?$/) {
 	        $has_template = 1;
+		if ($file =~ m/templates\.\w\w(_\w\w)?$/) {
+			push (@lang_templates, $file);
+		}
 	}
 }
 closedir(DEB);
@@ -49,6 +53,12 @@
     return 0;
 }
 
+# If we got here, we're using po-debconf, so there shouldn't be any stray
+# language templates left over from debconf-mergetemplate.
+for (@lang_templates) {
+    tag "stray-translated-debconf-templates", $_;
+}
+
 # yada builds its template and po/POTFILES.in dynamically at build time, so
 # excuse yada from some of these checks (including the out of date templates
 # check).

Modified: trunk/checks/po-debconf.desc
===================================================================
--- trunk/checks/po-debconf.desc	2006-05-07 06:18:24 UTC (rev 665)
+++ trunk/checks/po-debconf.desc	2006-05-07 06:20:55 UTC (rev 666)
@@ -13,6 +13,14 @@
  use po-debconf to make translations possible (debian/po doesn't exist, or no
  dependency on po-debconf). See po-debconf(7).
 
+Tag: stray-translated-debconf-templates
+Type: warning
+Info: This package contains a file named *templates.XX or
+ *templates.XX_XX.  This was the naming convention for the translated
+ templates merged using debconf-mergetemplate.  Since the package is using
+ po-debconf, these files should be replaced by language-specific files in
+ the <tt>debian/po</tt> directory and should no longer be needed.
+
 Tag: missing-potfiles-in
 Type: warning
 Info: The required file POTFILES.in is missing from debian/po

Modified: trunk/debian/changelog
===================================================================
--- trunk/debian/changelog	2006-05-07 06:18:24 UTC (rev 665)
+++ trunk/debian/changelog	2006-05-07 06:20:55 UTC (rev 666)
@@ -47,6 +47,8 @@
     + [RA] Exempt packages that use yada from the POTFILES.in check and
       from checking for up-to-date templates, since yada does this at
       build time.  Reported by Piotr Roszatycki.  (Closes: #321139)
+    + [RA] Check for stray debconf-mergetemplate files in packages
+      using po-debconf.  Thanks, Martin Quinson.  (Closes: #232442)
   * checks/shared-libs.desc:
     + [RA] Document that exceptions to the -fPIC rule for shared libraries
       are possible and ask that such exceptions be documented with lintian
@@ -60,7 +62,7 @@
     + [RA] Update standards version to 3.7.2 (no changes required).
     + [RA] Update description to note calibration for Policy 3.7.2.
 
- -- Russ Allbery <rra@debian.org>  Sat,  6 May 2006 22:40:27 -0700
+ -- Russ Allbery <rra@debian.org>  Sat,  6 May 2006 23:20:02 -0700
 
 lintian (1.23.19) unstable; urgency=low
 

Added: trunk/testset/debconf/debian/debconf-test.templates.de
===================================================================
--- trunk/testset/debconf/debian/debconf-test.templates.de	2006-05-07 06:18:24 UTC (rev 665)
+++ trunk/testset/debconf/debian/debconf-test.templates.de	2006-05-07 06:20:55 UTC (rev 666)
@@ -0,0 +1,3 @@
+Template: debconf/testmulti
+Type: multiselect
+Choices: foo, bar\, boo, boo

Modified: trunk/testset/tags.debconf
===================================================================
--- trunk/testset/tags.debconf	2006-05-07 06:18:24 UTC (rev 665)
+++ trunk/testset/tags.debconf	2006-05-07 06:20:55 UTC (rev 666)
@@ -7,6 +7,7 @@
 W: debconf source: invalid-po-file debian/po/fr.po
 W: debconf source: maintainer-script-lacks-debhelper-token debian/debconf-test.postinst
 W: debconf source: newer-debconf-templates
+W: debconf source: stray-translated-debconf-templates debconf-test.templates.de
 W: debconf source: unknown-encoding-in-po-file debian/po/fr.po
 W: debconf-test-noscripts: no-debconf-config
 W: debconf-test-noscripts: old-fsf-address-in-copyright-file



Reply to: