Sha256: 2d656dabd5ece819d9577f4a579674228e341fecc43f842300a1e6864de36dc7

Contents?: true

Size: 644 Bytes

Versions: 3

Compression:

Stored size: 644 Bytes

Contents

class OcNOS < Oxidized::Model
  using Refinements

  prompt /([\w.@-]+[#>]\s?)$/
  comment '# '

  cfg :ssh do
    post_login 'terminal length 0'
    pre_logout do
      send "disable\r"
      send "logout\r"
    end
  end

  cmd :all do |cfg|
    cfg.lines.to_a[1..-2].join
  end

  cmd 'show version' do |cfg|
    comment cfg
  end

  cmd 'show system fru' do |cfg|
    comment cfg
  end

  cmd 'show system-information board-info' do |cfg|
    comment cfg
  end

  cmd 'show forwarding profile limit' do |cfg|
    comment cfg
  end

  cmd 'show license' do |cfg|
    comment cfg
  end

  cmd 'show running-config' do |cfg|
    cfg
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
oxidized-0.31.0 lib/oxidized/model/ocnos.rb
oxidized-0.30.1 lib/oxidized/model/ocnos.rb
oxidized-0.30.0 lib/oxidized/model/ocnos.rb