X-Git-Url: http://vcs.maemo.org/git/?a=blobdiff_plain;f=nokia-lintian%2Ftestset%2Fmaintainer-scripts%2Fdebian%2Fprerm;fp=nokia-lintian%2Ftestset%2Fmaintainer-scripts%2Fdebian%2Fprerm;h=0000000000000000000000000000000000000000;hb=bf47c4c43f1f5f4986e85b74fc82b32048aeb846;hp=55f21b5422d563f2d2af5a9f897ba21396d95686;hpb=19fdce4b743853cee27edb892096cf64295c2874;p=maemian diff --git a/nokia-lintian/testset/maintainer-scripts/debian/prerm b/nokia-lintian/testset/maintainer-scripts/debian/prerm deleted file mode 100644 index 55f21b5..0000000 --- a/nokia-lintian/testset/maintainer-scripts/debian/prerm +++ /dev/null @@ -1,174 +0,0 @@ -#!/bin/sh - -if [ "$1" != "upgrade" ]; then - update-alternatives --remove dummy /usr/bin/dummy-alternative -fi - -if ([ "$1" = "upgrade" ] || [ "$1" = "remove" ]) && [ -L /usr/doc/maintainer-scripts ]; the -n - rm -f /usr/doc/maintainer-scripts -fi - -cat </dev/null -} - -source $FOO - -trap "echo hi" EXIT HUP 3 - -if [[ "$2" = "purge" ]]; then - kill -HUP $$ -fi - -#this is ok though -if test -n $(echo foo | perl -pe 's/[[:space:]]//go'); then - echo 1 -fi - -update-rc.d foo remove - -# More false positives for bashism checks. None of these are errors. -echo "$line" | grep -q '{fonts/map,}/{\$progname,pdftex,dvips,}//' -echo "$line" | grep -q "${fonts},${foo}" -echo '$[1+2]' -printf "foo |& bar" -perl -e "print q( kill -HUP $? )" - -# Still catch disallowed expansions in double-quotes, though. -echo "${line:3:1}" - -# The wrong way to run an init script (no invoke-rc.d). -/etc/init.d/package stop - -# This is the only install-sgmlcatalog call that's allowed. -install-sgmlcatalog --quiet --remove package - -# More bashisms checks - -read -x foo -read -x -read -r foo -read foo -read - -echo "a\\b" -echo 'a\nb' - -echo "${UID}" -echo "$EUID" -echo "$SHLVL" -echo "$DIRSTACK" -echo "$SECONDS" -echo "$BASH" -echo "$BASH_FOO" -echo "$SHELLOPTS" -echo "$PIPESTATUS" - -bar="$(cut '-d|' -f2 <<< "$foo")" - -VAR=1 -VAR+=a - -echos() { - echo -n -e "bar" - echo -e -n "bar" - echo -en "bar" - echo -ne "bar" - echo "bar" - echo "echo -e foo" -} - -ech.os() { - echo foo >& 2 - echo foo >&bar - echo foo >& bar -} - -echoes() { - echo "abc\nxyz" - echo 'xyz\rabc' - echo foo\cbar - - echo -e "abc\nxyz" - echo -net 'xyz\rabc' - echo -e foo\cbar -} - -foobar.() { - suspend x - suspended x - caller x - complete x - compgen x - declare -a foo -} - -.foobar() { - typeset -x bar - disown 1 - builtin foo - set -B - alias -p - unalias -a -} - -IFS="()" - -ulimit -shopt -type -v bar -time ls -dirs -diff <(tac a) <(tac b) - -pushd - -local foo=bar -local -x foo - -popd - -readonly -f - -echo bar > /dev/tcp -export x -export -x x -export -p x - -sh -x -sh -D -sh --foo -sh +O - -# Brace expansion checks -echo {a,b} -echo {abc},{bcd} - -foobar() -{ - # This is a function -} - - foo.bar() -( - # This is a function with a bad name -) - -foobar@() -{ - # As is this -}