stffn / declarative_authorization
- Source
- Commits
- Network (41)
- Issues (7)
- Downloads (4)
- Wiki (2)
- Graphs
-
Tree:
3ca12e3
declarative_authorization / Rakefile
| 0ba24788 » | stffn | 2008-08-14 | 1 | require 'rake' | |
| 2 | require 'rake/testtask' | ||||
| 3 | require 'rake/rdoctask' | ||||
| 4 | |||||
| 5 | desc 'Default: run unit tests.' | ||||
| 6 | task :default => :test | ||||
| 7 | |||||
| 8 | desc 'Test the authorization plugin.' | ||||
| 9 | Rake::TestTask.new(:test) do |t| | ||||
| 10 | t.libs << 'lib' | ||||
| 11 | t.pattern = 'test/**/*_test.rb' | ||||
| 12 | t.verbose = true | ||||
| 13 | end | ||||
| 14 | |||||
| 15 | desc 'Generate documentation for the authorization plugin.' | ||||
| 16 | Rake::RDocTask.new(:rdoc) do |rdoc| | ||||
| 17 | rdoc.rdoc_dir = 'rdoc' | ||||
| 18 | rdoc.title = 'Authorization' | ||||
| 19 | rdoc.options << '--line-numbers' << '--inline-source' | ||||
| 20 | rdoc.options << '--charset' << 'utf-8' | ||||
| 5f3b32d3 » | stffn | 2008-09-18 | 21 | rdoc.rdoc_files.include('README.rdoc') | |
| 035c94fa » | stffn | 2009-02-02 | 22 | rdoc.rdoc_files.include('CHANGELOG') | |
| 0ba24788 » | stffn | 2008-08-14 | 23 | rdoc.rdoc_files.include('lib/**/*.rb') | |
| 24 | end | ||||
| 7498bbfb » | stffn | 2008-10-28 | 25 | ||
| 26 | # load up garlic if it's here | ||||
| 27 | if File.directory?(File.join(File.dirname(__FILE__), 'garlic')) | ||||
| 28 | require File.join(File.dirname(__FILE__), 'garlic/lib/garlic_tasks') | ||||
| 29 | require File.join(File.dirname(__FILE__), 'garlic') | ||||
| 30 | end | ||||
| 31 | |||||
| 32 | desc "clone the garlic repo (for running ci tasks)" | ||||
| 33 | task :get_garlic do | ||||
| 34 | sh "git clone git://github.com/ianwhite/garlic.git garlic" | ||||
| 35 | end | ||||
| 1b29e5c4 » | stffn | 2009-02-25 | 36 | ||
| 37 | desc "Expand filelist in src gemspec" | ||||
| 38 | task :build_gemspec do | ||||
| 39 | gemspec_data = File.read("declarative_authorization.gemspec.src") | ||||
| 40 | gemspec_data.gsub!(/\.files = (.*)/) {|m| ".files = #{eval($1).inspect}"} | ||||
| 41 | File.open("declarative_authorization.gemspec", "w") {|f| f.write(gemspec_data)} | ||||
| 42 | end | ||||
| 43 | |||||
