lib/trackler/implementation.rb in trackler-2.1.0.13 vs lib/trackler/implementation.rb in trackler-2.1.0.14

- old
+ new

@@ -9,11 +9,10 @@ "\/\.$", "/\.meta/" ] attr_reader :track, :problem - attr_writer :files def initialize(track, problem) @track = track @problem = problem end @@ -27,9 +26,18 @@ def files @files ||= Hash[file_bundle.paths.map {|path| [path.relative_path_from(implementation_dir).to_s, File.read(path)] }].merge("README.md" => readme) + end + + def files=(value) + warn "DEPRECATION WARNING: 'Implementation#files=' is no longer public, please use 'implementation.merge_files' instead." + @files = value + end + + def merge_files(new_files) + files.merge!(new_files) end def zip @zip ||= file_bundle.zip do |io| io.put_next_entry('README.md')