From 3330f667a962658e31355f143037a07b9ef52177 Mon Sep 17 00:00:00 2001 From: Bdale Garbee Date: Wed, 11 Jan 2012 15:32:49 -0700 Subject: [PATCH] fix a pile of lintian warnings --- debian/source.lintian-overrides | 2 -- debian/sudo-ldap.lintian | 1 + debian/sudo-ldap.postinst | 12 +++++++----- debian/sudo.lintian | 1 + debian/sudo.postinst | 12 +++++++----- 5 files changed, 16 insertions(+), 12 deletions(-) delete mode 100644 debian/source.lintian-overrides diff --git a/debian/source.lintian-overrides b/debian/source.lintian-overrides deleted file mode 100644 index b747b98..0000000 --- a/debian/source.lintian-overrides +++ /dev/null @@ -1,2 +0,0 @@ -sudo source: maintainer-script-lacks-debhelper-token debian/sudo.postinst -sudo source: maintainer-script-lacks-debhelper-token debian/sudo-ldap.postinst diff --git a/debian/sudo-ldap.lintian b/debian/sudo-ldap.lintian index 56e77ef..10ce84d 100644 --- a/debian/sudo-ldap.lintian +++ b/debian/sudo-ldap.lintian @@ -1,3 +1,4 @@ sudo-ldap: non-standard-file-perm etc/sudoers.d/README 0440 != 0644 sudo-ldap: setuid-binary usr/bin/sudo 4755 root/root sudo-ldap: setuid-binary usr/bin/sudoedit 4755 root/root +sudo-ldap: read-in-maintainer-script diff --git a/debian/sudo-ldap.postinst b/debian/sudo-ldap.postinst index da4a83c..7394d52 100644 --- a/debian/sudo-ldap.postinst +++ b/debian/sudo-ldap.postinst @@ -1,5 +1,7 @@ #!/bin/sh +set -e + # remove old link if [ -L /etc/alternatives/sudo ]; then @@ -44,18 +46,18 @@ rm -f /etc/sudoers.pre-conffile # make sure we have a sudo group -[ -n "`/usr/bin/getent group sudo`" ] && exit 0 # we're finished if there is a group sudo: +[ -n "`getent group sudo`" ] && exit 0 # we're finished if there is a group sudo: # start search with gid 27 gid="27" -while [ -n "`/usr/bin/getent group $gid | /usr/bin/cut -d: -f3`" ];do - gid=`/usr/bin/expr $gid + 1` +while [ -n "`getent group $gid | cut -d: -f3`" ];do + gid=`expr $gid + 1` done if [ "$gid" -ne "27" ];then echo "On Debian we normally use gid 27 for 'sudo'." - gname="`/usr/bin/getent group 27 | /usr/bin/cut -d: -f1`" + gname="`getent group 27 | cut -d: -f1`" echo "However, on your system gid 27 is group '$gname'." echo "" echo "Would you like me to stop configuring sudo so that you can change this?"; @@ -64,7 +66,7 @@ if [ "$gid" -ne "27" ];then read ans [ "$ans" = "" ] && break if [ "$ans" = "yes" -o "$ans" = "YES" ];then - echo "'dpkg --pending --configure' will restart the configuration.\n\n" + echo "\'dpkg --pending --configure\' will restart the configuration.\n\n" exit 1; fi echo "Please enter exactly 'yes' to stop, or press the enter key to continue without stopping" diff --git a/debian/sudo.lintian b/debian/sudo.lintian index 0b4b58c..951d429 100644 --- a/debian/sudo.lintian +++ b/debian/sudo.lintian @@ -1,3 +1,4 @@ sudo: non-standard-file-perm etc/sudoers.d/README 0440 != 0644 sudo: setuid-binary usr/bin/sudo 4755 root/root sudo: setuid-binary usr/bin/sudoedit 4755 root/root +sudo: read-in-maintainer-script diff --git a/debian/sudo.postinst b/debian/sudo.postinst index 3ce5fc5..77c11cc 100644 --- a/debian/sudo.postinst +++ b/debian/sudo.postinst @@ -1,5 +1,7 @@ #!/bin/sh +set -e + # remove old link if [ -L /etc/alternatives/sudo ]; then @@ -32,18 +34,18 @@ rm -f /etc/sudoers.pre-conffile # make sure we have a sudo group -[ -n "`/usr/bin/getent group sudo`" ] && exit 0 # we're finished if there is a group sudo: +[ -n "`getent group sudo`" ] && exit 0 # we're finished if there is a group sudo: # start search with gid 27 gid="27" -while [ -n "`/usr/bin/getent group $gid | /usr/bin/cut -d: -f3`" ];do - gid=`/usr/bin/expr $gid + 1` +while [ -n "`getent group $gid | cut -d: -f3`" ];do + gid=`expr $gid + 1` done if [ "$gid" -ne "27" ];then echo "On Debian we normally use gid 27 for 'sudo'." - gname="`/usr/bin/getent group 27 | /usr/bin/cut -d: -f1`" + gname="`getent group 27 | cut -d: -f1`" echo "However, on your system gid 27 is group '$gname'." echo "" echo "Would you like me to stop configuring sudo so that you can change this?"; @@ -52,7 +54,7 @@ if [ "$gid" -ne "27" ];then read ans [ "$ans" = "" ] && break if [ "$ans" = "yes" -o "$ans" = "YES" ];then - echo "'dpkg --pending --configure' will restart the configuration.\n\n" + echo "\'dpkg --pending --configure\' will restart the configuration.\n\n" exit 1; fi echo "Please enter exactly 'yes' to stop, or press the enter key to continue without stopping" -- 2.47.2