From 8260a43aa07c7dd5851db08ca84673c7c72c4f2a Mon Sep 17 00:00:00 2001 From: Fabio Rehm Date: Sat, 1 Feb 2014 00:04:51 -0200 Subject: [PATCH] Mark `config.enable_nfs` as deprecated --- CHANGELOG.md | 2 ++ lib/vagrant-cachier/config.rb | 10 +++++++++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index a5e8b89..fc1556b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -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) diff --git a/lib/vagrant-cachier/config.rb b/lib/vagrant-cachier/config.rb index 77a3e97..933bbe8 100644 --- a/lib/vagrant-cachier/config.rb +++ b/lib/vagrant-cachier/config.rb @@ -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