From 5b3c6b8ad466815c906e2d2aae5a2b91451cb534 Mon Sep 17 00:00:00 2001 From: Brian Cain Date: Mon, 11 Mar 2019 14:21:55 -0700 Subject: [PATCH] Fixes #10723: Fix bug instance var in Vagrant Cloud CLI optparse This commit uses the correct instance variable for the optparse library when reading in the command line flags for various Vagrant Cloud CLI commands. --- plugins/commands/cloud/box/create.rb | 2 +- plugins/commands/cloud/box/delete.rb | 2 +- plugins/commands/cloud/provider/create.rb | 2 +- plugins/commands/cloud/provider/delete.rb | 2 +- plugins/commands/cloud/provider/update.rb | 2 +- plugins/commands/cloud/provider/upload.rb | 2 +- plugins/commands/cloud/publish.rb | 2 +- plugins/commands/cloud/search.rb | 2 +- plugins/commands/cloud/version/create.rb | 2 +- plugins/commands/cloud/version/delete.rb | 2 +- plugins/commands/cloud/version/release.rb | 2 +- plugins/commands/cloud/version/revoke.rb | 2 +- plugins/commands/cloud/version/update.rb | 2 +- 13 files changed, 13 insertions(+), 13 deletions(-) diff --git a/plugins/commands/cloud/box/create.rb b/plugins/commands/cloud/box/create.rb index 1195b88c3..5027872e6 100644 --- a/plugins/commands/cloud/box/create.rb +++ b/plugins/commands/cloud/box/create.rb @@ -19,7 +19,7 @@ module VagrantPlugins o.on("-d", "--description DESCRIPTION", String, "Full description of the box") do |d| options[:description] = d end - o.on("-u", "--username USERNAME_OR_EMAIL", String, "Vagrant Cloud username or email address") do |t| + o.on("-u", "--username USERNAME_OR_EMAIL", String, "Vagrant Cloud username or email address") do |u| options[:username] = u end o.on("-s", "--short-description DESCRIPTION", String, "Short description of the box") do |s| diff --git a/plugins/commands/cloud/box/delete.rb b/plugins/commands/cloud/box/delete.rb index 90ecc4bc6..a0a01ad5f 100644 --- a/plugins/commands/cloud/box/delete.rb +++ b/plugins/commands/cloud/box/delete.rb @@ -16,7 +16,7 @@ module VagrantPlugins o.separator "Options:" o.separator "" - o.on("-u", "--username USERNAME_OR_EMAIL", String, "Vagrant Cloud username or email address") do |t| + o.on("-u", "--username USERNAME_OR_EMAIL", String, "Vagrant Cloud username or email address") do |u| options[:username] = u end end diff --git a/plugins/commands/cloud/provider/create.rb b/plugins/commands/cloud/provider/create.rb index 206164e0e..2adb6a42a 100644 --- a/plugins/commands/cloud/provider/create.rb +++ b/plugins/commands/cloud/provider/create.rb @@ -16,7 +16,7 @@ module VagrantPlugins o.separator "Options:" o.separator "" - o.on("-u", "--username USERNAME_OR_EMAIL", String, "Vagrant Cloud username or email address") do |t| + o.on("-u", "--username USERNAME_OR_EMAIL", String, "Vagrant Cloud username or email address") do |u| options[:username] = u end end diff --git a/plugins/commands/cloud/provider/delete.rb b/plugins/commands/cloud/provider/delete.rb index cc38f37e2..cb77b501d 100644 --- a/plugins/commands/cloud/provider/delete.rb +++ b/plugins/commands/cloud/provider/delete.rb @@ -16,7 +16,7 @@ module VagrantPlugins o.separator "Options:" o.separator "" - o.on("-u", "--username USERNAME_OR_EMAIL", String, "Vagrant Cloud username or email address") do |t| + o.on("-u", "--username USERNAME_OR_EMAIL", String, "Vagrant Cloud username or email address") do |u| options[:username] = u end end diff --git a/plugins/commands/cloud/provider/update.rb b/plugins/commands/cloud/provider/update.rb index 0b2052af6..897b13f2a 100644 --- a/plugins/commands/cloud/provider/update.rb +++ b/plugins/commands/cloud/provider/update.rb @@ -16,7 +16,7 @@ module VagrantPlugins o.separator "Options:" o.separator "" - o.on("-u", "--username USERNAME_OR_EMAIL", String, "Vagrant Cloud username or email address") do |t| + o.on("-u", "--username USERNAME_OR_EMAIL", String, "Vagrant Cloud username or email address") do |u| options[:username] = u end end diff --git a/plugins/commands/cloud/provider/upload.rb b/plugins/commands/cloud/provider/upload.rb index cd70ac043..f599745ce 100644 --- a/plugins/commands/cloud/provider/upload.rb +++ b/plugins/commands/cloud/provider/upload.rb @@ -17,7 +17,7 @@ module VagrantPlugins o.separator "Options:" o.separator "" - o.on("-u", "--username USERNAME_OR_EMAIL", String, "Vagrant Cloud username or email address") do |t| + o.on("-u", "--username USERNAME_OR_EMAIL", String, "Vagrant Cloud username or email address") do |u| options[:username] = u end end diff --git a/plugins/commands/cloud/publish.rb b/plugins/commands/cloud/publish.rb index 346170e38..2583be8b5 100644 --- a/plugins/commands/cloud/publish.rb +++ b/plugins/commands/cloud/publish.rb @@ -40,7 +40,7 @@ module VagrantPlugins o.on("-s", "--short-description DESCRIPTION", String, "Short description of the box") do |s| options[:short_description] = s end - o.on("-u", "--username USERNAME_OR_EMAIL", String, "Vagrant Cloud username or email address") do |t| + o.on("-u", "--username USERNAME_OR_EMAIL", String, "Vagrant Cloud username or email address") do |u| options[:username] = u end end diff --git a/plugins/commands/cloud/search.rb b/plugins/commands/cloud/search.rb index 0359400bc..ab62b181d 100644 --- a/plugins/commands/cloud/search.rb +++ b/plugins/commands/cloud/search.rb @@ -37,7 +37,7 @@ module VagrantPlugins o.on("--sort-by SORT", "Field to sort results on (created, downloads, updated) Default: downloads") do |s| options[:sort] = s end - o.on("-u", "--username USERNAME_OR_EMAIL", String, "Vagrant Cloud username or email address") do |t| + o.on("-u", "--username USERNAME_OR_EMAIL", String, "Vagrant Cloud username or email address to login with") do |u| options[:username] = u end end diff --git a/plugins/commands/cloud/version/create.rb b/plugins/commands/cloud/version/create.rb index 65efc63cd..0c92a3a0d 100644 --- a/plugins/commands/cloud/version/create.rb +++ b/plugins/commands/cloud/version/create.rb @@ -19,7 +19,7 @@ module VagrantPlugins o.on("-d", "--description DESCRIPTION", String, "A description for this version") do |d| options[:description] = d end - o.on("-u", "--username USERNAME_OR_EMAIL", String, "Vagrant Cloud username or email address") do |t| + o.on("-u", "--username USERNAME_OR_EMAIL", String, "Vagrant Cloud username or email address") do |u| options[:username] = u end end diff --git a/plugins/commands/cloud/version/delete.rb b/plugins/commands/cloud/version/delete.rb index 1d72c44e6..4dc77dcb6 100644 --- a/plugins/commands/cloud/version/delete.rb +++ b/plugins/commands/cloud/version/delete.rb @@ -15,7 +15,7 @@ module VagrantPlugins o.separator "" o.separator "Options:" o.separator "" - o.on("-u", "--username USERNAME_OR_EMAIL", String, "Vagrant Cloud username or email address") do |t| + o.on("-u", "--username USERNAME_OR_EMAIL", String, "Vagrant Cloud username or email address") do |u| options[:username] = u end end diff --git a/plugins/commands/cloud/version/release.rb b/plugins/commands/cloud/version/release.rb index 774abdd01..db0b612b0 100644 --- a/plugins/commands/cloud/version/release.rb +++ b/plugins/commands/cloud/version/release.rb @@ -15,7 +15,7 @@ module VagrantPlugins o.separator "" o.separator "Options:" o.separator "" - o.on("-u", "--username USERNAME_OR_EMAIL", String, "Vagrant Cloud username or email address") do |t| + o.on("-u", "--username USERNAME_OR_EMAIL", String, "Vagrant Cloud username or email address") do |u| options[:username] = u end end diff --git a/plugins/commands/cloud/version/revoke.rb b/plugins/commands/cloud/version/revoke.rb index 7ca1def9e..5d6aeaf74 100644 --- a/plugins/commands/cloud/version/revoke.rb +++ b/plugins/commands/cloud/version/revoke.rb @@ -15,7 +15,7 @@ module VagrantPlugins o.separator "" o.separator "Options:" o.separator "" - o.on("-u", "--username USERNAME_OR_EMAIL", String, "Vagrant Cloud username or email address") do |t| + o.on("-u", "--username USERNAME_OR_EMAIL", String, "Vagrant Cloud username or email address") do |u| options[:username] = u end end diff --git a/plugins/commands/cloud/version/update.rb b/plugins/commands/cloud/version/update.rb index 3b2afd307..7691f6e72 100644 --- a/plugins/commands/cloud/version/update.rb +++ b/plugins/commands/cloud/version/update.rb @@ -19,7 +19,7 @@ module VagrantPlugins o.on("-d", "--description DESCRIPTION", "A description for this version") do |d| options[:description] = d end - o.on("-u", "--username USERNAME_OR_EMAIL", String, "Vagrant Cloud username or email address") do |t| + o.on("-u", "--username USERNAME_OR_EMAIL", String, "Vagrant Cloud username or email address") do |u| options[:username] = u end end