def system_call(*args)
      result = SystemCall.call(*args)
      return result.success_result if result.success?
      return yield(result.error_result) if block_given?

      result.error_result
    end
def system_call(*args)
      result = SystemCall.call(*args)
      return result.success_result if result.success?
      return yield(result.error_result) if block_given?

      result.error_result
    end
Initiates a system call with the given arguments.

 @param [Array] args The arguments for the system call.

 @overload system_call(*args)
   @return [String] The output of STDOUT or STDERR, depending of the exit
     status of the called command.

 @overload system_call(*args, &block)
   @yield [error_result] A block yielded when the called command exited
     unsuccessfully.
   @yieldparam [String] error_result The STDERR output.
   @return [Object] The value the called block returns.