Skip to content
This repository was archived by the owner on Sep 6, 2021. It is now read-only.
Closed
3 changes: 2 additions & 1 deletion src/brackets.config.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
"extension_listing_url" : "",
"extension_registry" : "https://s3.amazonaws.com/extend.brackets/registry.json",
"extension_url" : "https://s3.amazonaws.com/extend.brackets/{0}/{0}-{1}.zip",
"linting.enabled_by_default" : true
"linting.enabled_by_default" : true,
"build_timestamp" : ""
}
}
7 changes: 4 additions & 3 deletions src/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
"extension_listing_url": "",
"extension_registry": "https://s3.amazonaws.com/extend.brackets/registry.json",
"extension_url": "https://s3.amazonaws.com/extend.brackets/{0}/{0}-{1}.zip",
"linting.enabled_by_default": true
"linting.enabled_by_default": true,
"build_timestamp": ""
},
"name": "Brackets",
"version": "0.41.0-0",
Expand Down Expand Up @@ -56,7 +57,7 @@
"grunt-usemin": "0.1.11",
"load-grunt-tasks": "0.2.0",
"q": "0.9.2",
"jshint": "2.1.4"
"jshint": "2.1.4",
},
"scripts": {
"postinstall": "grunt install",
Expand All @@ -68,4 +69,4 @@
"url": "https://github.com/adobe/brackets/blob/master/LICENSE"
}
]
}
}
1 change: 1 addition & 0 deletions src/help/HelpCommandHandlers.js
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ define(function (require, exports, module) {
var templateVars = {
ABOUT_ICON : brackets.config.about_icon,
APP_NAME_ABOUT_BOX : brackets.config.app_name_about,
BUILD_TIMESTAMP : brackets.config.build_timestamp,
BUILD_INFO : buildInfo || "",
Strings : Strings
};
Expand Down
7 changes: 6 additions & 1 deletion src/htmlContent/about-dialog.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,12 @@ <h1 class="dialog-title">{{Strings.ABOUT}}</h1>
<div class="about-text">
<h2>{{APP_NAME_ABOUT_BOX}}</h2>
<div class="about-info">
<p class="dialog-message">{{Strings.ABOUT_TEXT_LINE1}} <span id="about-build-number">{{BUILD_INFO}}</span></p>
<p class="dialog-message">{{Strings.ABOUT_TEXT_LINE1}} <span id="about-build-number">{{BUILD_INFO}}</span>
{{#BUILD_TIMESTAMP}}
<br><span class="dialog-message">{{Strings.ABOUT_TEXT_BUILD_TIMESTAMP}}{{BUILD_TIMESTAMP}}</span>
{{/BUILD_TIMESTAMP}}
</p>

<p class="dialog-message"><!-- $NON-NLS$ -->Copyright 2012 - 2014 Adobe Systems Incorporated and its licensors. All rights reserved.</p>
<p class="dialog-message">{{{Strings.ABOUT_TEXT_WEB_PLATFORM_DOCS}}}</p>
<p class="dialog-message">{{{Strings.ABOUT_TEXT_LINE3}}}</p>
Expand Down
1 change: 1 addition & 0 deletions src/nls/root/strings.js
Original file line number Diff line number Diff line change
Expand Up @@ -385,6 +385,7 @@ define({
"ABOUT" : "About",
"CLOSE" : "Close",
"ABOUT_TEXT_LINE1" : "sprint {VERSION_MINOR} {BUILD_TYPE} {VERSION}",
"ABOUT_TEXT_BUILD_TIMESTAMP" : "build timestamp: ",
"ABOUT_TEXT_LINE3" : "Notices, terms and conditions pertaining to third party software are located at <a href='{ADOBE_THIRD_PARTY}'>{ADOBE_THIRD_PARTY}</a> and incorporated by reference herein.",
"ABOUT_TEXT_LINE4" : "Documentation and source at <a href='https://github.com/adobe/brackets/'>https://github.com/adobe/brackets/</a>",
"ABOUT_TEXT_LINE5" : "Made with \u2764 and JavaScript by:",
Expand Down
14 changes: 7 additions & 7 deletions src/strings.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,13 +45,13 @@ define(function (require, exports, module) {
var additionalGlobals = $.extend({}, urls),
parsedVersion = /([0-9]+)\.([0-9]+)\.([0-9]+)/.exec(brackets.metadata.version);

additionalGlobals.APP_NAME = brackets.metadata.name || strings.APP_NAME;
additionalGlobals.APP_TITLE = brackets.config.app_title || strings.APP_NAME;
additionalGlobals.TWITTER_NAME = brackets.config.twitter_name;
additionalGlobals.VERSION = brackets.metadata.version;
additionalGlobals.VERSION_MAJOR = parsedVersion[1];
additionalGlobals.VERSION_MINOR = parsedVersion[2];
additionalGlobals.VERSION_PATCH = parsedVersion[3];
additionalGlobals.APP_NAME = brackets.metadata.name || strings.APP_NAME;
additionalGlobals.APP_TITLE = brackets.config.app_title || strings.APP_NAME;
additionalGlobals.TWITTER_NAME = brackets.config.twitter_name;
additionalGlobals.VERSION = brackets.metadata.version;
additionalGlobals.VERSION_MAJOR = parsedVersion[1];
additionalGlobals.VERSION_MINOR = parsedVersion[2];
additionalGlobals.VERSION_PATCH = parsedVersion[3];

var isDevBuild = !StringUtils.endsWith(decodeURI(window.location.pathname), "/www/index.html");
additionalGlobals.BUILD_TYPE = (isDevBuild ? strings.DEVELOPMENT_BUILD : strings.EXPERIMENTAL_BUILD);
Expand Down
3 changes: 2 additions & 1 deletion tasks/write-config.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,15 @@ module.exports = function (grunt) {
});

// task: build-config
grunt.registerTask("build-config", "Update config.json with the branch and SHA being built", function () {
grunt.registerTask("build-config", "Update config.json with build timestamp, branch and SHA being built", function () {
var done = this.async(),
distConfig = grunt.file.readJSON("src/config.json");

build.getGitInfo(process.cwd()).then(function (gitInfo) {
distConfig.version = distConfig.version.substr(0, distConfig.version.lastIndexOf("-") + 1) + gitInfo.commits;
distConfig.repository.SHA = gitInfo.sha;
distConfig.repository.branch = gitInfo.branch;
distConfig.config.build_timestamp = new Date().toString().split('(')[0].trim();

common.writeJSON(grunt, "dist/config.json", distConfig);

Expand Down