Hello On Fri, Jan 21, 2011 at 03:13:05PM +0200, Teodor MICU wrote: > 2011/1/21 Agustin Martin <agmar...@debian.org>: > > if [ "$MILTERSOCKET" ] && [ "`echo $MILTERSOCKET | grep -v ^inet`" ]; then > > > > but as Teodor points out (just read it), second check seems to be enough. > > Only that I realized latter the intention of this construction. My > previous suggestion was to use this construction on its own without > "test": > > if echo "$MILTERSOCKET" | grep -q -v "^inet"; then > ... > fi > (the return code is set by grep) > > This works too but there is an extra test for the empty string: > if [ "$(echo $MILTERSOCKET | grep -v ^inet)" ]; then > ... > fi > (the return code is set by 'test')
Will check this deeper. > > Thanks > Thank you Harald -- To UNSUBSCRIBE, email to debian-bugs-rc-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org