Merge pull request #5399 from delftswa2014/improve-package-error-message
Improved the package error message
This commit is contained in:
commit
03b945d4d0
|
@ -29,9 +29,10 @@ module Vagrant
|
|||
|
||||
def call(env)
|
||||
@env = env
|
||||
|
||||
file_name = File.basename(@env["package.output"].to_s)
|
||||
|
||||
raise Errors::PackageOutputDirectory if File.directory?(tar_path)
|
||||
raise Errors::PackageOutputExists if File.exist?(tar_path)
|
||||
raise Errors::PackageOutputExists, file_name:file_name if File.exist?(tar_path)
|
||||
raise Errors::PackageRequiresDirectory if !env["package.directory"] ||
|
||||
!File.directory?(env["package.directory"])
|
||||
|
||||
|
|
|
@ -1749,7 +1749,7 @@ en:
|
|||
packaging: "Packaging additional file: %{file}"
|
||||
compressing: "Compressing package to: %{tar_path}"
|
||||
output_exists: |-
|
||||
The specified file to save the package as already exists. Please
|
||||
The specified file '%{file_name}' to save the package as already exists. Please
|
||||
remove this file or specify a different file name for outputting.
|
||||
output_is_directory: |-
|
||||
The specified output is a directory. Please specify a path including
|
||||
|
|
Loading…
Reference in New Issue