PDF Version Available

This document is also available in PDF format: cmdsandwildcards.pdf

The PDF version includes bookmarks for easy navigation and is optimized for printing.

Accessibility Notice

This document is also available in HTML format at:

https://aholdengouveia.name/IntroLinux/labs/cmdsandwildcards.html

The HTML version provides enhanced accessibility features including keyboard navigation, screen reader support, responsive design, dark mode support, and high contrast options.

Objectives:

Complete the following problems

References, a video, a PowerPoint and some notes are available at my website https://www.aholdengouveia.name/IntroLinux/cmdsandwildcards.html

How to setup for this lab

  1. Create a test subdirectory for this lab. I do NOT recommend using any spaces in the name of the files or folders.
  2. Using touch create at least a dozen files with different names with the following characteristics: enumerate
  3. Some start with f
  4. Some start with F
  5. Some start with a number
  6. Some end with a number
  7. Some do not have an f or F
  8. Some do not have a number
  9. At least one starts with a . (hidden file)

If you're struggling to think of names, use a naming scheme such as characters from your favorite video game, or locations and characters from favorite books etc. Make sure your files are full names of at least 5 characters, not just single letters/numbers For each of the problems you should start with ls and then figure out the pattern needed to show the requested information, then pick 1 of them to try with find instead. Demo of how to use ls is in the Linux FAQ videos https://youtube.com/playlist?list=PLQOmuLC45eoQlIMH7oCNL6yFP7kWQubBo&si=R1SFWzEPHDDo-VBJ

Problems to solve

  1. All files
  2. All files including hidden files.
  3. Files that start with “f”
  4. Files that start with “f” or “F”
  5. Files that have “f” or “F” anywhere in the name
  6. Files that have a digit in the name
  7. Files that start with a through d
  8. Files that end with 1 or 2
  9. Experiment with the find command by solving one of the above questions using find instead of ls.

Deliverables