Quantcast
Channel: csh: how to test for blank correctly? - Super User
Viewing all articles
Browse latest Browse all 2

csh: how to test for blank correctly?

$
0
0

I want to test if a variable is totally empty in csh.

set R='dddd aaa'
if ( '${R}' ) then
    echo not empty

else
    echo 1111
endif

However it apparently does not work.

It gives this error message:

/usr/bin/test: argument expected
if: Expression Syntax.

Viewing all articles
Browse latest Browse all 2

Trending Articles