Class: SshConfig::ParseRun
- Inherits:
-
Object
- Object
- SshConfig::ParseRun
- Defined in:
- lib/ssh_config/loader.rb
Overview
Internal method for parsing
Instance Method Summary collapse
Instance Method Details
#parse_host(arg) ⇒ Object
24 25 26 27 28 29 30 31 32 |
# File 'lib/ssh_config/loader.rb', line 24 def parse_host(arg) hosts = arg .split(/\s+/) .reject { |host| host =~ /^\d|%|\*/ } return if hosts.empty? entry = Entry.new(hosts) entry.distinct_names.each { |host| results[host] = entry } end |
#results ⇒ Object
34 35 36 |
# File 'lib/ssh_config/loader.rb', line 34 def results @results ||= {} end |