lib/nanoc/base/compilation/filter.rb
def depend_on(items)
      # Notify
      items.each do |item|
        Nanoc::NotificationCenter.post(:visit_started, item)
        Nanoc::NotificationCenter.post(:visit_ended,   item)
      end

      # Raise unmet dependency error if necessary
      items.each do |item|
        rep = item.reps.find { |r| !r.compiled? }
        raise Nanoc::Errors::UnmetDependency.new(rep) if rep
      end
    end
# Creates a dependency from the item that is currently being filtered onto
# the given collection of items. In other words, require the given items
# to be compiled first before this items is processed.
#
# @param [Array<Nanoc::Item>] items The items that are depended on.
#
# @return [void]
Creates a dependency from the item that is currently being filtered onto
the given collection of items. In other words, require the given items
to be compiled first before this items is processed.
Creates a dependency from the item that is currently being filtered onto the given collection of items . In other words require the given items to be compiled first before this items is processed .
def depend_on(items)
      items.each do |item|
        Nanoc::NotificationCenter.post(:visit_started, item)
        Nanoc::NotificationCenter.post(:visit_ended,   item)
      end
      items.each do |item|
        rep = item.reps.find { |r| !r.compiled? }
        raise Nanoc::Errors::UnmetDependency.new(rep) if rep
      end
    end
def depend_on ( items ) items . each do | item | Nanoc :: NotificationCenter . post ( :visit_started , item ) Nanoc :: NotificationCenter . post ( :visit_ended , item ) end items . each do | item | rep = item . reps . find { | r | ! r . compiled? } raise Nanoc :: Errors :: UnmetDependency . new ( rep ) if rep end end
Creates a dependency from the item that is currently being filtered onto
the given collection of items.
Creates a dependency from the item that is currently being filtered onto the given collection of items .
# Notify # Raise unmet dependency error if necessary
None
void
items
items The items that are depended on.
items The items that are depended on .