mirror of
https://github.com/Microsoft/vscode
synced 2024-08-27 13:00:58 +00:00
parent
f8cc75937a
commit
ab598a53ab
|
@ -12,7 +12,7 @@ const filter = require("gulp-filter");
|
|||
const _ = require("underscore");
|
||||
const util = require("./util");
|
||||
function isDocumentSuffix(str) {
|
||||
return str != undefined && (str === 'document' || str === 'script' || str === 'file' || str === 'source code');
|
||||
return str === 'document' || str === 'script' || str === 'file' || str === 'source code';
|
||||
}
|
||||
const root = path.dirname(path.dirname(__dirname));
|
||||
const product = JSON.parse(fs.readFileSync(path.join(root, 'product.json'), 'utf8'));
|
||||
|
|
|
@ -21,6 +21,8 @@ const fancyLog = require("fancy-log");
|
|||
const ansiColors = require("ansi-colors");
|
||||
const buffer = require('gulp-buffer');
|
||||
const jsoncParser = require("jsonc-parser");
|
||||
const dependencies_1 = require("./dependencies");
|
||||
const _ = require("underscore");
|
||||
const util = require('./util');
|
||||
const root = path.dirname(path.dirname(__dirname));
|
||||
const commit = util.getVersion(root);
|
||||
|
@ -242,8 +244,10 @@ function packageLocalExtensionsStream(forWeb) {
|
|||
result = localExtensionsStream;
|
||||
}
|
||||
else {
|
||||
// also include shared node modules
|
||||
result = es.merge(localExtensionsStream, gulp.src('extensions/node_modules/**', { base: '.' }));
|
||||
// also include shared production node modules
|
||||
const productionDependencies = (0, dependencies_1.getProductionDependencies)('extensions/');
|
||||
const dependenciesSrc = _.flatten(productionDependencies.map(d => path.relative(root, d.path)).map(d => [`${d}/**`, `!${d}/**/{test,tests}/**`]));
|
||||
result = es.merge(localExtensionsStream, gulp.src(dependenciesSrc, { base: '.' }));
|
||||
}
|
||||
return (result
|
||||
.pipe(util2.setExecutableBit(['**/*.sh'])));
|
||||
|
|
|
@ -21,6 +21,8 @@ import * as ansiColors from 'ansi-colors';
|
|||
const buffer = require('gulp-buffer');
|
||||
import * as jsoncParser from 'jsonc-parser';
|
||||
import webpack = require('webpack');
|
||||
import { getProductionDependencies } from './dependencies';
|
||||
import _ = require('underscore');
|
||||
const util = require('./util');
|
||||
const root = path.dirname(path.dirname(__dirname));
|
||||
const commit = util.getVersion(root);
|
||||
|
@ -302,8 +304,10 @@ export function packageLocalExtensionsStream(forWeb: boolean): Stream {
|
|||
if (forWeb) {
|
||||
result = localExtensionsStream;
|
||||
} else {
|
||||
// also include shared node modules
|
||||
result = es.merge(localExtensionsStream, gulp.src('extensions/node_modules/**', { base: '.' }));
|
||||
// also include shared production node modules
|
||||
const productionDependencies = getProductionDependencies('extensions/');
|
||||
const dependenciesSrc = _.flatten(productionDependencies.map(d => path.relative(root, d.path)).map(d => [`${d}/**`, `!${d}/**/{test,tests}/**`]));
|
||||
result = es.merge(localExtensionsStream, gulp.src(dependenciesSrc, { base: '.' }));
|
||||
}
|
||||
|
||||
return (
|
||||
|
|
Loading…
Reference in a new issue