Shell Programming/String comparison

From Wikibooks, open books for an open world
< Shell Programming
Jump to navigation Jump to search


  string1 = string2  equal
  string1 != string2  not equal
  -n string  not null
  -z string null