More commands and switches

Learning outcomes:

  • Demonstrate finding files with several criteria
  • Show the use of ls with wildcards and recursive searches
  • Explain how to locate running processes and kill a process

Would you like to download my PowerPoint to follow along?

  • Using Switches
    • Commands have their own sentence structure
    • The basic pattern is "Command Switch Argument"
    • Switches give us the ability to get more details and power from commands
  • the find command
    • Search using find (or locate)
    • find -name myfile (basic)
    • find /etc -name passwd (within a folder)
    • find -name “*.txt” (search by extension)
    • find - testfile (case insensitive find)
    • Groups, user, file type, dirdctory, empty files, date, last access etc.
    • Video: How to use the find command
  • Wildcards
  • Processes

Suggested Activities and Discussion Topics:

  • Activity: Go to a Linux Emulator or Linux machine and try to solve the following problems using wildcards:
    • All files including hidden files
    • Files that start with “f”
    • Files that start with “f” or “F”
    • Files that have “f” or “F” anywhere in the name
    • Files that have a digit in the name
    • Files that start with a through d
    • Files that end with 1 or 2
    • Experiment with the find command. Include going to your home directory and using find.
  • Activity: Listen to This Podcast That was created using AI from these materials. Transcript for the Podcast What are your thoughts? Did the AI do a good job representing the materials? Did you find any mistakes?
  • Go through This AI generated study guide, what do you think? Did it capture the week materials well? How did you do on the self quiz? Do you know all the vocab used?
  • Go through This AI generated briefing document, what do you think? Did it capture the week materials well? Was there anything it missed? Do you know all the vocab used?

Would you like to see some more classes? Click here