Skip to content

Commit

Permalink
Merge pull request #11 from ehaselwanter/allow-for-quoted-includes
Browse files Browse the repository at this point in the history
puppet does quoted includes, normalize on includes without quotes to be able
  • Loading branch information
arlimus committed Dec 12, 2014
2 parents b4949f2 + 1a81fac commit 1d8ebf6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions default/serverspec/type/file_with_includes.rb
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@ def content
file = get_file_content(@file_name)

file.scan(@include_matcher).each do |include_match|

Dir.glob(include_match[/\/.+?\.[^.]*$|$/]).each do |file_name|
# We split at whitespace and strip quotes
Dir.glob(include_match.split(/\s/).last.gsub(/['"]/, '')).each do |file_name|
included_file = get_file_content(file_name)
file << included_file
end
Expand Down

0 comments on commit 1d8ebf6

Please sign in to comment.