Type in a command, or "ls dictionary" to search all commands for "dictionary", etc.

ifEqual

ifthen -value1 ${value1} -value2 ${value2} -test EQUAL -then ${then} -else ${else} -redirect ${redirect=false}
NAME
     ifEqual - Checks if two values are equal to each other.

SYNOPSIS
     ifEqual -value1 [VALUE 1] -value2 [VALUE 2] -then [RESULT IF TRUE] -else [RESULT IF FALSE] -redirect [REDIRECT]

EXAMPLES
     ifEqual -value1 2 -value2 4 -then yay -else nay
          (returns 'nay' because the two values are not equal)

     ifEqual -value1 yub -value2 yub -then http://www.yubnub.org/ -redirect true
          (redirects to www.yubnub.org because the values are equal)

DESCRIPTION
     Compares two values and returns a result depending on if they are equal or not.

     -value1, -value2, and -then are required parameters.

     The '-redirect' parameter can be set to True or False. It defaults to False. If set to True and
     the result of the command begins with "HTTP://" then the the command will attempt to
     redirect the user to the web site.

AUTHOR
     Allen Ormond
     This is a simple remix of ifThen, inspired by ifEmpty and ifnotempty. Also, check out
     its sister command, ifNotEqual.
    
176 uses - Created 2006-03-26 16:15:25 - Last used 2012-04-27 14:33:11
Is this command broken? Tell Jon if you know how to fix it.
Do you find this command offensive? Let Jon know.