Disable the parse method with a decent error message. It should only be used internally now.

This commit is contained in:
Chris Eppstein 2010-02-13 17:19:57 -08:00
parent 8172fce22a
commit 9cca38f85d

View File

@ -10,7 +10,7 @@ module Compass
module ClassMethods module ClassMethods
def new_from_file(config_file) def new_from_file(config_file)
data = Data.new(config_file) data = Data.new(config_file)
data.parse(config_file) data._parse(config_file)
data data
end end
@ -22,8 +22,12 @@ module Compass
end end
module InstanceMethods module InstanceMethods
# parses a configuration file which is a ruby script
def parse(config_file) def parse(config_file)
raise Compass::Error, "Compass.configuration.parse(filename) has been removed. Please call Compass.add_project_configuration(filename) instead."
end
# parses a configuration file which is a ruby script
def _parse(config_file)
unless File.readable?(config_file) unless File.readable?(config_file)
raise Compass::Error, "Configuration file, #{config_file}, not found or not readable." raise Compass::Error, "Configuration file, #{config_file}, not found or not readable."
end end