-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrakefile
48 lines (42 loc) · 1.19 KB
/
rakefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
# -*- coding: utf-8 -*-
require 'rubygems'
require 'rake'
require 'rspec'
require 'rspec/core/rake_task'
require 'yard'
require 'rcov'
task :default => :specs
desc 'Run all specs'
RSpec::Core::RakeTask.new(:specs) do |t|
t.rspec_opts = ["--colour", "--format", "documentation"]
end
desc 'Coverage for all specs'
RSpec::Core::RakeTask.new(:rcov) do |t|
t.rcov = true
t.rcov_opts = %q[--exclude "spec"]
t.verbose = true
end
begin
require 'jeweler'
Jeweler::Tasks.new do |gemspec|
gemspec.name = "queule"
gemspec.authors = ["Daniel Hernández"]
gemspec.email = "daniel@degu.cl"
gemspec.homepage = "http://github.com/danielhz/queule"
gemspec.summary = "Minimalist library to build web appplications on top of rack"
gemspec.rubyforge_project = "queule"
gemspec.description = "Queule..."
end
rescue LoadError
end
YARD::Rake::YardocTask.new do |t|
t.options += ['--title', "Queule Documentation"]
end
desc 'Build and upload the last gem file'
task :gem_push => :build do
gem = Dir['pkg/*.gem'].map { |f|
[f, File.basename(f).gsub(/.gem$/, '').gsub(/^queule-/, '').split('.').map{ |x| x.to_i}]
}.sort.last
puts "gem push #{gem[0]}"
system "gem push #{gem[0]}"
end