fix git versioning

This commit is contained in:
Devin Howard 2016-09-25 18:49:16 +08:00
parent 1810faacbe
commit 5819447828
4 changed files with 7 additions and 1 deletions

View file

@ -18,3 +18,5 @@ Metamaps.Erb['sounds/MM_sounds.mp3'] = '<%= asset_path 'sounds/MM_sounds.mp3' %>
Metamaps.Erb['sounds/MM_sounds.ogg'] = '<%= asset_path 'sounds/MM_sounds.ogg' %>' Metamaps.Erb['sounds/MM_sounds.ogg'] = '<%= asset_path 'sounds/MM_sounds.ogg' %>'
Metamaps.Metacodes = <%= Metacode.all.to_json.gsub(%r[(icon.*?)(\"},)], '\1?purple=stupid\2').html_safe %> Metamaps.Metacodes = <%= Metacode.all.to_json.gsub(%r[(icon.*?)(\"},)], '\1?purple=stupid\2').html_safe %>
Metamaps.VERSION = '<%= METAMAPS_VERSION %>' Metamaps.VERSION = '<%= METAMAPS_VERSION %>'
Metamaps.BUILD = '<%= METAMAPS_BUILD %>'
Metamaps.LAST_UPDATED = '<%= METAMAPS_LAST_UPDATED %>'

View file

@ -13,12 +13,14 @@
<div id="leftAboutParms"> <div id="leftAboutParms">
<p>STATUS: </p> <p>STATUS: </p>
<p>VERSION:</p> <p>VERSION:</p>
<p>BUILD:</p>
<p>LAST UPDATE:</p> <p>LAST UPDATE:</p>
</div> </div>
<div id="rightAboutParms"> <div id="rightAboutParms">
<p>PRIVATE BETA</p> <p>PRIVATE BETA</p>
<p><%= METAMAPS_VERSION %></p> <p><%= METAMAPS_VERSION %></p>
<p><%= METAMAPS_BUILD %></p>
<p><%= METAMAPS_LAST_UPDATED %></p> <p><%= METAMAPS_LAST_UPDATED %></p>
</div> </div>
<div class="clearfloat"> <div class="clearfloat">

View file

@ -1,3 +1,4 @@
# frozen_string_literal: true # frozen_string_literal: true
METAMAPS_VERSION = '2 build `git log -1 --pretty=%H`' METAMAPS_VERSION = '2.9'
METAMAPS_BUILD = `git log -1 --pretty=%H`.chomp.freeze
METAMAPS_LAST_UPDATED = `git log -1 --pretty='%ad'`.split(' ').values_at(1, 2, 4).join(' ').freeze METAMAPS_LAST_UPDATED = `git log -1 --pretty='%ad'`.split(' ').values_at(1, 2, 4).join(' ').freeze

View file

@ -31,6 +31,7 @@ import Util from './Util'
import Views from './Views' import Views from './Views'
import Visualize from './Visualize' import Visualize from './Visualize'
Metamaps = window.Metamaps || {}
Metamaps.Account = Account Metamaps.Account = Account
Metamaps.Active = Active Metamaps.Active = Active
Metamaps.Admin = Admin Metamaps.Admin = Admin