From 02b08ac12c04a936eabe2018b39f4142cea77a8b Mon Sep 17 00:00:00 2001 From: Chris Roberts Date: Tue, 26 Jan 2021 16:38:47 -0800 Subject: [PATCH] Remove option parser modifications for storing flags --- lib/vagrant.rb | 18 ------------------ 1 file changed, 18 deletions(-) diff --git a/lib/vagrant.rb b/lib/vagrant.rb index 6647c854e..51b492cf3 100644 --- a/lib/vagrant.rb +++ b/lib/vagrant.rb @@ -24,29 +24,11 @@ module Vagrant attr_reader :flags def initialize(*_) - @flags = [] super Vagrant.default_cli_options.each do |opt_proc| opt_proc.call(self) end end - - def on(*opts, &block) - super - # TODO: make this not a disaster - if opts[0][0,2] == "--" - ln = opts[0].split(" ")[0][2..-1] - else - ln = opts[1].split(" ")[0][2..-1] - end - @flags.append( - { - long_name: ln, - description: opts[-1], - type: String - } - ) - end end end