lib/linux_admin/network_interface.rb
# Runs the command `ip addr show <interface>`
#
# @return [String] The command output
# @raise [NetworkInterfaceError] if the command fails
Runs the command `ip addr show `
Runs the command ` ip addr show `
def ip_show
      Common.run!(Common.cmd("ip"), :params => ["addr", "show", @interface]).output
    rescue AwesomeSpawn::CommandResultError => e
      raise NetworkInterfaceError.new(e.message, e.result)
    end
def ip_show Common . run! ( Common . cmd ( "ip" ) , :params => [ "addr" , "show" , @interface ] ) . output rescue AwesomeSpawn :: CommandResultError => e raise NetworkInterfaceError . new ( e . message , e . result ) end
Runs the command `ip addr show <interface>`
Runs the command ` ip addr show <interface > `
The command output
The command output
String
[NetworkInterfaceError] if the command fails
[ NetworkInterfaceError ] if the command fails