You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

17 lines
500 B

  1. #!/usr/bin/env ruby
  2. gem_dir = File.expand_path("..",File.dirname(__FILE__))
  3. $LOAD_PATH.unshift gem_dir # Look in gem directory for resources first.
  4. exec_type = ARGV[0]
  5. if exec_type == 'rake' then
  6. require 'rake'
  7. require 'pp'
  8. pwd=Dir.pwd
  9. Dir.chdir(gem_dir) # We'll load rakefile from the gem's dir.
  10. Rake.application.init
  11. Rake.application.load_rakefile
  12. Dir.chdir(pwd) # Revert to original pwd for any path args passed to task.
  13. Rake.application.invoke_task(ARGV[1])
  14. end