[check_postgres] [commit] Add back in auto-html creation, do p:c for Makefile.PL

check_postgres at bucardo.org check_postgres at bucardo.org
Sun May 3 17:53:12 UTC 2009


Committed by Greg Sabino Mullane <greg at endpoint.com>

Add back in auto-html creation, do p:c for Makefile.PL

---
 Makefile.PL            |   15 +++++++++++++++
 check_postgres.pl      |    2 +-
 check_postgres.pl.asc  |    6 +++---
 check_postgres.pl.html |    3 ++-
 t/99_perlcritic.t      |    8 +++++++-
 5 files changed, 28 insertions(+), 6 deletions(-)

diff --git a/Makefile.PL b/Makefile.PL
index 828c638..ab510cc 100644
--- a/Makefile.PL
+++ b/Makefile.PL
@@ -66,6 +66,21 @@ my %opts =
 		$string .= qq{\t@ gpg --verify check_postgres.pl.asc\n};
 		return $string;
 	}
+
+	sub manifypods {
+		my $string = shift->SUPER::manifypods(@_);
+		$string .= <<'EOM';
+	pod2html check_postgres.pl > check_postgres.pl.html
+	perl -pi -e "s/<link.*?>//" check_postgres.pl.html
+	perl -pi -e "s~ git clone.*~ git clone http://bucardo.org/check_postgres.git</pre>~" check_postgres.pl.html
+	perl -pi -e "s~<title>\S+(.+)~<title>check_postgres.pl\\1</TITLE>~" check_postgres.pl.html
+	perl -pi -e "s~.*</title>~~" check_postgres.pl.html
+	perl -pi -e "s~</TITLE>~</title>~" check_postgres.pl.html
+	perl -pi -e "s~\`\`(.+?)''~&quot;\\1&quot;~g" check_postgres.pl.html
+	@ rm -f pod2htmd.tmp pod2htmi.tmp
+EOM
+		return $string;
+	}
 }
 
 my $output = WriteMakefile(%opts);
diff --git a/check_postgres.pl b/check_postgres.pl
index 2e23045..9d83b4a 100755
--- a/check_postgres.pl
+++ b/check_postgres.pl
@@ -6089,7 +6089,7 @@ Items not specifically attributed are by Greg Sabino Mullane.
   Make fsm_pages and fsm_relatins handle 8.4 servers smoothly. (Greg)
   Fix missing 'upd' field in show_dbstats (Andras Fabian)
   Allow ENV{PGCONTROLDATA} and ENV{PGBINDIR}. (Greg)
-  Add various Perl module infratructure, including (e.g. Makefile.PL) (Greg)
+  Add various Perl module infrastructure (e.g. Makefile.PL) (Greg)
   Fix incorrect regex in txn_wraparound (Greg)
   For txn_wraparound: consistent ordering and fix duplicates in perf output (Andras Fabian)
   Add in missing exabyte regex check (Selena Deckelmann)
diff --git a/check_postgres.pl.asc b/check_postgres.pl.asc
index 85e0f06..adccbe7 100644
--- a/check_postgres.pl.asc
+++ b/check_postgres.pl.asc
@@ -1,6 +1,6 @@
 -----BEGIN PGP SIGNATURE-----
 
-iEYEABEDAAYFAkn3GRwACgkQvJuQZxSWSsipUgCfSgw0v+Ib9MkS3dI2W2GxQu1D
-JeEAn3fn0FW2jpkxf0uW/xRNoMb00M51
-=jWv7
+iEYEABEDAAYFAkn9z5YACgkQvJuQZxSWSsh72QCg1o645QIAidzcALE6IzNiT/s4
+SCoAoORfQXeoA7CqFwtajUel2r6FVzuH
+=Imx1
 -----END PGP SIGNATURE-----
diff --git a/check_postgres.pl.html b/check_postgres.pl.html
index 97a4a4f..6fc2470 100644
--- a/check_postgres.pl.html
+++ b/check_postgres.pl.html
@@ -1328,7 +1328,7 @@ feature requests, and commit notices, send email to <a href="mailto:check_postgr
 <h1><a name="history">HISTORY</a></h1>
 <p>Items not specifically attributed are by Greg Sabino Mullane.</p>
 <dl>
-<dt><strong><a name="item_0"><strong>Version 2.8.0</strong> (April ??, 2009)</a></strong></dt>
+<dt><strong><a name="item_0"><strong>Version 2.8.0</strong> (May ??, 2009)</a></strong></dt>
 
 <dd>
 <pre>
@@ -1343,6 +1343,7 @@ feature requests, and commit notices, send email to <a href="mailto:check_postgr
   Make fsm_pages and fsm_relatins handle 8.4 servers smoothly. (Greg)
   Fix missing 'upd' field in show_dbstats (Andras Fabian)
   Allow ENV{PGCONTROLDATA} and ENV{PGBINDIR}. (Greg)
+  Add various Perl module infrastructure (e.g. Makefile.PL) (Greg)
   Fix incorrect regex in txn_wraparound (Greg)
   For txn_wraparound: consistent ordering and fix duplicates in perf output (Andras Fabian)
   Add in missing exabyte regex check (Selena Deckelmann)
diff --git a/t/99_perlcritic.t b/t/99_perlcritic.t
index 0469bdb..b3ff746 100644
--- a/t/99_perlcritic.t
+++ b/t/99_perlcritic.t
@@ -32,7 +32,7 @@ ok(@testfiles, 'Found files in test directory');
 ## Check some non-test files
 my $critic = Perl::Critic->new(-severity => 1, '-profile-strictness' => 'quiet');
 
-for my $filename (qw{check_postgres.pl t/CP_Testing.pm}) {
+for my $filename (qw{Makefile.PL check_postgres.pl t/CP_Testing.pm}) {
 
 	if ($ENV{TEST_CRITIC_SKIPNONTEST}) {
 		pass qq{Skipping non-test file "$filename"};
@@ -56,6 +56,12 @@ for my $filename (qw{check_postgres.pl t/CP_Testing.pm}) {
 				or $policy =~ /RequireVersionVar/o;
 		}
 
+		if ($filename =~ /Makefile/o) {
+			next VIO if $policy =~ /RequireVersionVar/o
+				or $policy =~ /ProhibitBooleanGrep/o
+				or $policy =~ /RequireInterpolationOfMetachars/o;
+		}
+
 		$vios++;
 		my $f = $v->filename();
 		my $l = $v->location();
-- 
1.6.0.5



More information about the Check_postgres mailing list