Permalink
Browse files

Merge branch 'master' of github.com:technicalpickles/jeweler

  • Loading branch information...
2 parents 4aa0a2b + 85ff945 commit ec91e05d06f2835ee30568fa42b5fa7d451444b6 Fred Mitchell committed Apr 14, 2016
Showing with 12 additions and 4 deletions.
  1. +3 −0 README.markdown
  2. +9 −4 lib/jeweler/version_helper.rb
View
3 README.markdown
@@ -2,6 +2,8 @@
# Jeweler: Craft the perfect RubyGem
+[![Join the chat at https://gitter.im/technicalpickles/jeweler](https://badges.gitter.im/technicalpickles/jeweler.svg)](https://gitter.im/technicalpickles/jeweler?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
+
Jeweler provides the noble ruby developer with two primary features:
* a library for managing and releasing RubyGem projects
@@ -15,6 +17,7 @@ are dealt with.
[![Build Status](https://travis-ci.org/technicalpickles/jeweler.png)](https://travis-ci.org/technicalpickles/jeweler)
[![Coverage Status](https://coveralls.io/repos/technicalpickles/jeweler/badge.png)](https://coveralls.io/r/technicalpickles/jeweler)
[![Dependency Status](https://www.versioneye.com/ruby/jeweler/2.0.0/badge.png)](https://www.versioneye.com/ruby/jeweler/2.0.0)
+[![Code Climate](https://codeclimate.com/github/technicalpickles/jeweler/badges/gpa.svg)](https://codeclimate.com/github/technicalpickles/jeweler)
## Hello, world
View
13 lib/jeweler/version_helper.rb
@@ -125,15 +125,20 @@ def to_s
end
def yaml_path
- denormalized_path = File.join(@base_dir, 'VERSION.yml')
- absolute_path = File.expand_path(denormalized_path)
- absolute_path.gsub(Dir.getwd + File::SEPARATOR, '')
+ path_to_version_file('VERSION.yml')
end
def plaintext_path
- denormalized_path = File.join(@base_dir, 'VERSION')
+ path_to_version_file('VERSION')
+ end
+
+ private
+
+ def path_to_version_file(filename)
+ denormalized_path = File.join(@base_dir, filename)
absolute_path = File.expand_path(denormalized_path)
absolute_path.gsub(Dir.getwd + File::SEPARATOR, '')
end
+
end
end

0 comments on commit ec91e05

Please sign in to comment.