MISSION 386

Glob Patterns and Wildcards

At the end of the Modifying the Filesystem mission, you read that you were going to learn what glob patterns and wildcards are. In this mission, you’ll start diving into those topics, and learn how to use them.

As you learned in the last mission, you can modify the filesystem in many different ways. One of the other ways you can use the filesystem is to search for files. Glob patterns and wildcards can be used to extend your file searching ability, making it easier to (for example) search for all files that meet certain criteria.

In this mission, you'll learn to use different kinds of wildcards and characters to extend your knowledge of the command line and make it easier to find the precise files you need quickly.

If you're familiar with regular expressions, glob patterns work in a similar way, only the characters are used and their roles are a bit different. Glob patterns are built from special characters called wildcards, and from regular characters.

(If you're familiar with using wildcards when searching for files using the graphical user interface, nothing really changes when using those characters in one interface versus the other, but in this mission you’ll get practice using them in the terminal, just in case).

Using glob patterns and wildcards can be confusing at times. At every step in this mission — as is always the case on Dataquest — you’ll be able to apply what you’ve learned and check that you’ve understood everything correctly before progressing to the next stage. 

What You'll Learn

  • What glob patterns and wildcards are
  • How to use wildcards
  • How to search for files

Mission Outline

1. Wildcards and Globbing Patterns
2. The * Wildcard
3. The ? Wildcard
4. Escaping Characters
5. The Wildcard []
6. Other Wildcards
7. Summary and Practice
8. Searching for Files
9. Next Steps
10. Takeaways

Course Info:

Beginner

The median completion time for this course is 4 hours. View details

This course requires a basic subscription. It includes five missions and it is the ninth course in the Data Analyst in Python path and Data Scientist in Python path.

START LEARNING FREE

Take a Look Inside