lib/nanoc/base/compilation/dependency_tracker.rb in nanoc-3.7.4 vs lib/nanoc/base/compilation/dependency_tracker.rb in nanoc-3.7.5
- old
+ new
@@ -1,9 +1,8 @@
# encoding: utf-8
module Nanoc
-
# Responsible for remembering dependencies between items and layouts. It is
# used to speed up compilation by only letting an item be recompiled when it
# is outdated or any of its dependencies (or dependencies’ dependencies,
# etc) is outdated.
#
@@ -18,11 +17,10 @@
# The dependency tracker remembers the dependency information between runs.
# Dependency information is stored in the `tmp/dependencies` file.
#
# @api private
class DependencyTracker < ::Nanoc::Store
-
# @return [Array<Nanoc::Item, Nanoc::Layout>] The list of items and
# layouts that are being tracked by the dependency tracker
attr_reader :objects
# @return [Nanoc::Compiler] The compiler that corresponds to this
@@ -174,12 +172,12 @@
protected
def data
{
- :edges => @graph.edges,
- :vertices => @graph.vertices.map { |obj| obj && obj.reference }
+ edges: @graph.edges,
+ vertices: @graph.vertices.map { |obj| obj && obj.reference }
}
end
def data=(new_data)
# Create new graph
@@ -205,9 +203,7 @@
next unless obj.is_a?(Nanoc::Item)
@graph.add_edge(new_obj, obj)
end
end
end
-
end
-
end