#!/bin/bash

CLIENT=/Home/p1/sameer/charm/net-sol/pgms/scheduler/client
HOST=localhost
PORT=7999
DIR=$(/bin/pwd)

if [ "x$1" = "x" ]  || [ "$1" = "-help" ] || [ "$1" = "-h" ];
	then echo "frun <program_name> <options> [<arguments>]"
	echo "frun interactively runs the job on the parallel machine"
	echo "program_name is the name of your compiled executable or script,"
	echo "you should not provide an mpirun or charmrun"
	echo "Options"
	echo "-stdout <filename>: The Std. Output file of the job"
	echo "-stderr <filename>: The Std. Error file of the job"
	echo "-stdin <filename>: The Std. Input file of the job"
	echo "-type [mpi/charm/mcharm/uni]: The type of the job"
	echo "-pwd <directory name>: Process Working Directory, default is current directory"
	echo "-minpe <value> : minimum number of processors used by the job"
	echo "-maxpe <value> : maximum number of processors used by the job"
	echo "#Processors allocated to the job varies between these bounds"
	echo "-time <hh:mm:ss> : time requested for the job";
else
   $CLIENT $HOST $PORT job -pwd $DIR $*
fi
	
