Skip to content

Commit

Permalink
Removed more deprecation warnings about packages dir
Browse files Browse the repository at this point in the history
  • Loading branch information
wagenet committed Sep 21, 2011
1 parent 0da7f70 commit 81cf78a
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions lib/bpm/project.rb
Expand Up @@ -91,14 +91,9 @@ def vendored_projects

def vendored_packages
@vendored_packages ||= begin
# Packages path is deprecated
packages_path = File.join(@root_path, 'packages')
search_paths = [vendor_root, packages_path]
search_paths = [vendor_root, File.join(@root_path, 'packages')]
paths = search_paths.map{|p| Dir.glob(File.join(p, '*')) }.flatten
pkgs = paths.select{|p| Package.is_package_root?(p) }.map{|p| Package.new(p) }
if pkgs.any?{|p| p.root_path =~ /^#{Regexp.escape(packages_path)}\// }
BPM.deprecation_warning "Use the vendor directory instead of the packages directory for #{root_path}"
end
pkgs += vendored_projects.map{|p| p.vendored_packages }.flatten
pkgs.select do |p|
begin
Expand Down

0 comments on commit 81cf78a

Please sign in to comment.