lib/nanoc3/base/compilation/compiler.rb
# Finds the first matching routing rule for the given item representation.
#
# @api private
#
# @param [Nanoc3::ItemRep] rep The item rep for which to fetch the rule
#
# @return [Nanoc3::Rule, nil] The routing rule for the given item rep, or
#   nil if no rules have been found
Finds the first matching routing rule for the given item representation.
Finds the first matching routing rule for the given item representation .
def routing_rule_for(rep)
      @item_routing_rules.find do |rule|
        rule.applicable_to?(rep.item) && rule.rep_name == rep.name
      end
    end
def routing_rule_for ( rep ) @item_routing_rules . find do | rule | rule . applicable_to? ( rep . item ) && rule . rep_name == rep . name end end
Finds the first matching routing rule for the given item representation.
Finds the first matching routing rule for the given item representation .
The routing rule for the given item rep, or nil if no rules have been found
The routing rule for the given item rep or nil if no rules have been found
Nanoc3::Rule, nil
rep
rep The item rep for which to fetch the rule
rep The item rep for which to fetch the rule
api
None