From cb45a80928f225e608e931f4f162cb3a3cda94e2 Mon Sep 17 00:00:00 2001 From: Charlie Sharpsteen Date: Mon, 2 Jun 2014 21:55:27 -0700 Subject: [PATCH] Parse module lib directories along with manifests The `puppet yardoc` face now parses any files matching `lib/**/*.rb` when operating on modules. --- lib/puppet/face/yardoc.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/puppet/face/yardoc.rb b/lib/puppet/face/yardoc.rb index dacce93..e6f1098 100644 --- a/lib/puppet/face/yardoc.rb +++ b/lib/puppet/face/yardoc.rb @@ -30,7 +30,7 @@ Puppet::Face.define(:yardoc, '0.0.1') do # # TODO: It would be awesome if we could somehow override/append to the # default file list that YARD uses. Consider an upstream PR for this. - MODULE_SOURCEFILES = ['manifests/**/*.pp'] + MODULE_SOURCEFILES = ['manifests/**/*.pp', 'lib/**/*.rb'] action(:yardoc) do default @@ -50,7 +50,7 @@ Puppet::Face.define(:yardoc, '0.0.1') do opts = args.pop # For now, assume the remaining positional args are a list of manifest - # files to parse. + # and ruby files to parse. yard_args = (args.empty? ? MODULE_SOURCEFILES : args) merge_puppet_args!(yard_args)