Searching in Linux: Regular Expressions for Beginners

Find the files you are looking for and select only the useful lines with find, grep and regular expressions.
4.3 (39 ratings) Instead of using a simple lifetime average, Udemy calculates a
course's star rating by considering a number of different factors
such as the number of ratings, the age of ratings, and the
likelihood of fraudulent ratings.
1,944 students enrolled
$19
$20
5% off
Take This Course
  • Lectures 17
  • Length 1 hour
  • Skill Level Beginner Level
  • Languages English
  • Includes Lifetime access
    30 day money back guarantee!
    Available on iOS and Android
    Certificate of Completion
Wishlisted Wishlist

How taking a course works

Discover

Find online courses made by experts from around the world.

Learn

Take your courses with you and learn anywhere, anytime.

Master

Learn and practice real-world skills and achieve your goals.

About This Course

Published 2/2016 English

Course Description

Do you want to master regular expressions? Would you like to be able to search for files from the Linux command line based on their name, owner, permission or size? Do you want to be able to perform an action on any file of a specific type? Take this course and find out how.

This course will first take you through the basics of command line, changing and listing directories, wildcards, file and directory permissions. Even if you are an experienced Linux user, you might learn some interesting things from these lectures.

After this, you will go through the options, expressions and actions that are supported by the find command. You will be able to find files that, for instance, are owned by a particular user and exceed, or are under, a specific size. Or, you will be to do specific actions on specific files at the same time with only one command (e.g. create multiple archives based on the file types). I will also teach you about the locate command and its advantages and disadvantages over find.

The third section is about grep and regular expressions. I will help you take your first steps in learning regular expressions. They are a very powerful pattern matching tool. You will be able to use them together with grep to select particular lines inside files or on streams received at the standard input. You will see plenty of examples to understand what the metacharacters of regular expressions actually mean and how to use them to match strings.

What are the requirements?

  • Little to none experience with a Linux system
  • A host or a virtual machine running Linux is needed

What am I going to get from this course?

  • Find any file on a Linux filesystem
  • Use regular expressions in able to select files containing matching patterns.
  • Master the find, locate and grep commands
  • Understand Linux filesystem structure and file permissions

What is the target audience?

  • Linux beginners and intermediate users.

What you get with this course?

Not for you? No problem.
30 day money back guarantee.

Forever yours.
Lifetime access.

Learn on the go.
Desktop, iOS and Android.

Get rewarded.
Certificate of completion.

Curriculum

Section 1: Introduction
02:03

Quick walk-through of the curriculum of this course.

Section 2: Linux Folder Structure
04:17

How to navigate around the Linux directory structure. So you think you know all about the cd command...?

02:22

Watch this lecture to see what ls can do.

04:36

Basic file matching using the *,?,[] and {} wildcards.

04:13

You will learn how to keep others from overwriting your files.

4 questions

A few questions on setting and resetting file permissions

03:10

You must be able to execute directories.

Section 3: findutils - find and locate
03:58

Search for files based on their name.

02:33

Find files based on their owner.

02:39

See which files take the most space.

02:26

Put all criteria together in expressions.

04:52

Take actions on the files you find.

04:47

... and even more actions.

2 questions

Recap of the find options

03:11

Find files faster with locate and updatedb.

Section 4: Searching in Files - grep
03:26

Search inside file using grep.

06:27

Introduction to regular expressions.

02:41

... continued.

14:08

How to use grep together with regular expressions.

3 questions

A few questions on regular expressions and grep

Students Who Viewed This Course Also Viewed

  • Loading
  • Loading
  • Loading

Instructor Biography

Andrei Bunghez, Embedded Software Engineer | PM | Android Rookie

Hello! I am a passionate software engineer working mostly in the embedded networking world. I have a degree in Computer Science from the Politechnica University in Bucharest, major in Compilers and Operating Systems and have recently obtained an Android Developer Nanodegree from Udacity.

I have been an embedded software engineer for the past 12+ years, developing and maintaining software for a range of Ethernet devices. During this time I have been responsible for various parts of these systems, ranging from the higher levels of networking protocols like VLAN, STP, SNMP to chip drivers and distributed programming across Ethernet switches. At some point I started leading software releases and did a partial shift to project management, while still maintaining a keen interest in the embedded software practice. In the past few years I have added Android and Arduino on my list of interests and I am now working on a small pet project related to air quality, tying these two platforms together.

I usually prefer learning by example. So, it is only natural that this becomes my preferred way of teaching as well. My lectures are filled with examples that illustrate the main presented concept or topic.

I'm looking forward to seeing you in my courses!


Ready to start learning?
Take This Course