Class: Kanrisuru::Core::Apt::Parser::Search
- Defined in:
- lib/kanrisuru/core/apt/parsers/search.rb
Class Method Summary collapse
Methods inherited from Base
extract_single_line, parse_apt_line, parse_apt_sources, parse_comma_values
Class Method Details
.parse(command) ⇒ Object
9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 |
# File 'lib/kanrisuru/core/apt/parsers/search.rb', line 9 def parse(command) lines = command.to_a lines.shift lines.shift result = [] lines.each do |line| next unless line.include?('/') item = parse_apt_line(line) next unless item result << item end result end |