[xml/sgml-pkgs] Bug#701549: refdb-clients: bashism in /bin/sh script
Raphael Geissert
atomo64 at gmail.com
Sun Feb 24 12:18:23 UTC 2013
Package: refdb-clients
Version: 0.9.9-3
Severity: serious
User: debian-release at lists.debian.org
Usertags: goal-dash
Hello maintainer,
While performing an archive wide checkbashisms (from the 'devscripts'
package) check I've found your package containing a /bin/sh script making
use of a bashism.
checkbashisms' output:
>possible bashism in ./usr/bin/refdb-backup line 158 (should be >word
>2>&1):
>${refdba} -C listdb &> /dev/null || \
> endScript "Error: Unable to access RefDB using client 'refdba'."
> "failed"
>
>possible bashism in ./usr/bin/refdb-backup line 160 (should be >word
>2>&1):
>${refdbc} -C listdb &> /dev/null || \
> endScript "Error: Unable to access RefDB using client 'refdbc'."
> "failed"
>
>possible bashism in ./usr/bin/refdb-backup line 187 (should be >word 2>&1):
> mkdir ${dirname} &> /dev/null
>
>possible bashism in ./usr/bin/refdb-backup line 193 (should be >word 2>&1):
> ${refdbc} -C getref -d ${db} -t ${format} -o ${reffile} ":ID:>0" \
> &> /dev/null
>
>possible bashism in ./usr/bin/refdb-backup line 199 (should be >word 2>&1):
> ${refdbc} -C getnote -d ${db} -t xnote -o ${notefile} ":NID:>0" \
> &> /dev/null
>
>possible bashism in ./usr/bin/refdb-backup line 206 (should be >word
>2>&1):
>mkdir ${styles_directory} &> /dev/null
>possible bashism in ./usr/bin/refdb-backup line 217 (should be >word 2>&1):
> ${refdba} -C getstyle -o ${stylefile} ${style} &> /dev/null
>possible bashism in ./usr/bin/refdb-backup line 235 (should be >word
>2>&1):
>mv -f ${archive} ${backup_dir} &> /dev/null
>possible bashism in ./usr/bin/refdb-restore line 133 (should be >word
>2>&1):
>tar -tzf ${archive} &> /dev/null || \
> endScript "'${archive}' is not a valid archive." "failed"
>
>possible bashism in ./usr/bin/refdb-restore line 137 (should be >word
>2>&1):
> ${refdba} -C listdb &> /dev/null || \
> endScript "Error: Unable to access RefDB using client 'refdba'."
> "failed"
>
>possible bashism in ./usr/bin/refdb-restore line 139 (should be >word
>2>&1):
>${refdbc} -C listdb &> /dev/null || \
> endScript "Error: Unable to access RefDB using client 'refdbc'."
> "failed"
>
>possible bashism in ./usr/bin/refdb-restore line 167 (should be >word
2>&1):
> tar -xzf ${archive} ${reffile} &> /dev/null
>
>possible bashism in ./usr/bin/refdb-restore line 171 (should be >word
>2>&1):
> refdba -C createdb ${db} &> /dev/null
>
>possible bashism in ./usr/bin/refdb-restore line 176 (should be >word
>2>&1):
> refdbc -C addref -d ${db} -t ${format} ${reffile} &>
> /dev/null
>
>possible bashism in ./usr/bin/refdb-restore line 183 (should be >word
>2>&1):
> tar -xzf ${archive} ${notefile} &> /dev/null
>
>possible bashism in ./usr/bin/refdb-restore line 187 (should be >word
>2>&1):
> refdbc -C addnote -d ${db} ${notefile} &> /dev/null
>possible bashism in ./usr/bin/refdb-restore line 197 (should be >word
>2>&1):
> tar -xzf ${archive} ${stylefile} &> /dev/null
>
>possible bashism in ./usr/bin/refdb-restore line 206 (should be >word
>2>&1):
> refdba -C addstyle ${stylefile} &> /dev/null
Not using bash (or a Debian Policy conformant shell interpreter which
doesn't provide such an extra feature) as /bin/sh is likely to lead to
errors or unexpected behaviours.
You can find hints about how to fix bashisms at:
https://wiki.ubuntu.com/DashAsBinSh
Thank you,
Raphael Geissert
More information about the debian-xml-sgml-pkgs
mailing list