Search code examples
bashmanpage

Quick search of command options in bash


I found myself in a situation where I constantly look for parameters of a command in bash. For instance, find -type f -name '*py' -print0. In order to find all of those I need to go through man,info, or --help option which is laborious and time consuming. Is there any way to make this search instant. Ideally, I would love to see something like: find -type --help stating help on type option of find.


Solution

  • If your man pages open in less you can use / to search over it.

    man find

    /-type

    n, for next search

    N for previous search