admin_vr400_script/cli

17 lines
338 B
Ruby
Executable File

#!/usr/bin/env ruby
require_relative "lib/router"
require_relative "lib/router/admin"
warn "You may want to run this with rlwrap".yellow
admin = Router::Admin.new
admin.auto_login!
loop do
$stderr.print "#{@display_local_ip}> ".on_blue
str = gets&.chomp
exit(0) if str.nil? || str == "exit"
admin.arbitrary!(str.chomp)
end