Commit c7352ba0 authored by Alexander.Trofimov's avatar Alexander.Trofimov

Сборку перевел на google-closure-compiler модуль

parent 96440f23
module.exports = function(grunt) {
require('google-closure-compiler').grunt(grunt);
var revision="unknown", defaultConfig, packageFile, toolsConfig, toolsFile;
var path = require('path');
......@@ -7,7 +8,6 @@ module.exports = function(grunt) {
grunt.loadNpmTasks('grunt-contrib-concat');
grunt.loadNpmTasks('grunt-contrib-copy');
grunt.loadNpmTasks('grunt-exec');
grunt.loadNpmTasks('grunt-closure-tools');
grunt.loadNpmTasks('grunt-replace');
grunt.registerTask('get_svn_info', 'Initialize svn information', function () {
......@@ -205,32 +205,27 @@ module.exports = function(grunt) {
packageFile['compile']['defines']['dst'],
map_record_file_path ];
grunt.initConfig({
closureCompiler: {
pkg: grunt.file.readJSON(defaultConfig),
'closure-compiler': {
build: {
files: {
'<%= pkg.compile.sdk.dst %>': packageFile['compile']['sdk']['src']
},
options: {
compilerFile: compilerFile,
javaFlags: ['-Xms2048m']
},
sdk: {
TEMPcompilerOpts: {
compilation_level: compilation_level,
warning_level: 'QUIET',
externs: packageFile['compile']['sdk']['externs'],
define: packageFile['compile']['sdk']['define'],
warning_level: 'QUIET',
variable_renaming_report: packageFile['compile']['sdk']['log'] + '/variable.map',
property_renaming_report: packageFile['compile']['sdk']['log'] + '/property.map'/*,
create_source_map: map_file_path,
source_map_format: "V3"*/
},
src: packageFile['compile']['sdk']['src'],
dest: packageFile['compile']['sdk']['dst']
},
defines: {
TEMPcompilerOpts: {
options: {
compilation_level: 'SIMPLE',
warning_level: 'QUIET'
},
src: packageFile['compile']['defines']['src'],
dest: packageFile['compile']['defines']['dst']
}
}
}
},
create_map_file: {},
......@@ -239,7 +234,6 @@ module.exports = function(grunt) {
packageFile['compile']['defines']['dst'],
map_record_file_path
],
pkg: grunt.file.readJSON(defaultConfig),
replace: {
version: {
options: {
......@@ -257,11 +251,11 @@ module.exports = function(grunt) {
});
});
grunt.registerTask('compile_sdk', ['compile_sdk_init:ADVANCED', 'closureCompiler', 'concat', 'replace', 'clean']);
grunt.registerTask('compile_sdk_fast', ['compile_sdk_init:WHITESPACE_ONLY', 'closureCompiler', 'concat', 'replace', 'clean']);
grunt.registerTask('compile_sdk', ['compile_sdk_init:ADVANCED', 'closure-compiler', 'concat', 'replace', 'clean']);
grunt.registerTask('compile_sdk_fast', ['compile_sdk_init:WHITESPACE_ONLY', 'closure-compiler', 'concat', 'replace', 'clean']);
grunt.registerTask('compile_sdk_native', ['compile_sdk_init:ADVANCED', 'closureCompiler:sdk', 'concat', 'replace', 'clean']);
grunt.registerTask('compile_sdk_native_fast', ['compile_sdk_init:WHITESPACE_ONLY', 'closureCompiler:sdk', 'concat', 'replace', 'clean']);
grunt.registerTask('compile_sdk_native', ['compile_sdk_init:ADVANCED', 'closure-compiler:sdk', 'concat', 'replace', 'clean']);
grunt.registerTask('compile_sdk_native_fast', ['compile_sdk_init:WHITESPACE_ONLY', 'closure-compiler:sdk', 'concat', 'replace', 'clean']);
grunt.registerTask('deploy_sdk_init', function() {
grunt.initConfig({
......
{
"name": "common",
"version": "0.0.0",
"homepage": "http://www.teamlab.com",
"private": true,
"dependencies": {
"grunt": "0.4.2",
"grunt-contrib-clean": "0.5.0",
"grunt-contrib-concat": "0.3.0",
"grunt-contrib-copy": "0.5.0",
"grunt-exec": "0.4.5",
"grunt-replace": "0.7.3",
"grunt-closure-tools": "0.9.9"
}
}
\ No newline at end of file
"name": "common",
"version": "0.0.0",
"homepage": "http://www.teamlab.com",
"private": true,
"dependencies": {
"google-closure-compiler": "^20160315.0.0",
"grunt": "0.4.2",
"grunt-contrib-clean": "0.5.0",
"grunt-contrib-concat": "0.3.0",
"grunt-contrib-copy": "0.5.0",
"grunt-exec": "0.4.5",
"grunt-replace": "0.7.3"
}
}
......@@ -169,7 +169,7 @@
"dst": "../../word/sdk-all.js",
"externs": [
"../../common/Native/jquery_native.js",
"../../common/3rdparty/XRegExp/xregexp-all-min.js"
"../../../web-apps/vendor/xregexp/xregexp-all-min.js"
],
"map": "sdk-all.js.map",
"log": "../../word/Build/Log"
......
......@@ -23,7 +23,7 @@
"../../common/Charts/DrawingArea.js",
"../../common/Charts/DrawingObjects.js",
"../../common/Charts/ChartsDrawer.js",
"../../common/Charts/3DTransformation.js",
"../../common/Charts/3DTransformation.js",
"../../common/FontsFreeType/font_engine.js",
"../../common/FontsFreeType/FontFile.js",
"../../common/FontsFreeType/FontManager.js",
......@@ -44,7 +44,7 @@
"../../cell/model/ConditionalFormatting.js",
"../../cell/model/FormulaObjects/parserFormula.js",
"../../cell/model/FormulaObjects/_xlfnFunctions.js",
"../../cell/model/FormulaObjects/dateandtimeFunctions.js",
"../../cell/model/FormulaObjects/dateandtimeFunctions.js",
"../../cell/model/FormulaObjects/engineeringFunctions.js",
"../../cell/model/FormulaObjects/cubeFunctions.js",
"../../cell/model/FormulaObjects/databaseFunctions.js",
......@@ -133,10 +133,10 @@
"../../word/Editor/Document.js",
"../../word/Editor/DocumentContent.js",
"../../word/Editor/Table.js",
"../../word/Editor/Table/TableRecalculate.js",
"../../word/Editor/Table/TableDraw.js",
"../../word/Editor/Table/TableRow.js",
"../../word/Editor/Table/TableCell.js",
"../../word/Editor/Table/TableRecalculate.js",
"../../word/Editor/Table/TableDraw.js",
"../../word/Editor/Table/TableRow.js",
"../../word/Editor/Table/TableCell.js",
"../../word/Editor/Serialize2.js",
"../../word/Editor/FontClassification.js",
"../../word/Editor/Spelling.js",
......@@ -155,27 +155,27 @@
"../../word/Math/operators.js",
"../../word/Math/accent.js",
"../../word/Math/borderBox.js",
"../../common/CollaborativeEditingBase.js",
"../../common/CollaborativeEditingBase.js",
"../../cell/model/DrawingObjects/GlobalCounters.js",
"../../word/apiCommon.js",
"../../cell/apiCommonExport.js",
"../../common/apiBase.js",
"../../cell/api.js",
"../../common/Private/license.js",
"../../cell/Private/comments.js"
"../../common/Private/license.js",
"../../cell/Private/comments.js"
],
"dst": "../../cell/sdk-all.js",
"externs": [
"../../common/Build/Externs.js",
"../../common/3rdparty/jquery/jquery.min.js",
"../../common/3rdparty/Underscore/underscore-min.js",
"../../common/3rdparty/Sockjs/sockjs.min.js",
"../../common/3rdparty/XRegExp/xregexp-all-min.js",
"../../common/3rdparty/jszip/jszip.min.js",
"../../common/3rdparty/jszip-utils/jszip-utils.min.js",
"../../common/3rdparty/jsrsasign/jsrsasign-latest-all-min.js",
"../../common/3rdparty/perfect-scrollbar/jquery.mousewheel.js",
"../../common/3rdparty/perfect-scrollbar/perfect-scrollbar.js"
"../../../web-apps/vendor/jquery/jquery.min.js",
"../../../web-apps/vendor/underscore/underscore-min.js",
"../../../web-apps/vendor/sockjs/sockjs.min.js",
"../../../web-apps/vendor/xregexp/xregexp-all-min.js",
"../../../web-apps/vendor/jszip/jszip.min.js",
"../../../web-apps/vendor/jszip-utils/jszip-utils.min.js",
"../../../web-apps/vendor/jsrsasign/jsrsasign-latest-all-min.js",
"../../../web-apps/vendor/perfect-scrollbar/src/jquery.mousewheel.js",
"../../../web-apps/vendor/perfect-scrollbar/src/perfect-scrollbar.js"
],
"map": "sdk-all.js.map",
"log": "../../cell/Build/Log"
......
......@@ -38,17 +38,17 @@
"../../word/Editor/Styles.js",
"../../word/Editor/Numbering.js",
"../../word/Drawing/Metafile.js",
"../../common/CollaborativeEditingBase.js",
"../../common/CollaborativeEditingBase.js",
"../../slide/Editor/CollaborativeEditing.js",
"../../word/Drawing/GraphicsEvents.js",
"../../word/Drawing/WorkEvents.js",
"../../common/Controls.js",
"../../word/Drawing/Rulers.js",
"../../word/Editor/Table.js",
"../../word/Editor/Table/TableRecalculate.js",
"../../word/Editor/Table/TableDraw.js",
"../../word/Editor/Table/TableRow.js",
"../../word/Editor/Table/TableCell.js",
"../../word/Editor/Table/TableRecalculate.js",
"../../word/Editor/Table/TableDraw.js",
"../../word/Editor/Table/TableRow.js",
"../../word/Editor/Table/TableCell.js",
"../../word/Editor/Common.js",
"../../word/Editor/Sections.js",
"../../common/scroll.js",
......@@ -134,8 +134,8 @@
"../../slide/Editor/Format/GraphicFrame.js",
"../../common/apiBase.js",
"../../slide/api.js",
"../../common/Private/license.js",
"../../slide/Private/comments.js",
"../../common/Private/license.js",
"../../slide/Private/comments.js",
"../../slide/apiCommon.js",
"../../word/apiCommon.js",
"../../slide/apiExport.js",
......@@ -150,13 +150,13 @@
"dst": "../../slide/sdk-all.js",
"externs": [
"../../common/Build/Externs.js",
"../../common/3rdparty/jquery/jquery.min.js",
"../../common/3rdparty/Underscore/underscore-min.js",
"../../common/3rdparty/Sockjs/sockjs.min.js",
"../../common/3rdparty/XRegExp/xregexp-all-min.js",
"../../common/3rdparty/jszip/jszip.min.js",
"../../common/3rdparty/jszip-utils/jszip-utils.min.js",
"../../common/3rdparty/jsrsasign/jsrsasign-latest-all-min.js"
"../../../web-apps/vendor/jquery/jquery.min.js",
"../../../web-apps/vendor/underscore/underscore-min.js",
"../../../web-apps/vendor/sockjs/sockjs.min.js",
"../../../web-apps/vendor/xregexp/xregexp-all-min.js",
"../../../web-apps/vendor/jszip/jszip.min.js",
"../../../web-apps/vendor/jszip-utils/jszip-utils.min.js",
"../../../web-apps/vendor/jsrsasign/jsrsasign-latest-all-min.js"
],
"map": "sdk-all.js.map",
"log": "../../slide/Build/Log"
......
......@@ -37,7 +37,7 @@
"../../word/Drawing/translations.js",
"../../common/Charts/charts.js",
"../../common/Charts/ChartsDrawer.js",
"../../common/Charts/3DTransformation.js",
"../../common/Charts/3DTransformation.js",
"../../common/Charts/DrawingArea.js",
"../../common/Charts/DrawingObjects.js",
"../../common/NumFormat.js",
......@@ -94,10 +94,10 @@
"../../word/Editor/Common.js",
"../../word/Editor/DocumentContent.js",
"../../word/Editor/Table.js",
"../../word/Editor/Table/TableRecalculate.js",
"../../word/Editor/Table/TableDraw.js",
"../../word/Editor/Table/TableRow.js",
"../../word/Editor/Table/TableCell.js",
"../../word/Editor/Table/TableRecalculate.js",
"../../word/Editor/Table/TableDraw.js",
"../../word/Editor/Table/TableRow.js",
"../../word/Editor/Table/TableCell.js",
"../../word/Editor/Serialize2.js",
"../../word/Editor/Search.js",
"../../word/Editor/FontClassification.js",
......@@ -107,7 +107,7 @@
"../../word/Drawing/HatchPattern.js",
"../../word/Drawing/ShapeDrawer.js",
"../../word/Drawing/Metafile.js",
"../../common/CollaborativeEditingBase.js",
"../../common/CollaborativeEditingBase.js",
"../../word/Drawing/DrawingDocument.js",
"../../word/Drawing/GraphicsEvents.js",
"../../common/Scrolls/iscroll.js",
......@@ -121,9 +121,9 @@
"../../word/apiDefines.js",
"../../common/apiBase.js",
"../../word/api.js",
"../../common/Private/license.js",
"../../common/Private/versionHistory.js",
"../../word/Private/comments.js",
"../../common/Private/license.js",
"../../common/Private/versionHistory.js",
"../../word/Private/comments.js",
"../../word/Private/StyleManager.js",
"../../word/Private/MailMerge.js",
"../../word/Private/TrackRevisions.js",
......@@ -155,13 +155,13 @@
"dst": "../../word/sdk-all.js",
"externs": [
"../../common/Build/Externs.js",
"../../common/3rdparty/jquery/jquery.min.js",
"../../common/3rdparty/Underscore/underscore-min.js",
"../../common/3rdparty/Sockjs/sockjs.min.js",
"../../common/3rdparty/XRegExp/xregexp-all-min.js",
"../../common/3rdparty/jszip/jszip.min.js",
"../../common/3rdparty/jszip-utils/jszip-utils.min.js",
"../../common/3rdparty/jsrsasign/jsrsasign-latest-all-min.js"
"../../../web-apps/vendor/jquery/jquery.min.js",
"../../../web-apps/vendor/underscore/underscore-min.js",
"../../../web-apps/vendor/sockjs/sockjs.min.js",
"../../../web-apps/vendor/xregexp/xregexp-all-min.js",
"../../../web-apps/vendor/jszip/jszip.min.js",
"../../../web-apps/vendor/jszip-utils/jszip-utils.min.js",
"../../../web-apps/vendor/jsrsasign/jsrsasign-latest-all-min.js"
],
"map": "sdk-all.js.map",
"log": "../../word/Build/Log"
......@@ -237,4 +237,4 @@
"compile_sdk"
]
}
}
}
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment