Mark config.enable_nfs as deprecated

This commit is contained in:
Fabio Rehm 2014-02-01 00:04:51 -02:00
parent 3b83867427
commit cdf13d3f70
2 changed files with 11 additions and 1 deletions

View file

@ -4,6 +4,8 @@ BACKWARDS INCOMPATIBILITY:
- Automatic handling of multiple machine scoped cache dirs from versions
prior to 0.3.0 of this plugin was removed.
- Support for `enable_nfs` has been deprecated and will be removed on 0.7.0,
please use `cache.synced_folder_opts = {type: 'nfs'}` instead.
## [0.5.1](https://github.com/fgrehm/vagrant-cachier/compare/v0.5.0...v0.5.1) (Dec 20, 2013)

View file

@ -1,7 +1,7 @@
module VagrantPlugins
module Cachier
class Config < Vagrant.plugin(2, :config)
attr_accessor :scope, :auto_detect, :enable_nfs, :synced_folder_opts
attr_accessor :scope, :auto_detect, :synced_folder_opts
attr_reader :buckets
ALLOWED_SCOPES = %w( box machine )
@ -16,6 +16,14 @@ module VagrantPlugins
(@buckets ||= {})[bucket] = opts
end
def enable_nfs=(value)
puts "The `enable_nfs` config for vagrant-cachier has been deprecated " \
"and will be removed on 0.7.0, please use " \
"`synced_folder_opts = { type: 'nfs' }` instead."
@synced_folder_opts = { type: 'nfs' } if value
end
def validate(machine)
errors = _detected_errors