Permalink
Browse files

Cleanup a little by using ActiveSupport convenience methods.

  • Loading branch information...
1 parent 1dc80ad commit 854cc1af0d212d8b6c0893195dd5c0b63ee5ea99 @alloy alloy committed Aug 10, 2012
Showing with 5 additions and 4 deletions.
  1. +5 −4 lib/cocoapods/installer/user_project_integrator.rb
@@ -1,6 +1,9 @@
require 'xcodeproj/workspace'
require 'xcodeproj/project'
+require 'active_support/core_ext/string/inflections'
+require 'active_support/core_ext/array/conversions'
+
module Pod
class Installer
@@ -69,10 +72,8 @@ def integrate!
return if targets.empty?
unless Config.instance.silent?
- # TODO let's just use ActiveSupport.
- plural = targets.size > 1
- puts "-> Integrating `#{@target_definition.lib_name}' into target#{'s' if plural} " \
- "`#{targets.map(&:name).join(', ')}' of Xcode project `#{user_project_path.basename}'.".green
+ puts "-> Integrating `#{@target_definition.lib_name}' into #{'target'.pluralize(targets.size)} " \
+ "`#{targets.map(&:name).to_sentence}' of Xcode project `#{user_project_path.basename}'.".green
end
add_xcconfig_base_configuration

0 comments on commit 854cc1a

Please sign in to comment.