Sha256: 44934cff1ccd7c08651647ebff41b2a3a38e8da309a8d61f70dcb4e760cd1581

Contents?: true

Size: 1.4 KB

Versions: 4

Compression:

Stored size: 1.4 KB

Contents

# Bring in rake with rake-compiler's support.
require 'rake'
require 'rake/clean'
require 'rake/extensiontask'

# Bring in bundler and it's gem tasks.
require 'bundler/setup'
require 'bundler/gem_tasks'

# Bring in RSpec's built-in rake task.
require 'rspec/core/rake_task'

# Bring in RDoc's built-in rake task.
require 'rdoc/task'

# By default, run rspec tests.
task :default => [ :test ]

# Let Rake know what is safe to remove.
CLEAN.include [ 'pkg/*', 'doc/*' ]

desc "Compile the native extension."
Rake::ExtensionTask.new do |extension|
  # Some basic configuration.
  extension.name     = 'rbpod'
  extension.ext_dir  = 'ext/rbpod'
  extension.lib_dir  = 'lib/rbpod'

  # Monitor sources for change tracking.
  extension.source_pattern = '*.[ch]'
end

desc "Run all available RSpec tests."
RSpec::Core::RakeTask.new(:test) do |task|
  task.pattern = 'spec/**/*_spec.rb'
  # Execute ruby with warnings enabled.
  task.ruby_opts = '-w'
end
# Make compilation a prerequisite of testing.
Rake::Task[:test].prerequisites << :compile

desc "Build all RDoc documentation."
RDoc::Task.new(:rdoc) do |task|
 task.rdoc_dir = 'doc/rdoc'
 task.markup   = 'markdown'
 task.main     = 'README.md'
 task.title    = 'RbPod: Lightweight Ruby bindings to libgpod'
 task.rdoc_files.include('README.md', 'lib/**/*.rb', 'ext/**/*.[ch]')
end

desc "Open a console with rbpod preloaded."
task :console => [ :compile ] do
  sh 'bundle console'
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
rbpod-0.0.8 Rakefile
rbpod-0.0.7 Rakefile
rbpod-0.0.6 Rakefile
rbpod-0.0.5 Rakefile