pingable 0.0.2 → 0.0.3

Sign up to get free protection for your applications and to get access to all the features.
data/Rakefile CHANGED
@@ -1 +1,21 @@
1
1
  require "bundler/gem_tasks"
2
+
3
+ desc 'Bump version'
4
+ task :bump do
5
+ if `git status -uno -s --porcelain | wc -l`.to_i > 0
6
+ abort "You have uncommitted changed."
7
+ end
8
+ text = File.read('lib/pingable/version.rb')
9
+ if text =~ /VERSION = ['"](.*)['"]/
10
+ old_version = $1
11
+ version_parts = old_version.split('.')
12
+ version_parts[-1] = version_parts[-1].to_i + 1
13
+ new_version = version_parts.join('.')
14
+ text.gsub!(/VERSION = ['"](.*)['"]/, "VERSION = '#{new_version}'")
15
+ File.open('lib/pingable/version.rb', 'w') { |f| f << text }
16
+ (system("git add lib/pingable/version.rb") and
17
+ system("git commit -m 'Bump to #{new_version}.'")) or abort "Failed to commit."
18
+ else
19
+ abort "Could not find version number"
20
+ end
21
+ end
@@ -18,7 +18,7 @@ module Pingable
18
18
 
19
19
  private
20
20
 
21
- HEADERS = {'Cache-Control' => 'private', 'Content-Type': 'text/plain'}
21
+ HEADERS = {'Cache-Control' => 'private', 'Content-Type' => 'text/plain'}
22
22
 
23
23
  end
24
24
 
@@ -1,3 +1,3 @@
1
1
  module Pingable
2
- VERSION = "0.0.2"
2
+ VERSION = '0.0.3'
3
3
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pingable
3
3
  version: !ruby/object:Gem::Version
4
- hash: 27
4
+ hash: 25
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
8
  - 0
9
- - 2
10
- version: 0.0.2
9
+ - 3
10
+ version: 0.0.3
11
11
  platform: ruby
12
12
  authors:
13
13
  - Alexander Staubo