Sha256: c87b6bdbc2103e7f6075c95d25153dbea900276ca2edd2df3e83175e9a72cdba

Contents?: true

Size: 1.06 KB

Versions: 19

Compression:

Stored size: 1.06 KB

Contents

require 'date'

def version
  contents = File.read File.expand_path('../lib/chronic.rb', __FILE__)
  contents[/VERSION = "([^"]+)"/, 1]
end

task :test do
  $:.unshift './test'
  Dir.glob('test/test_*.rb').each { |t| require File.basename(t) }
end

desc "Generate RCov test coverage and open in your browser"
task :coverage do
  require 'rcov'
  sh "rm -fr coverage"
  sh "rcov test/test_*.rb"
  sh "open coverage/index.html"
end

desc "Open an irb session preloaded with this library"
task :console do
  sh "irb -Ilib -rchronic"
end

desc "Release Chronic version #{version}"
task :release => :build do
  unless `git branch` =~ /^\* master$/
    puts "You must be on the master branch to release!"
    exit!
  end
  sh "git commit --allow-empty -a -m 'Release #{version}'"
  sh "git tag v#{version}"
  sh "git push origin master"
  sh "git push origin v#{version}"
  sh "gem push pkg/chronic-#{version}.gem"
end

desc "Build a gem from the gemspec"
task :build do
  sh "mkdir -p pkg"
  sh "gem build chronic.gemspec"
  sh "mv chronic-#{version}.gem pkg"
end

task :default => :test

Version data entries

19 entries across 19 versions & 3 rubygems

Version Path
chronic-mmlac-0.6.4.2 Rakefile
chronic-0.9.1 Rakefile
chronic-0.9.0 Rakefile
Hokkaido-0.1.5 chronic/Rakefile
Hokkaido-0.1.4 chronic/Rakefile
Hokkaido-0.1.3 chronic/Rakefile
Hokkaido-0.1.2 chronic/Rakefile
Hokkaido-0.1.1 chronic/Rakefile
Hokkaido-0.1.0 chronic/Rakefile
Hokkaido-0.0.9 chronic/Rakefile
Hokkaido-0.0.6 chronic/Rakefile
Hokkaido-0.0.5 chronic/Rakefile
Hokkaido-0.0.4 chronic/Rakefile
chronic-0.8.0 Rakefile
chronic-0.7.0 Rakefile
chronic-0.6.7 Rakefile
chronic-0.6.6 Rakefile
chronic-0.6.5 Rakefile
chronic-0.6.4 Rakefile