forked from shugo/textbringer
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathRakefile
More file actions
28 lines (26 loc) · 668 Bytes
/
Copy pathRakefile
File metadata and controls
28 lines (26 loc) · 668 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
require "bundler/gem_tasks"
require "rake/testtask"
task :default => :test
Rake::TestTask.new do |t|
t.libs << "test"
t.test_files = FileList["test/**/test_*.rb"]
t.verbose = true
t.warning = true
end
task :bump do
require_relative "lib/textbringer/version"
version = Textbringer::VERSION.to_i + 1
tag_name = "v#{version}"
puts "Bump version to #{version}"
sh "git checkout main"
sh "git pull"
File.write("lib/textbringer/version.rb", <<~EOF)
module Textbringer
VERSION = "#{version}"
end
EOF
sh "git commit -a -m 'Bump version to #{version}'"
sh "git push"
sh "git tag #{tag_name}"
sh "git push origin #{tag_name}"
end