Previous Section  < Day Day Up >  Next Section

LAB 36: SHELL METACHARACTERS

  1. Create a directory called meta. Cd to that directory. Use touch to create the following files (the touch command creates a new empty file or updates the timestamp on an existing file):

    abc abc1 abc2 abc2191 Abc1 ab2 ab3 ab345 abc29 abc9 abc91 abc21xyz abc2121 noone nobody nothing nowhere

  2. Do the following:

    1. List all files that start with a lowercase a.

    2. List all files starting with uppercase A followed by two characters.

    3. List all files that end in a number.

    4. List all files that match one number after abc.

    5. List all files that match nothing or noone.

    6. List all files that match one or more numbers after abc.

    7. List all files that do not contain the pattern abc.

    8. List all files that contain ab followed by a 3 or 4.

    9. List all files starting with a or A, followed by b, and ending in one number.

    10. What is the error message if there is not a match?

    Previous Section  < Day Day Up >  Next Section