aboutsummaryrefslogtreecommitdiff
path: root/examples
diff options
context:
space:
mode:
authorLoïc Minier <lool@dooz.org>2009-09-21 16:28:53 +0200
committerLoïc Minier <lool@dooz.org>2009-09-21 16:28:53 +0200
commit7954a48776add805bded8549e38c45785c5ab2ea (patch)
tree324c17ffb4785136a710b03b8816900050998ce1 /examples
parentfd3f5f90a650df0d5ee789af4932c52886154b8d (diff)
downloadpbuilder-7954a48776add805bded8549e38c45785c5ab2ea.tar
pbuilder-7954a48776add805bded8549e38c45785c5ab2ea.tar.gz
Misc enhancements to sample lintian hook
examples/B90lintian: Run lintian as pbuilder and not root and show how to not fail the build if lintian fails.
Diffstat (limited to 'examples')
-rw-r--r--examples/B90lintian24
1 files changed, 18 insertions, 6 deletions
diff --git a/examples/B90lintian b/examples/B90lintian
index 57fcfc4..f2c692f 100644
--- a/examples/B90lintian
+++ b/examples/B90lintian
@@ -1,6 +1,18 @@
-#!/bin/bash
-# example file to be used with --hookdir
-#
-# run lintian on generated deb files
-apt-get install -y --force-yes lintian
-lintian /tmp/buildd/*.deb
+#!/bin/sh
+
+set -e
+
+install_packages() {
+ apt-get -y --force-yes install "$@"
+}
+
+install_packages lintian
+
+echo "+++ lintian output +++"
+
+su -c "lintian -I --show-overrides /tmp/buildd/*.changes" - pbuilder
+# use this version if you don't want lintian to fail the build
+#su -c "lintian -I --show-overrides /tmp/buildd/*.changes; :" - pbuilder
+
+echo "+++ end of lintian output +++"
+