Sha256: 25af475b65f86e2811ce0b2964827741728a1329a9d2a7f728b5f8c8bd777032

Contents?: true

Size: 779 Bytes

Versions: 2

Compression:

Stored size: 779 Bytes

Contents

require 'rake'
require 'rake/testtask'
require 'rake/clean'
require 'rbconfig'

CLEAN.include("**/*.rbc", "**/*.rbx", "**/*.gem")

desc "Run the example program"
task :example do
  if File::ALT_SEPARATOR
    sh 'ruby -Ilib/windows examples/uname_test.rb'
  else
    sh 'ruby -Ilib/unix examples/uname_test.rb'
  end
end

namespace :gem do
  desc "Create the sys-uname gem"
  task :create => [:clean] do
    require 'rubygems/package'
    spec = eval(IO.read('sys-uname.gemspec'))
    Gem::Package.build(spec)
  end

  desc "Install the sys-uname gem"
  task :install => [:create] do
    file = Dir["*.gem"].first
    sh "gem install #{file}"
  end
end

desc "Run the test suite"
Rake::TestTask.new("test") do |t|
  t.warning = true
  t.verbose = true
end

task :default => :test

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
sys-uname-1.0.1 Rakefile
sys-uname-1.0.0 Rakefile