Package: pmount
Version: 0.9.99-alpha-2
Severity: minor


pmounts bash_completion script uses grep for finding devices. Since I have
an alias for grep which prints the linenumbers, the bash_completion script
falls apart. I changed all occuring grep to /bin/grep and everything works
again.

Cheers,
  Christoph

P.S: My grep alias:
alias grep='grep --color=auto -Eine'


-- System Information:
Debian Release: wheezy/sid
  APT prefers testing
  APT policy: (690, 'testing'), (650, 'unstable'), (600, 'experimental'), (500, 
'stable')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.39.1 (SMP w/2 CPU cores; PREEMPT)
Locale: LANG=en_US.utf8, LC_CTYPE=en_US.utf8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages pmount depends on:
ii  libblkid1                     2.17.2-9.1 block device id library
ii  libc6                         2.13-4     Embedded GNU C Library: Shared lib

pmount recommends no packages.

Versions of packages pmount suggests:
ii  cryptsetup                    2:1.3.0-3  configures encrypted block devices

-- Configuration Files:
/etc/bash_completion.d/pmount changed:
have pmount &&
_pmount() {
   local cur prev options devices fslist
   options=' -r --read-only -w --read-write -s --sync -A --noatime -e --exec \
   -t filesystem --type filesystem -c charset --charset charset -u umask \
   --umask umask --dmask dmask --fmask fmask -p file --passphrase file \
   -h --help -d --debug -V --version'
   fslist=' ascii cp1250 cp1251 cp1255 cp437 cp737 cp775 cp850 cp852 cp855 
cp857 cp860 cp861 cp862 cp863 cp864 cp865 cp866 cp869 cp874 cp932 cp936 cp949 
cp950 euc-jp iso8859-1 iso8859-13 iso8859-14 iso8859-15 iso8859-2 iso8859-3 
iso8859-4 iso8859-5 iso8859-6 iso8859-7 iso8859-9 koi8-r koi8-ru koi8-u utf8'
   COMPREPLY=()
   cur=${COMP_WORDS[COMP_CWORD]}
   prev=${COMP_WORDS[COMP_CWORD-1]}
   case "$prev" in
      -@(t|-type))
      COMPREPLY=( $( /bin/grep "^[[:space:]]$cur" /proc/filesystems ) )
      return 0
      ;;
      -@(c|-charset))
      COMPREPLY=( $( compgen -W "$fslist" -- $cur ) )
      return 0
      ;;
      -@(u|d|-umask|-dmask))
      COMPREPLY=( ${cur}0 ${cur}1 ${cur}2 ${cur}3 ${cur}4 ${cur}5 ${cur}6 
${cur}7 )
      return 0
      ;;
      -@(p|-passphrase))
      _filedir
      return 0
      ;;
   esac
        if [[ "$cur" == -* ]]; then
                COMPREPLY=( $( compgen -W "$options" -- $cur ) )
        else
    devices="$( command ls $(/bin/grep -v '^[[:space:]]*#' /etc/pmount.allow ) 
$(/bin/grep 1 /sys/block/*/removable | sed -e 
's,/sys/block/,/dev/,;s,/removable:1,*,') 2>/dev/null | sort -u | sed -e 
's,\(^/dev/\)\(.*\),\1\2 \2,' )"
                COMPREPLY=( $( compgen -W "$devices" -- $cur ) )
        fi
        return 0
}
have pumount &&
_pumount() {
   local cur prev options devices mdir
   mdir="$(readlink -f /media)"
   options=' -l --luks-force -h --help -d --debug --version'
   COMPREPLY=()
   cur=${COMP_WORDS[COMP_CWORD]}
   prev=${COMP_WORDS[COMP_CWORD-1]}
   if [[ "$cur" == -* ]]; then
      COMPREPLY=( $( compgen -W "$options" -- $cur ) )
   else
      devices="$( /bin/grep $mdir /proc/mounts | sed -e 's,.*/$mdir/,,;s,\ 
.*,,;s,\(.*\),\1\n/dev/\1,;s,/dev//dev,/dev,' )"
      COMPREPLY=( $( compgen -W "$devices" -- $cur ) )
   fi
   return 0
}
[ "$have" ] && complete -F _pmount $filenames pmount
[ "$have" ] && complete -F _pumount $filenames pumount

/etc/pmount.allow changed:
/dev/sdb1
/dev/sdb2
/dev/sdc1
/dev/mmcblk0p1

/etc/pmount.conf changed:
fsck_allow = yes
fsck_allow_user = chris
not_physically_logged_allow = yes
loop_allow = no


-- no debconf information



-- 
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]

Reply via email to