Skip to content
This repository has been archived by the owner on Jan 15, 2024. It is now read-only.

Commit

Permalink
Lower threshold for chef_repo and add warning
Browse files Browse the repository at this point in the history
  • Loading branch information
sethvargo committed May 15, 2013
1 parent 3b21369 commit c523f10
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion lib/strainer/sandbox.rb
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,9 @@ def initialize(cookbook_names, options = {})
Strainer.ui.warn "Supply specific cookbooks to a cookbook_repo is not supported. Use `strainer test` with no arguments instead."
end
@cookbooks = [load_self]
else
Strainer.ui.warn "I could not detect if you were a chef-repo or a cookbook!"
@cookbooks = []
end

reset_sandbox
Expand Down Expand Up @@ -214,7 +217,7 @@ def cookbook_repo?
def chef_repo?
@_chef_repo ||= begin
chef_folders = %w(.chef certificates config cookbooks data_bags environments roles)
(root_folders & chef_folders).size > 4
(root_folders & chef_folders).size > 2
end
end

Expand Down

0 comments on commit c523f10

Please sign in to comment.