Suppress "Where are you?" Message

biff n
pdir=`pwd`

# check for null parameter
if [ $# -lt 1 ]; then
  echo current directory $pdir
  ls -latr
  echo
else
  p1=$1
  #check for directory entry only
  if [ -d $p1 ]; then
    pdir=$p1
    echo current directory $pdir
    cd $pdir
    ls -latr
    echo
  #check for directory entry and file
  elif [ -f $p1 ]; then
    pdir=`dirname $p1`
    echo current directory $pdir
    cd $pdir

    for f in $*
    do
      pfile=`basename $f`
      ls -altr $pfile
    done
  else
    echo $p1 not found
  fi
fi

# put a white space
echo

i have the above piece of code that accepts a parameter input to display directory file listing. the script runs fine on the unix command line with an example output of:

$ sh dir_file_list.sh /u02/app/pcrd/dev/out
current directory /u02/app/pcrd/dev/out
total 24
drwxr-xr-x    3 oracle   oracle          256 Jun 29 14:10 ..
-rw-r--r--    1 oracle   oracle         5597 Jul 04 18:00 PCARD_EXPORT_7.csv
drwxr-xr-x    2 oracle   oracle          256 Jul 06 18:00 .
-rw-r--r--    1 oracle   oracle          311 Jul 06 18:00 PCARD_EXPORT_8.csv

i created the script to run from a scheduler called TIDAL. basically the scheduler is tool that runs on a windows platform and has agents on each servers that operates and runs any programs. when the script runs from a scheduler it gets a message on the first line as "Where are you?":

Where are you?
current directory /u02/app/pcrd/dev/out
total 24
drwxr-xr-x    3 oracle   oracle          256 Jun 29 14:10 ..
-rw-r--r--    1 oracle   oracle         5597 Jul 04 18:00 PCARD_EXPORT_7.csv
drwxr-xr-x    2 oracle   oracle          256 Jul 06 18:00 .
-rw-r--r--    1 oracle   oracle          311 Jul 06 18:00 PCARD_EXPORT_8.csv

how do i suppress that "Where are you?" message? thanks.

my script has a line of code for "biff n" that is to suppress the mail notification or disable them. i observed that when we run the script from a scheduler (TIDAL Enterprise Scheduler) it gives us an output "Where are you?" message. if i removed that piece of code it is no longer giving us that message. i am thinking that on the succession run of the same script that is the time that it gives the message. i want to put a conditional if-then statement to check if the "biff" is currently set to "n". how do i put that into my script.

i tried this code but it never got it work.

if [biff n eq 0]; then
 echo yes
fi 

thanks,
warren

Do you want, perhaps, to run the script interactively, and if so, biff works, but if run from a scheduler, keep biff off? Try this:

if tty &>/dev/null ; then
   biff y
fi

Though this doesn't answer your question, I think it solves your problem.