<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Try single quotes and see if that helps out. I've had similar issues
in the past. Also, you shouldn't need the "" after [Mm]; it's
superfluous.<br>
<br>
--TP<br>
<div class="moz-signature">_______________________________
<br>
Do you <a href="http://www.gnu.org">GNU</a>?
<br>
<a href="http://www.cmosnetworks.com">Microsoft Free since 2003</a>--the
ultimate antivirus protection!
<br>
</div>
<br>
<br>
Peter Hartmann wrote:
<blockquote
cite="mid9bd317560803080916j27a4969es35fc0d6215d894bb@mail.gmail.com"
type="cite">
<pre wrap="">Ok so this works in ksh:
if [ ! -d "/home/vpopmail/domains/ascensionschoolnyc.org/"$name"/Maildir/."[Ss][Pp][Aa][Mm]""
];
Why not bash?
Peter
On Sat, Mar 8, 2008 at 12:01 PM, Peter Hartmann <a class="moz-txt-link-rfc2396E" href="mailto:ascensiontech@gmail.com"><ascensiontech@gmail.com></a> wrote:
</pre>
<blockquote type="cite">
<pre wrap="">I'm trying to test if vpopmail users have a spam folder already, but
I'd like to make the directory test case insensitive.
snip:
if [ ! -d "/home/vpopmail/domains/domain.com/$name/Maildir/.[Ss][Pp][Aa][Mm]" ];
then
echo not there
fi
This way the test fails even if there is a .spam folder.
Without the quotes the regex is interpreted but when the directory is
there, I get a 'binary operator expected' error for the 'if' line.
What am I not getting?
Thanks,
Peter
</pre>
</blockquote>
<pre wrap=""><!---->
_______________________________________________
K12OSN mailing list
<a class="moz-txt-link-abbreviated" href="mailto:K12OSN@redhat.com">K12OSN@redhat.com</a>
<a class="moz-txt-link-freetext" href="https://www.redhat.com/mailman/listinfo/k12osn">https://www.redhat.com/mailman/listinfo/k12osn</a>
For more info see <a class="moz-txt-link-rfc2396E" href="http://www.k12os.org"><http://www.k12os.org></a>
</pre>
</blockquote>
</body>
</html>