From e634cdc824af128fdd0db9199a2bcdad9649f049 Mon Sep 17 00:00:00 2001 From: Teemu Matilainen Date: Sun, 2 Feb 2014 17:26:54 -0300 Subject: [PATCH] guests: rename LinuxShellExpandFailed error to ShellExpandFailed Make the error generic for all guests (`DarwinShellExpandFailed` didn't even exist) and not tied to synced folder. --- lib/vagrant/errors.rb | 8 ++++---- plugins/guests/darwin/cap/shell_expand_guest_path.rb | 2 +- plugins/guests/linux/cap/shell_expand_guest_path.rb | 2 +- templates/locales/en.yml | 10 +++++----- 4 files changed, 11 insertions(+), 11 deletions(-) diff --git a/lib/vagrant/errors.rb b/lib/vagrant/errors.rb index 0a7b1f479..204abd258 100644 --- a/lib/vagrant/errors.rb +++ b/lib/vagrant/errors.rb @@ -304,10 +304,6 @@ module Vagrant error_key(:linux_nfs_mount_failed) end - class LinuxShellExpandFailed < VagrantError - error_key(:linux_shell_expand_failed) - end - class LocalDataDirectoryNotAccessible < VagrantError error_key(:local_data_dir_not_accessible) end @@ -444,6 +440,10 @@ module Vagrant error_key(:shared_folder_create_failed) end + class ShellExpandFailed < VagrantError + error_key(:shell_expand_failed) + end + class SSHAuthenticationFailed < VagrantError error_key(:ssh_authentication_failed) end diff --git a/plugins/guests/darwin/cap/shell_expand_guest_path.rb b/plugins/guests/darwin/cap/shell_expand_guest_path.rb index 13a82979b..1fdcf5215 100644 --- a/plugins/guests/darwin/cap/shell_expand_guest_path.rb +++ b/plugins/guests/darwin/cap/shell_expand_guest_path.rb @@ -14,7 +14,7 @@ module VagrantPlugins if !real_path # If no real guest path was detected, this is really strange # and we raise an exception because this is a bug. - raise DarwinShellExpandFailed + raise ShellExpandFailed end # Chomp the string so that any trailing newlines are killed diff --git a/plugins/guests/linux/cap/shell_expand_guest_path.rb b/plugins/guests/linux/cap/shell_expand_guest_path.rb index 114edc415..341c0a1a8 100644 --- a/plugins/guests/linux/cap/shell_expand_guest_path.rb +++ b/plugins/guests/linux/cap/shell_expand_guest_path.rb @@ -17,7 +17,7 @@ module VagrantPlugins if !real_path # If no real guest path was detected, this is really strange # and we raise an exception because this is a bug. - raise LinuxShellExpandFailed + raise ShellExpandFailed end # Chomp the string so that any trailing newlines are killed diff --git a/templates/locales/en.yml b/templates/locales/en.yml index fd4590754..27d50e411 100644 --- a/templates/locales/en.yml +++ b/templates/locales/en.yml @@ -463,11 +463,6 @@ en: that the NFS client software is properly installed, and consult any resources specific to the linux distro you're using for more information on how to do this. - linux_shell_expand_failed: |- - Vagrant failed to determine the shell expansion of the guest path - for one of your shared folders. This is an extremely rare error case - and most likely indicates an unusual configuration of the guest system. - Please report a bug with your Vagrantfile. machine_guest_not_ready: |- Guest-specific operations were attempted on a machine that is not ready for guest communication. This should not happen and a bug @@ -591,6 +586,11 @@ en: %{path} Please create the folder manually or specify another path to share. + shell_expand_failed: |- + Vagrant failed to determine the shell expansion of a guest path + (probably for one of your shared folders). This is an extremely rare + error case and most likely indicates an unusual configuration of the + guest system. Please report a bug with your Vagrantfile and debug log. ssh_authentication_failed: |- SSH authentication failed! This is typically caused by the public/private keypair for the SSH user not being properly set on the guest VM. Please