Forrest logo
back to the find tool

find:tldr:d74c9

find: Find directories matching a given name, in case-insensitive mode.
$ find ${root_path} -type d -iname '${*lib*}'
try on your machine

This command is using the find command to search for directories within the root_path directory that have names containing the string "lib" (case-insensitive).

  • find: This command is used to search for files and directories within a specified location.
  • ${root_path}: This is a variable representing the root directory path where the search will commence.
  • -type d: This option specifies that only directories should be included in the search results.
  • -iname '${*lib*}': This option specifies the pattern to match directory names against. The -iname flag makes the search case-insensitive. ${*lib*} is a placeholder, where * is a wildcard that matches any character (or string) before and after "lib". So, it will match any directory name containing "lib" in any position or multiple times within the name.
This explanation was created by an AI. In most cases those are correct. But please always be careful and never run a command you are not sure if it is safe.
back to the find tool