Skip to content

Implement whereis #396

@PrasannaPaithankar

Description

@PrasannaPaithankar

Implementing https://github.com/util-linux/util-linux/blob/master/misc-utils/whereis.1.adoc

I'll am taking this up, but facing the following issue:

The search restrictions (options -b, -m and -s) are cumulative and apply to the subsequent name patterns on the command line. Any new search restriction resets the search mask. For example,

whereis -bm ls tr -m gcc

searches for "ls" and "tr" binaries and man pages, and for "gcc" man pages only.

whereis has sticky, resettable options and clap doesn't have a clear support for doing the same.
(The approach would be to use .trailing_var_arg(true) and use a simple match as in the original C source. This defeats the purpose of clap)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions