How to use find

  • Finding all files containing string "get_map"
    $ find . -name *.c | xargs grep -l get_map
  • A more sophisticated use:
    $ find . -name '*.[ch]' -print0 | xargs -r -0 grep -l get_map

    find: -print0
    xargs: -0 -r

  • on Cygwin, Windows file are usually case insensitive, one might need/want to make the search case-insensitive using the -iname option
    $ find /cygdrive/c/WINDOWS/Microsoft.NET -iname "msbuild.*"