-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathRakefile
More file actions
41 lines (33 loc) · 727 Bytes
/
Copy pathRakefile
File metadata and controls
41 lines (33 loc) · 727 Bytes
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
task default: [:spec, :standard]
# Load git-reclone files straight into ruby path
lib = File.expand_path("../lib/", __FILE__)
$:.unshift lib unless $:.include?(lib)
# gem name, version
g = "git-reclone"
require "git-reclone"
v = GitReclone::VERSION
# Testing
#
require "rspec/core/rake_task"
RSpec::Core::RakeTask.new(:spec) do |rake|
rake.rspec_opts = "--color --format documentation"
rake.verbose = true
end
# Linting
#
require "standard/rake"
task :dev do
sh 'filewatcher "**/*.rb" "clear && rake"'
end
# Gem management
#
task :build do
sh "gem build #{g}.gemspec"
sh "gem install ./#{g}-#{v}.gem"
end
task :clean do
sh "rm -fv *.gem"
end
task push: [:clean, :build] do
sh "gem push #{g}-#{v}.gem"
end