Sha256: 4ea2bc0ba3c009de238cdfb77de9393e733f0eaa8d6f8008b99779729f67e3d6

Contents?: true

Size: 773 Bytes

Versions: 1

Compression:

Stored size: 773 Bytes

Contents

# -*- mode: ruby; coding: utf-8 -*-


task :gem => 'gem:build'

%w[clean install uninstall upload].each do |t|
  task t.intern => "gem:#{t}"
end

empty_task :lib, :ext, :rdoc


namespace :gem do


  mod  = MODULE
  name = env :NAME, MODULE.name.downcase
  gem  = env :GEM,  'gem'

  gemspec = "#{name}.gemspec"
  gemname = env :GEMNAME, name
  gemfile = "#{gemname}-#{mod.version}.gem"


  task :build => gemfile

  task :clean do
    sh %( rm -f #{gemfile} )
  end

  task :install => gemfile do
    sh %( #{gem} install #{gemfile} )
  end

  task :uninstall do
    sh %( #{gem} uninstall #{name} )
  end

  task :upload => gemfile do
    sh %( #{gem} push #{gemfile} )
  end

  file gemfile => [:lib, :ext, :rdoc] do
    sh %( #{gem} build #{gemspec} )
  end


end# :gem

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
xot-0.1.4 task/gem.rake