Sha256: 1cbcc412a571f824e9c9e880791affb1da84ba9fdb7d23ca97d7bcad485c3b36
Contents?: true
Size: 656 Bytes
Versions: 1
Compression:
Stored size: 656 Bytes
Contents
module Oxidized VERSION = '0.26.3'.freeze VERSION_FULL = '0.26.3'.freeze def self.version_set version_full = %x(git describe --tags).chop rescue "" version = %x(git describe --tags --abbrev=0).chop rescue "" return false unless [version, version_full].none?(&:empty?) Oxidized.send(:remove_const, :VERSION) Oxidized.send(:remove_const, :VERSION_FULL) const_set(:VERSION, version) const_set(:VERSION_FULL, version_full) file = File.readlines(__FILE__) file[1] = " VERSION = '%s'.freeze\n" % VERSION file[2] = " VERSION_FULL = '%s'.freeze\n" % VERSION_FULL File.write(__FILE__, file.join) end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
oxidized-0.26.3 | lib/oxidized/version.rb |