modify casperjs.gemspec for reading VERSION from package.json file.
Showing
1 changed file
with
3 additions
and
1 deletions
1 | # by hannyu | ||
1 | 2 | ||
3 | CASPERJS_VERSION = File.read("package.json")[/version.*:.*"(.*?)"/,1].gsub(/[\-_\+]/,".") | ||
2 | 4 | ||
3 | Gem::Specification.new do |s| | 5 | Gem::Specification.new do |s| |
4 | s.name = "casperjs" | 6 | s.name = "casperjs" |
5 | s.version = "1.0.0.RC1" | 7 | s.version = CASPERJS_VERSION |
6 | s.homepage = "http://casperjs.org/" | 8 | s.homepage = "http://casperjs.org/" |
7 | s.authors = ["Nicolas Perriault", ] | 9 | s.authors = ["Nicolas Perriault", ] |
8 | s.email = ["nperriault@gmail.com",] | 10 | s.email = ["nperriault@gmail.com",] | ... | ... |
-
Please register or sign in to post a comment