There are two script types that may be modified. Scripts other than those written in Perl may have any name convention. Perl script should have a file suffix of ".sin" and contain in the first line an alias for perl (see the template example below).

Procedure for modifying software in the kroot directory tree for NIRES.

Script Template for non perl scripts

Template below is found in the ~lris_sh dir.
#!/usr/local/bin/tcsh -f
# 
# Name:
#       script_template
#
# Purpose:
#       
# 
# Usage:
#       
# where:
#       
# 
# Output:
#       
# 
# Modification history:
#       2000-Jul-25     MK      template version
#-----------------------------------------------------------------------

# if debugging, do not make motor moves...
if ( "$1" == "-debug" ) then
  echo "Entering DEBUG MODE!"
  echo ""
  shift
endif

exit

Perl Script Template

#!@PERL@ -w
#+
# NAME:  template 
#
# Purpose:
#       Do nothing but provide a template for future use.
#
# Usage:
#       template -debug
#
# Arguments:
#       -debug = debug mode
#
# Output:
#       to STDOUT
#
# Restrictions:
#       none
#
# Exit values:
#
# Example:
#
# Modification history:
#       2006-Dec-20     MK    template version
#-----------------------------------------------------------------------

# check for -verbose flag...
global verbose
set verbose 0
if { [lsearch -regexp $argv {^-v}] > -1 } {
    set verbose 1
}

# check for -debug flag...
global debug
set debug 0
if { [lsearch -regexp $argv {^-d}] > -1 } {
    set debug 1
    set verbose 1
}

if { $debug }{echo "DEBUG MODE"}
if { $verbose } {echo "Verbose triggered"}