diff --git a/config/version b/config/version index 965065db..b0bb8785 100644 --- a/config/version +++ b/config/version @@ -1 +1 @@ -0.9.3 +0.9.5 diff --git a/make_mobile b/make_mobile index fbf33596..e9cc17f4 100755 --- a/make_mobile +++ b/make_mobile @@ -9,7 +9,7 @@ APP_ROOT="#{HOME}/Documents/workspace/mozo" APP_ASSET_ROOT="#{APP_ROOT}/www/assets" app_config_path = File.join(APP_ROOT, 'config.xml') app_config = File.read(app_config_path) -app_index_html_path = File.join(APP_ASSET_ROOT, 'index.html') +app_index_html_path = File.join(APP_ROOT, 'www/index.html') app_index_html = File.read(app_index_html_path) current_version = app_config.match(/version="([\.\d]+)"/)[1].to_version new_version = File.read("config/version").strip.to_version @@ -61,4 +61,4 @@ end # Set app versions File.open(app_config_path, 'w+'){|f| f.puts app_config.sub(%[version="#{current_version}"], %[version="#{new_version}"])} -File.open(app_index_html_path, 'w+'){ |f| f.puts app_index_html.sub('##APP_VERSION##', new_version.to_s) } +File.open(app_index_html_path, 'w+'){ |f| f.puts app_index_html.sub(/$app_version\s*=\s*'([\.\d]+)'/, "$app_version = '#{new_version.to_s}'") }