Modified little bit to allow users to choose extra information.

Usage is like below.

```
$ crew search vi
(i) vim: Vim is a highly configurable text editor built to make creating and changing any kind of text very efficient.
(i) vidstab: Transcode video stabilization plugin.
vifm: Vifm is an ncurses based file manager with vi like keybindings/modes/options/commands/configuration, which also borrows some useful ideas from mutt.
(i) libxvid: The free video codec that is strong in compression and quality.
neovim: Neovim is a refactor, and sometimes redactor, in the tradition of Vim (which itself derives from Stevie).
$ crew search vi extra
(i) vim: Vim is a highly configurable text editor built to make creating and changing any kind of text very efficient.
http://www.vim.org/
version 8.0-1
(i) vidstab: Transcode video stabilization plugin.
http://public.hronopik.de/vid.stab/
version 0.98b
vifm: Vifm is an ncurses based file manager with vi like keybindings/modes/options/commands/configuration, which also borrows some useful ideas from mutt.
https://vifm.info/
version 0.8.2
(i) libxvid: The free video codec that is strong in compression and quality.
https://www.xvid.com/
version 1.3.4
neovim: Neovim is a refactor, and sometimes redactor, in the tradition of Vim (which itself derives from Stevie).
https://neovim.io/
version 0.1.7
$ crew search ^vim$ extra
(i) vim: Vim is a highly configurable text editor built to make creating and changing any kind of text very efficient.
http://www.vim.org/
version 8.0-1
```
parent 6918a2c4
......@@ -157,7 +157,7 @@ def regexp_search(pkg_name)
results = Dir["#{CREW_LIB_PATH}packages/*.rb"] \
.select { |f| File.basename(f, '.rb') =~ Regexp.new(pkg_name, true) } \
.collect { |f| File.basename(f, '.rb') } \
.each { |f| set_package(f) }
.each { |f| print_package(f, ARGV[2] == "extra") }
abort "Package not found :(" unless results.length > 0
end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment