lib/picky-client/tasks/javascripts.rb in picky-client-3.0.1 vs lib/picky-client/tasks/javascripts.rb in picky-client-3.1.0

- old
+ new

@@ -12,10 +12,11 @@ # Picky::Tasks::Javascripts.new # Copies the files into the javascripts folder (by default). # Picky::Tasks::Javascripts.new('public/javascripts') # Copies the files into the public/javascripts folder. # class Javascripts - define_method :initialize do |target = 'javascripts'| + define_method :initialize do |*args| + target = args.shift || 'javascripts' desc "Copy the latest client javascripts to '#{target}' (Give target dir to Picky::Tasks::Javascripts.new to change)." task :javascripts do target_dir = ::File.expand_path target, Dir.pwd source_dir = ::File.expand_path '../../../../javascripts/*.min.js', __FILE__ \ No newline at end of file