From c22c4b864cc9bc077f35599e3c165f3ad09ada96 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torkel=20=C3=96degaard?= Date: Mon, 17 Mar 2014 17:24:38 +0100 Subject: [PATCH] fixed string replace issue that caused problems, this removes build cache busting in requirejs, will need to fix that later --- src/app/app.js | 2 +- tasks/build_task.js | 8 ++------ 2 files changed, 3 insertions(+), 7 deletions(-) diff --git a/src/app/app.js b/src/app/app.js index 88b8f2abd26..c3c46dbdde0 100644 --- a/src/app/app.js +++ b/src/app/app.js @@ -26,7 +26,7 @@ function (angular, $, _, appLevelRequire) { // features if we define them after boot time register_fns = {}; - // // This stores the Kibana revision number, @REV@ is replaced by grunt. + // This stores the grafana version number app.constant('grafanaVersion',"@grafanaVersion@"); // Use this for cache busting partials diff --git a/tasks/build_task.js b/tasks/build_task.js index 964e09f2711..0498013a511 100644 --- a/tasks/build_task.js +++ b/tasks/build_task.js @@ -26,15 +26,11 @@ module.exports = function(grunt) { options: { replacements: [ { - pattern: /(?:^|\/\/)(.*)@REV@/, - replacement: '$1'+desc.object - }, - { - pattern: /@REV@/, + pattern: /@REV@/g, replacement: desc.object }, { - pattern: /@grafanaVersion@/, + pattern: /@grafanaVersion@/g, replacement: 'v<%= pkg.version %>' } ]