Skip to content

Commit 8a5cf89

Browse files
committed
build(gulp): remove obsolete config
1 parent 22c79df commit 8a5cf89

File tree

1 file changed

+0
-149
lines changed

1 file changed

+0
-149
lines changed

gulpfile.js

Lines changed: 0 additions & 149 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ var merge = require('merge');
1313
var merge2 = require('merge2');
1414
var path = require('path');
1515

16-
var gulpTraceur = require('./tools/transpiler/gulp-traceur');
1716
var clean = require('./tools/build/clean');
1817
var transpile = require('./tools/build/transpile');
1918
var pubget = require('./tools/build/pubget');
@@ -55,50 +54,6 @@ var DART_SDK = require('./tools/build/dartdetect')(gulp);
5554
// -----------------------
5655
// configuration
5756

58-
var _COMPILER_CONFIG_JS_DEFAULT = {
59-
sourceMaps: true,
60-
annotations: true, // parse annotations
61-
types: true, // parse types
62-
script: false, // parse as a module
63-
memberVariables: true, // parse class fields
64-
modules: 'instantiate'
65-
};
66-
67-
var _HTML_DEFAULT_SCRIPTS_JS = [
68-
{src: gulpTraceur.RUNTIME_PATH, mimeType: 'text/javascript', copy: true},
69-
{src: 'node_modules/es6-module-loader/dist/es6-module-loader-sans-promises.src.js',
70-
mimeType: 'text/javascript', copy: true},
71-
{src: 'node_modules/zone.js/zone.js', mimeType: 'text/javascript', copy: true},
72-
{src: 'node_modules/zone.js/long-stack-trace-zone.js', mimeType: 'text/javascript', copy: true},
73-
{src: 'node_modules/systemjs/dist/system.src.js', mimeType: 'text/javascript', copy: true},
74-
{src: 'node_modules/systemjs/lib/extension-register.js', mimeType: 'text/javascript', copy: true},
75-
{src: 'node_modules/systemjs/lib/extension-cjs.js', mimeType: 'text/javascript', copy: true},
76-
{src: 'node_modules/rx/dist/rx.all.js', mimeType: 'text/javascript', copy: true},
77-
{src: 'tools/build/snippets/runtime_paths.js', mimeType: 'text/javascript', copy: true},
78-
{
79-
inline: 'System.import(\'$MODULENAME$\').then(function(m) { m.main(); }, console.error.bind(console))',
80-
mimeType: 'text/javascript'
81-
}
82-
];
83-
84-
var BASE_PACKAGE_JSON = require('./package.json');
85-
var COMMON_PACKAGE_JSON = {
86-
version: BASE_PACKAGE_JSON.version,
87-
homepage: BASE_PACKAGE_JSON.homepage,
88-
bugs: BASE_PACKAGE_JSON.bugs,
89-
license: BASE_PACKAGE_JSON.license,
90-
contributors: BASE_PACKAGE_JSON.contributors,
91-
dependencies: BASE_PACKAGE_JSON.dependencies,
92-
devDependencies: {
93-
"yargs": BASE_PACKAGE_JSON.devDependencies['yargs'],
94-
"gulp-sourcemaps": BASE_PACKAGE_JSON.devDependencies['gulp-sourcemaps'],
95-
"gulp-traceur": BASE_PACKAGE_JSON.devDependencies['gulp-traceur'],
96-
"gulp": BASE_PACKAGE_JSON.devDependencies['gulp'],
97-
"gulp-rename": BASE_PACKAGE_JSON.devDependencies['gulp-rename'],
98-
"through2": BASE_PACKAGE_JSON.devDependencies['through2']
99-
}
100-
};
101-
10257
var CONFIG = {
10358
dest: {
10459
js: {
@@ -117,115 +72,11 @@ var CONFIG = {
11772
dart: 'dist/dart',
11873
docs: 'dist/docs'
11974
},
120-
transpile: {
121-
src: {
122-
js: ['modules/**/*.js', 'modules/**/*.es6'],
123-
ts: ['modules/**/*.ts'],
124-
},
125-
options: {
126-
js: {
127-
dev: merge(true, _COMPILER_CONFIG_JS_DEFAULT, {
128-
typeAssertionModule: 'rtts_assert/rtts_assert',
129-
typeAssertions: true,
130-
outputLanguage: 'es6'
131-
}),
132-
prod: merge(true, _COMPILER_CONFIG_JS_DEFAULT, {
133-
typeAssertions: false,
134-
outputLanguage: 'es6'
135-
}),
136-
cjs: merge(true, _COMPILER_CONFIG_JS_DEFAULT, {
137-
typeAssertionModule: 'rtts_assert/rtts_assert',
138-
// Don't use type assertions since this is partly transpiled by typescript
139-
typeAssertions: false,
140-
modules: 'commonjs'
141-
})
142-
}
143-
}
144-
},
145-
copy: {
146-
js: {
147-
cjs: {
148-
src: [
149-
'modules/**/*.md', '!modules/**/*.dart.md', 'modules/**/*.png',
150-
'modules/**/package.json'
151-
],
152-
pipes: {
153-
'**/*.js.md': gulpPlugins.rename(function(file) {
154-
file.basename = file.basename.substring(0, file.basename.lastIndexOf('.'));
155-
}),
156-
'**/package.json': gulpPlugins.template({ 'packageJson': COMMON_PACKAGE_JSON })
157-
}
158-
},
159-
dev: {
160-
src: ['modules/**/*.css'],
161-
pipes: {}
162-
},
163-
prod: {
164-
src: ['modules/**/*.css'],
165-
pipes: {}
166-
}
167-
}
168-
},
169-
multicopy: {
170-
js: {
171-
cjs: {
172-
src: [
173-
'LICENSE'
174-
],
175-
pipes: {}
176-
},
177-
dev: {
178-
es6: {
179-
src: ['tools/build/es5build.js'],
180-
pipes: {}
181-
}
182-
},
183-
prod: {
184-
es6: {
185-
src: ['tools/build/es5build.js'],
186-
pipes: {}
187-
}
188-
}
189-
},
190-
},
191-
html: {
192-
src: {
193-
js: ['modules/*/src/**/*.html'],
194-
},
195-
scriptsPerFolder: {
196-
js: {
197-
'**': _HTML_DEFAULT_SCRIPTS_JS,
198-
'benchmarks/**':
199-
[
200-
{ src: 'tools/build/snippets/url_params_to_form.js', mimeType: 'text/javascript', copy: true }
201-
].concat(_HTML_DEFAULT_SCRIPTS_JS),
202-
'benchmarks_external/**':
203-
[
204-
{ src: 'node_modules/angular/angular.js', mimeType: 'text/javascript', copy: true },
205-
{ src: 'tools/build/snippets/url_params_to_form.js', mimeType: 'text/javascript', copy: true }
206-
].concat(_HTML_DEFAULT_SCRIPTS_JS),
207-
'benchmarks_external/**/*polymer*/**':
208-
[
209-
{ src: 'bower_components/polymer/lib/polymer.html', copyOnly: true },
210-
{ src: 'tools/build/snippets/url_params_to_form.js', mimeType: 'text/javascript', copy: true }
211-
]
212-
},
213-
}
214-
},
21575
formatDart: {
21676
packageName: 'dart_style',
21777
args: ['dart_style:format', '-w', 'dist/dart']
218-
},
219-
test: {
220-
js: {
221-
cjs: [
222-
'/angular2/test/**/*_spec.js'
223-
]
224-
}
22578
}
22679
};
227-
CONFIG.test.js.cjs = CONFIG.test.js.cjs.map(function(s) {return CONFIG.dest.js.cjs + s});
228-
CONFIG.test.js.cjs.push('!**/core/zone/vm_turn_zone_spec.js'); //Disabled in nodejs because it relies on Zone.js
22980

23081
// ------------
23182
// clean

0 commit comments

Comments
 (0)