diff options
author | Eelco Dolstra <edolstra@gmail.com> | 2020-12-23 21:10:32 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-12-23 21:10:32 +0100 |
commit | a93916b1905cd7b968e92cd94a3e4a595bff2e0f (patch) | |
tree | 178e04a23a35b9a4ede224bdcb903e75c188a304 /src/nix/search.cc | |
parent | 8927cba62f5afb33b01016d5c4f7f8b7d0adde3c (diff) | |
parent | 5178211e963fa111f84c4881b22cc506d5254fde (diff) |
Merge pull request #4336 from NixOS/manpages
Documentation for nix subcommands
Diffstat (limited to 'src/nix/search.cc')
-rw-r--r-- | src/nix/search.cc | 25 |
1 files changed, 5 insertions, 20 deletions
diff --git a/src/nix/search.cc b/src/nix/search.cc index 47770e128..9f864b3a4 100644 --- a/src/nix/search.cc +++ b/src/nix/search.cc @@ -41,29 +41,14 @@ struct CmdSearch : InstallableCommand, MixJSON std::string description() override { - return "query available packages"; + return "search for packages"; } - Examples examples() override + std::string doc() override { - return { - Example{ - "To show all packages in the flake in the current directory:", - "nix search" - }, - Example{ - "To show packages in the 'nixpkgs' flake containing 'blender' in its name or description:", - "nix search nixpkgs blender" - }, - Example{ - "To search for Firefox or Chromium:", - "nix search nixpkgs 'firefox|chromium'" - }, - Example{ - "To search for packages containing 'git' and either 'frontend' or 'gui':", - "nix search nixpkgs git 'frontend|gui'" - } - }; + return + #include "search.md" + ; } Strings getDefaultFlakeAttrPaths() override |