Search Contact information
University of Cambridge Home Department of Engineering
University of Cambridge >  Engineering Department >  computing help
next up previous contents
Next: Arguments from the command Up: Shell Programming Previous: Shell Programming   Contents

Wildcard characters

The * and ? characters have a special meaning to the shell when used where filenames are expected. If you have files called bashful, sneezy and grumpy in your directory and you type
  ls *y
you'll list sneezy and grumpy because * can represent any number of characters (except an initial '.'). ? represents a single character, so
  ls *u?
will only print filenames whose penultimate letter is u.



Tim Love 2010-04-27