lib/bundler/errors.rb in bundler-1.13.7 vs lib/bundler/errors.rb in bundler-1.14.0.pre.1

- old
+ new

@@ -50,10 +50,12 @@ class SecurityError < BundlerError; status_code(19); end class LockfileError < BundlerError; status_code(20); end class CyclicDependencyError < BundlerError; status_code(21); end class GemfileLockNotFound < BundlerError; status_code(22); end class PluginError < BundlerError; status_code(29); end + class SudoNotPermittedError < BundlerError; status_code(30); end + class ThreadCreationError < BundlerError; status_code(33); end class GemfileEvalError < GemfileError; end class MarshalError < StandardError; end class PermissionError < BundlerError def initialize(path, permission_type = :write) @@ -128,7 +130,27 @@ def message "Attempting to #{action} `#{@path}` is unsupported by your OS." end status_code(28) + end + + class NoSpaceOnDeviceError < PermissionError + def message + "There was an error while trying to #{action} `#{@path}`. " \ + "There was insufficent space remaining on the device." + end + + status_code(31) + end + + class GenericSystemCallError < BundlerError + attr_reader :underlying_error + + def initialize(underlying_error, message) + @underlying_error = underlying_error + super("#{message}\nThe underlying system error is #{@underlying_error.class}: #{@underlying_error}") + end + + status_code(32) end end