Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
掘金者说
vscode
提交
74fa1d89
V
vscode
项目概览
掘金者说
/
vscode
与 Fork 源项目一致
从无法访问的项目Fork
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
V
vscode
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
未验证
提交
74fa1d89
编写于
9月 06, 2018
作者:
J
Johannes Rieken
提交者:
GitHub
9月 06, 2018
浏览文件
操作
浏览文件
下载
差异文件
Merge pull request #57956 from Microsoft/joh/vsce-next
use packagedDependencies from running vsce#ls
上级
126082fd
9536dde3
变更
10
隐藏空白更改
内联
并排
Showing
10 changed file
with
241 addition
and
177 deletion
+241
-177
build/gulpfile.vscode.js
build/gulpfile.vscode.js
+10
-9
build/lib/extensions.js
build/lib/extensions.js
+92
-64
build/lib/extensions.ts
build/lib/extensions.ts
+116
-80
build/lib/stats.js
build/lib/stats.js
+4
-3
build/lib/stats.ts
build/lib/stats.ts
+5
-3
extensions/emmet/.vscodeignore
extensions/emmet/.vscodeignore
+2
-4
extensions/git/.vscodeignore
extensions/git/.vscodeignore
+1
-5
extensions/typescript-language-features/.vscodeignore
extensions/typescript-language-features/.vscodeignore
+0
-2
package.json
package.json
+1
-1
yarn.lock
yarn.lock
+10
-6
未找到文件。
build/gulpfile.vscode.js
浏览文件 @
74fa1d89
...
...
@@ -327,15 +327,16 @@ function packageTask(platform, arch, opts) {
.
pipe
(
rename
(
'
bin/
'
+
product
.
applicationName
)));
}
return
result
.
pipe
(
es
.
through
(
undefined
,
function
()
{
// submit all stats that have been collected during the build phase
if
(
!
opts
.
stats
)
{
return
this
.
emit
(
'
end
'
);
}
const
{
submitAllStats
}
=
require
(
'
./lib/stats
'
);
submitAllStats
(
product
).
then
(()
=>
this
.
emit
(
'
end
'
)).
catch
(()
=>
this
.
emit
(
'
end
'
));
})).
pipe
(
vfs
.
dest
(
destination
));
// submit all stats that have been collected
// during the build phase
if
(
opts
.
stats
)
{
result
.
on
(
'
end
'
,
()
=>
{
const
{
submitAllStats
}
=
require
(
'
./lib/stats
'
);
submitAllStats
(
product
).
then
(()
=>
console
.
log
(
'
Submitted bundle stats!
'
));
});
}
return
result
.
pipe
(
vfs
.
dest
(
destination
));
};
}
...
...
build/lib/extensions.js
浏览文件 @
74fa1d89
...
...
@@ -37,8 +37,26 @@ var webpack = require('webpack');
var
webpackGulp
=
require
(
'
webpack-stream
'
);
var
root
=
path
.
resolve
(
path
.
join
(
__dirname
,
'
..
'
,
'
..
'
));
function
fromLocal
(
extensionPath
,
sourceMappingURLBase
)
{
var
webpackFilename
=
path
.
join
(
extensionPath
,
'
extension.webpack.config.js
'
);
if
(
fs
.
existsSync
(
webpackFilename
))
{
return
fromLocalWebpack
(
extensionPath
,
sourceMappingURLBase
);
}
else
{
return
fromLocalNormal
(
extensionPath
);
}
}
exports
.
fromLocal
=
fromLocal
;
function
fromLocalWebpack
(
extensionPath
,
sourceMappingURLBase
)
{
var
result
=
es
.
through
();
vsce
.
listFiles
({
cwd
:
extensionPath
,
packageManager
:
vsce
.
PackageManager
.
Yarn
}).
then
(
function
(
fileNames
)
{
var
packagedDependencies
=
[];
var
packageJsonConfig
=
require
(
path
.
join
(
extensionPath
,
'
package.json
'
));
var
webpackRootConfig
=
require
(
path
.
join
(
extensionPath
,
'
extension.webpack.config.js
'
));
for
(
var
key
in
webpackRootConfig
.
externals
)
{
if
(
key
in
packageJsonConfig
.
dependencies
)
{
packagedDependencies
.
push
(
key
);
}
}
vsce
.
listFiles
({
cwd
:
extensionPath
,
packageManager
:
vsce
.
PackageManager
.
Yarn
,
packagedDependencies
:
packagedDependencies
}).
then
(
function
(
fileNames
)
{
var
files
=
fileNames
.
map
(
function
(
fileName
)
{
return
path
.
join
(
extensionPath
,
fileName
);
})
.
map
(
function
(
filePath
)
{
return
new
File
({
...
...
@@ -51,76 +69,86 @@ function fromLocal(extensionPath, sourceMappingURLBase) {
// check for a webpack configuration files, then invoke webpack
// and merge its output with the files stream. also rewrite the package.json
// file to a new entry point
var
pattern
=
path
.
join
(
extensionPath
,
'
/**/extension.webpack.config.js
'
);
var
webpackConfigLocations
=
glob
.
sync
(
pattern
,
{
ignore
:
[
'
**/node_modules
'
]
});
if
(
webpackConfigLocations
.
length
)
{
var
packageJsonFilter
=
filter
(
function
(
f
)
{
if
(
path
.
basename
(
f
.
path
)
===
'
package.json
'
)
{
// only modify package.json's next to the webpack file.
// to be safe, use existsSync instead of path comparison.
return
fs
.
existsSync
(
path
.
join
(
path
.
dirname
(
f
.
path
),
'
extension.webpack.config.js
'
));
var
webpackConfigLocations
=
glob
.
sync
(
path
.
join
(
extensionPath
,
'
/**/extension.webpack.config.js
'
),
{
ignore
:
[
'
**/node_modules
'
]
});
var
packageJsonFilter
=
filter
(
function
(
f
)
{
if
(
path
.
basename
(
f
.
path
)
===
'
package.json
'
)
{
// only modify package.json's next to the webpack file.
// to be safe, use existsSync instead of path comparison.
return
fs
.
existsSync
(
path
.
join
(
path
.
dirname
(
f
.
path
),
'
extension.webpack.config.js
'
));
}
return
false
;
},
{
restore
:
true
});
var
patchFilesStream
=
filesStream
.
pipe
(
packageJsonFilter
)
.
pipe
(
buffer
())
.
pipe
(
json
(
function
(
data
)
{
// hardcoded entry point directory!
data
.
main
=
data
.
main
.
replace
(
'
/out/
'
,
/dist/
);
return
data
;
}))
.
pipe
(
packageJsonFilter
.
restore
);
var
webpackStreams
=
webpackConfigLocations
.
map
(
function
(
webpackConfigPath
)
{
var
webpackDone
=
function
(
err
,
stats
)
{
util
.
log
(
"
Bundled extension:
"
+
util
.
colors
.
yellow
(
path
.
join
(
path
.
basename
(
extensionPath
),
path
.
relative
(
extensionPath
,
webpackConfigPath
)))
+
"
...
"
);
if
(
err
)
{
result
.
emit
(
'
error
'
,
err
);
}
return
false
;
},
{
restore
:
true
});
var
patchFilesStream
=
filesStream
.
pipe
(
packageJsonFilter
)
.
pipe
(
buffer
())
.
pipe
(
json
(
function
(
data
)
{
// hardcoded entry point directory!
data
.
main
=
data
.
main
.
replace
(
'
/out/
'
,
/dist/
);
return
data
;
var
compilation
=
stats
.
compilation
;
if
(
compilation
.
errors
.
length
>
0
)
{
result
.
emit
(
'
error
'
,
compilation
.
errors
.
join
(
'
\n
'
));
}
if
(
compilation
.
warnings
.
length
>
0
)
{
result
.
emit
(
'
error
'
,
compilation
.
warnings
.
join
(
'
\n
'
));
}
};
var
webpackConfig
=
__assign
({},
require
(
webpackConfigPath
),
{
mode
:
'
production
'
});
var
relativeOutputPath
=
path
.
relative
(
extensionPath
,
webpackConfig
.
output
.
path
);
return
webpackGulp
(
webpackConfig
,
webpack
,
webpackDone
)
.
pipe
(
es
.
through
(
function
(
data
)
{
data
.
stat
=
data
.
stat
||
{};
data
.
base
=
extensionPath
;
this
.
emit
(
'
data
'
,
data
);
}))
.
pipe
(
packageJsonFilter
.
restore
);
var
webpackStreams
=
webpackConfigLocations
.
map
(
function
(
webpackConfigPath
)
{
var
webpackDone
=
function
(
err
,
stats
)
{
util
.
log
(
"
Bundled extension:
"
+
util
.
colors
.
yellow
(
path
.
join
(
path
.
basename
(
extensionPath
),
path
.
relative
(
extensionPath
,
webpackConfigPath
)))
+
"
...
"
);
if
(
err
)
{
result
.
emit
(
'
error
'
,
err
);
}
var
compilation
=
stats
.
compilation
;
if
(
compilation
.
errors
.
length
>
0
)
{
result
.
emit
(
'
error
'
,
compilation
.
errors
.
join
(
'
\n
'
));
}
if
(
compilation
.
warnings
.
length
>
0
)
{
result
.
emit
(
'
error
'
,
compilation
.
warnings
.
join
(
'
\n
'
));
}
};
var
webpackConfig
=
__assign
({},
require
(
webpackConfigPath
),
{
mode
:
'
production
'
});
var
relativeOutputPath
=
path
.
relative
(
extensionPath
,
webpackConfig
.
output
.
path
);
return
webpackGulp
(
webpackConfig
,
webpack
,
webpackDone
)
.
pipe
(
es
.
through
(
function
(
data
)
{
data
.
stat
=
data
.
stat
||
{};
data
.
base
=
extensionPath
;
this
.
emit
(
'
data
'
,
data
);
}))
.
pipe
(
es
.
through
(
function
(
data
)
{
// source map handling:
// * rewrite sourceMappingURL
// * save to disk so that upload-task picks this up
if
(
sourceMappingURLBase
)
{
var
contents
=
data
.
contents
.
toString
(
'
utf8
'
);
data
.
contents
=
Buffer
.
from
(
contents
.
replace
(
/
\n\/\/
# sourceMappingURL=
(
.*
)
$/gm
,
function
(
_m
,
g1
)
{
return
"
\n
//# sourceMappingURL=
"
+
sourceMappingURLBase
+
"
/extensions/
"
+
path
.
basename
(
extensionPath
)
+
"
/
"
+
relativeOutputPath
+
"
/
"
+
g1
;
}),
'
utf8
'
);
if
(
/
\.
js
\.
map$/
.
test
(
data
.
path
))
{
if
(
!
fs
.
existsSync
(
path
.
dirname
(
data
.
path
)))
{
fs
.
mkdirSync
(
path
.
dirname
(
data
.
path
));
}
fs
.
writeFileSync
(
data
.
path
,
data
.
contents
);
.
pipe
(
es
.
through
(
function
(
data
)
{
// source map handling:
// * rewrite sourceMappingURL
// * save to disk so that upload-task picks this up
if
(
sourceMappingURLBase
)
{
var
contents
=
data
.
contents
.
toString
(
'
utf8
'
);
data
.
contents
=
Buffer
.
from
(
contents
.
replace
(
/
\n\/\/
# sourceMappingURL=
(
.*
)
$/gm
,
function
(
_m
,
g1
)
{
return
"
\n
//# sourceMappingURL=
"
+
sourceMappingURLBase
+
"
/extensions/
"
+
path
.
basename
(
extensionPath
)
+
"
/
"
+
relativeOutputPath
+
"
/
"
+
g1
;
}),
'
utf8
'
);
if
(
/
\.
js
\.
map$/
.
test
(
data
.
path
))
{
if
(
!
fs
.
existsSync
(
path
.
dirname
(
data
.
path
)))
{
fs
.
mkdirSync
(
path
.
dirname
(
data
.
path
));
}
fs
.
writeFileSync
(
data
.
path
,
data
.
contents
);
}
this
.
emit
(
'
data
'
,
data
);
}));
});
es
.
merge
.
apply
(
es
,
webpackStreams
.
concat
([
patchFilesStream
])).
pipe
(
result
);
}
else
{
filesStream
.
pipe
(
result
);
}
}
this
.
emit
(
'
data
'
,
data
);
}));
});
es
.
merge
.
apply
(
es
,
webpackStreams
.
concat
([
patchFilesStream
])).
pipe
(
result
);
}).
catch
(
function
(
err
)
{
return
result
.
emit
(
'
error
'
,
err
);
});
return
result
.
pipe
(
stats_1
.
createStatsStream
(
path
.
basename
(
extensionPath
)));
}
exports
.
fromLocal
=
fromLocal
;
function
fromLocalNormal
(
extensionPath
)
{
var
result
=
es
.
through
();
vsce
.
listFiles
({
cwd
:
extensionPath
,
packageManager
:
vsce
.
PackageManager
.
Yarn
})
.
then
(
function
(
fileNames
)
{
var
files
=
fileNames
.
map
(
function
(
fileName
)
{
return
path
.
join
(
extensionPath
,
fileName
);
})
.
map
(
function
(
filePath
)
{
return
new
File
({
path
:
filePath
,
stat
:
fs
.
statSync
(
filePath
),
base
:
extensionPath
,
contents
:
fs
.
createReadStream
(
filePath
)
});
});
es
.
readArray
(
files
).
pipe
(
result
);
})
.
catch
(
function
(
err
)
{
return
result
.
emit
(
'
error
'
,
err
);
});
return
result
;
}
function
error
(
err
)
{
var
result
=
es
.
through
();
setTimeout
(
function
()
{
return
result
.
emit
(
'
error
'
,
err
);
});
...
...
build/lib/extensions.ts
浏览文件 @
74fa1d89
...
...
@@ -28,9 +28,27 @@ const webpackGulp = require('webpack-stream');
const
root
=
path
.
resolve
(
path
.
join
(
__dirname
,
'
..
'
,
'
..
'
));
export
function
fromLocal
(
extensionPath
:
string
,
sourceMappingURLBase
?:
string
):
Stream
{
const
webpackFilename
=
path
.
join
(
extensionPath
,
'
extension.webpack.config.js
'
);
if
(
fs
.
existsSync
(
webpackFilename
))
{
return
fromLocalWebpack
(
extensionPath
,
sourceMappingURLBase
);
}
else
{
return
fromLocalNormal
(
extensionPath
);
}
}
function
fromLocalWebpack
(
extensionPath
:
string
,
sourceMappingURLBase
:
string
):
Stream
{
let
result
=
es
.
through
();
vsce
.
listFiles
({
cwd
:
extensionPath
,
packageManager
:
vsce
.
PackageManager
.
Yarn
}).
then
(
fileNames
=>
{
let
packagedDependencies
:
string
[]
=
[];
let
packageJsonConfig
=
require
(
path
.
join
(
extensionPath
,
'
package.json
'
));
let
webpackRootConfig
=
require
(
path
.
join
(
extensionPath
,
'
extension.webpack.config.js
'
));
for
(
const
key
in
webpackRootConfig
.
externals
)
{
if
(
key
in
packageJsonConfig
.
dependencies
)
{
packagedDependencies
.
push
(
key
);
}
}
vsce
.
listFiles
({
cwd
:
extensionPath
,
packageManager
:
vsce
.
PackageManager
.
Yarn
,
packagedDependencies
}).
then
(
fileNames
=>
{
const
files
=
fileNames
.
map
(
fileName
=>
path
.
join
(
extensionPath
,
fileName
))
.
map
(
filePath
=>
new
File
({
...
...
@@ -45,96 +63,114 @@ export function fromLocal(extensionPath: string, sourceMappingURLBase?: string):
// check for a webpack configuration files, then invoke webpack
// and merge its output with the files stream. also rewrite the package.json
// file to a new entry point
const
pattern
=
path
.
join
(
extensionPath
,
'
/**/extension.webpack.config.js
'
);
const
webpackConfigLocations
=
(
<
string
[]
>
glob
.
sync
(
pattern
,
{
ignore
:
[
'
**/node_modules
'
]
}));
if
(
webpackConfigLocations
.
length
)
{
const
packageJsonFilter
=
filter
(
f
=>
{
if
(
path
.
basename
(
f
.
path
)
===
'
package.json
'
)
{
// only modify package.json's next to the webpack file.
// to be safe, use existsSync instead of path comparison.
return
fs
.
existsSync
(
path
.
join
(
path
.
dirname
(
f
.
path
),
'
extension.webpack.config.js
'
));
const
webpackConfigLocations
=
(
<
string
[]
>
glob
.
sync
(
path
.
join
(
extensionPath
,
'
/**/extension.webpack.config.js
'
),
{
ignore
:
[
'
**/node_modules
'
]
}
));
const
packageJsonFilter
=
filter
(
f
=>
{
if
(
path
.
basename
(
f
.
path
)
===
'
package.json
'
)
{
// only modify package.json's next to the webpack file.
// to be safe, use existsSync instead of path comparison.
return
fs
.
existsSync
(
path
.
join
(
path
.
dirname
(
f
.
path
),
'
extension.webpack.config.js
'
));
}
return
false
;
},
{
restore
:
true
});
const
patchFilesStream
=
filesStream
.
pipe
(
packageJsonFilter
)
.
pipe
(
buffer
())
.
pipe
(
json
(
data
=>
{
// hardcoded entry point directory!
data
.
main
=
data
.
main
.
replace
(
'
/out/
'
,
/dist/
);
return
data
;
}))
.
pipe
(
packageJsonFilter
.
restore
);
const
webpackStreams
=
webpackConfigLocations
.
map
(
webpackConfigPath
=>
{
const
webpackDone
=
(
err
,
stats
)
=>
{
util
.
log
(
`Bundled extension:
${
util
.
colors
.
yellow
(
path
.
join
(
path
.
basename
(
extensionPath
),
path
.
relative
(
extensionPath
,
webpackConfigPath
)))}
...`
);
if
(
err
)
{
result
.
emit
(
'
error
'
,
err
);
}
return
false
;
},
{
restore
:
true
});
const
patchFilesStream
=
filesStream
.
pipe
(
packageJsonFilter
)
.
pipe
(
buffer
())
.
pipe
(
json
(
data
=>
{
// hardcoded entry point directory!
data
.
main
=
data
.
main
.
replace
(
'
/out/
'
,
/dist/
);
return
data
;
}))
.
pipe
(
packageJsonFilter
.
restore
);
const
{
compilation
}
=
stats
;
if
(
compilation
.
errors
.
length
>
0
)
{
result
.
emit
(
'
error
'
,
compilation
.
errors
.
join
(
'
\n
'
));
}
if
(
compilation
.
warnings
.
length
>
0
)
{
result
.
emit
(
'
error
'
,
compilation
.
warnings
.
join
(
'
\n
'
));
}
};
const
webpackStreams
=
webpackConfigLocations
.
map
(
webpackConfigPath
=>
{
const
webpackConfig
=
{
...
require
(
webpackConfigPath
),
...{
mode
:
'
production
'
}
};
let
relativeOutputPath
=
path
.
relative
(
extensionPath
,
webpackConfig
.
output
.
path
);
const
webpackDone
=
(
err
,
stats
)
=>
{
util
.
log
(
`Bundled extension:
${
util
.
colors
.
yellow
(
path
.
join
(
path
.
basename
(
extensionPath
),
path
.
relative
(
extensionPath
,
webpackConfigPath
)))}
...`
);
if
(
err
)
{
result
.
emit
(
'
error
'
,
err
);
}
const
{
compilation
}
=
stats
;
if
(
compilation
.
errors
.
length
>
0
)
{
result
.
emit
(
'
error
'
,
compilation
.
errors
.
join
(
'
\n
'
));
}
if
(
compilation
.
warnings
.
length
>
0
)
{
result
.
emit
(
'
error
'
,
compilation
.
warnings
.
join
(
'
\n
'
));
}
};
const
webpackConfig
=
{
...
require
(
webpackConfigPath
),
...{
mode
:
'
production
'
}
};
let
relativeOutputPath
=
path
.
relative
(
extensionPath
,
webpackConfig
.
output
.
path
);
return
webpackGulp
(
webpackConfig
,
webpack
,
webpackDone
)
.
pipe
(
es
.
through
(
function
(
data
)
{
data
.
stat
=
data
.
stat
||
{};
data
.
base
=
extensionPath
;
this
.
emit
(
'
data
'
,
data
);
}))
.
pipe
(
es
.
through
(
function
(
data
:
File
)
{
// source map handling:
// * rewrite sourceMappingURL
// * save to disk so that upload-task picks this up
if
(
sourceMappingURLBase
)
{
const
contents
=
(
<
Buffer
>
data
.
contents
).
toString
(
'
utf8
'
);
data
.
contents
=
Buffer
.
from
(
contents
.
replace
(
/
\n\/\/
# sourceMappingURL=
(
.*
)
$/gm
,
function
(
_m
,
g1
)
{
return
`\n//# sourceMappingURL=
${
sourceMappingURLBase
}
/extensions/
${
path
.
basename
(
extensionPath
)}
/
${
relativeOutputPath
}
/
${
g1
}
`
;
}),
'
utf8
'
);
if
(
/
\.
js
\.
map$/
.
test
(
data
.
path
))
{
if
(
!
fs
.
existsSync
(
path
.
dirname
(
data
.
path
)))
{
fs
.
mkdirSync
(
path
.
dirname
(
data
.
path
));
}
fs
.
writeFileSync
(
data
.
path
,
data
.
contents
);
return
webpackGulp
(
webpackConfig
,
webpack
,
webpackDone
)
.
pipe
(
es
.
through
(
function
(
data
)
{
data
.
stat
=
data
.
stat
||
{};
data
.
base
=
extensionPath
;
this
.
emit
(
'
data
'
,
data
);
}))
.
pipe
(
es
.
through
(
function
(
data
:
File
)
{
// source map handling:
// * rewrite sourceMappingURL
// * save to disk so that upload-task picks this up
if
(
sourceMappingURLBase
)
{
const
contents
=
(
<
Buffer
>
data
.
contents
).
toString
(
'
utf8
'
);
data
.
contents
=
Buffer
.
from
(
contents
.
replace
(
/
\n\/\/
# sourceMappingURL=
(
.*
)
$/gm
,
function
(
_m
,
g1
)
{
return
`\n//# sourceMappingURL=
${
sourceMappingURLBase
}
/extensions/
${
path
.
basename
(
extensionPath
)}
/
${
relativeOutputPath
}
/
${
g1
}
`
;
}),
'
utf8
'
);
if
(
/
\.
js
\.
map$/
.
test
(
data
.
path
))
{
if
(
!
fs
.
existsSync
(
path
.
dirname
(
data
.
path
)))
{
fs
.
mkdirSync
(
path
.
dirname
(
data
.
path
));
}
fs
.
writeFileSync
(
data
.
path
,
data
.
contents
);
}
this
.
emit
(
'
data
'
,
data
);
}));
});
es
.
merge
(...
webpackStreams
,
patchFilesStream
)
// .pipe(es.through(function (data) {
// // debug
// console.log('out', data.path, data.contents.length);
// this.emit('data', data);
// }))
.
pipe
(
result
);
}
else
{
filesStream
.
pipe
(
result
);
}
}
this
.
emit
(
'
data
'
,
data
);
}));
});
es
.
merge
(...
webpackStreams
,
patchFilesStream
)
// .pipe(es.through(function (data) {
// // debug
// console.log('out', data.path, data.contents.length);
// this.emit('data', data);
// }))
.
pipe
(
result
);
}).
catch
(
err
=>
result
.
emit
(
'
error
'
,
err
));
return
result
.
pipe
(
createStatsStream
(
path
.
basename
(
extensionPath
)));
}
function
fromLocalNormal
(
extensionPath
:
string
):
Stream
{
const
result
=
es
.
through
();
vsce
.
listFiles
({
cwd
:
extensionPath
,
packageManager
:
vsce
.
PackageManager
.
Yarn
})
.
then
(
fileNames
=>
{
const
files
=
fileNames
.
map
(
fileName
=>
path
.
join
(
extensionPath
,
fileName
))
.
map
(
filePath
=>
new
File
({
path
:
filePath
,
stat
:
fs
.
statSync
(
filePath
),
base
:
extensionPath
,
contents
:
fs
.
createReadStream
(
filePath
)
as
any
}));
es
.
readArray
(
files
).
pipe
(
result
);
})
.
catch
(
err
=>
result
.
emit
(
'
error
'
,
err
));
return
result
;
}
function
error
(
err
:
any
):
Stream
{
const
result
=
es
.
through
();
setTimeout
(()
=>
result
.
emit
(
'
error
'
,
err
));
...
...
build/lib/stats.js
浏览文件 @
74fa1d89
...
...
@@ -105,14 +105,15 @@ function submitAllStats(productJson) {
.
setAutoCollectPerformance
(
false
)
.
setAutoCollectRequests
(
false
)
.
start
();
appInsights
.
defaultClient
.
config
.
endpointUrl
=
'
https://vortex.data.microsoft.com/collect/v1
'
;
var
client
=
appInsights
.
getClient
(
productJson
.
aiConfig
.
asimovKey
);
client
.
config
.
endpointUrl
=
'
https://vortex.data.microsoft.com/collect/v1
'
;
/* __GDPR__
"monacoworkbench/bundleStats" : {
"outcome" : {"classification": "SystemMetaData", "purpose": "PerformanceAndHealth", "isMeasurement": true }
}
*/
appInsights
.
defaultC
lient
.
trackEvent
(
"
monacoworkbench/bundleStats
"
,
undefined
,
measurements
);
appInsights
.
defaultC
lient
.
sendPendingData
(
function
()
{
return
resolve
();
});
c
lient
.
trackEvent
(
"
monacoworkbench/bundleStats
"
,
undefined
,
measurements
);
c
lient
.
sendPendingData
(
function
()
{
return
resolve
();
});
});
}
exports
.
submitAllStats
=
submitAllStats
;
build/lib/stats.ts
浏览文件 @
74fa1d89
...
...
@@ -111,14 +111,16 @@ export function submitAllStats(productJson: any): Promise<void> {
.
setAutoCollectRequests
(
false
)
.
start
();
appInsights
.
defaultClient
.
config
.
endpointUrl
=
'
https://vortex.data.microsoft.com/collect/v1
'
;
const
client
=
appInsights
.
getClient
(
productJson
.
aiConfig
.
asimovKey
);
client
.
config
.
endpointUrl
=
'
https://vortex.data.microsoft.com/collect/v1
'
;
/* __GDPR__
"monacoworkbench/bundleStats" : {
"outcome" : {"classification": "SystemMetaData", "purpose": "PerformanceAndHealth", "isMeasurement": true }
}
*/
appInsights
.
defaultC
lient
.
trackEvent
(
`monacoworkbench/bundleStats`
,
undefined
,
measurements
);
appInsights
.
defaultC
lient
.
sendPendingData
(()
=>
resolve
());
c
lient
.
trackEvent
(
`monacoworkbench/bundleStats`
,
undefined
,
measurements
);
c
lient
.
sendPendingData
(()
=>
resolve
());
});
}
extensions/emmet/.vscodeignore
浏览文件 @
74fa1d89
...
...
@@ -2,7 +2,5 @@ test/**
src/**
out/**
tsconfig.json
node_modules/@emmetio/css-parser/**
node_modules/@emmetio/html-matcher/**
node_modules/@emmetio/math-expression/**
node_modules/image-size/**
extension.webpack.config.js
extensions/git/.vscodeignore
浏览文件 @
74fa1d89
...
...
@@ -3,8 +3,4 @@ test/**
out/**
tsconfig.json
build/**
node_modules/byline/**
node_modules/file-type/**
node_modules/iconv-lite/**
node_modules/jschardet/**
node_modules/which/**
extension.webpack.config.js
extensions/typescript-language-features/.vscodeignore
浏览文件 @
74fa1d89
...
...
@@ -2,7 +2,5 @@ build/**
src/**
test/**
out/**
node_modules/jsonc-parser/**
node_modules/semver/**
tsconfig.json
extension.webpack.config.js
package.json
浏览文件 @
74fa1d89
...
...
@@ -127,7 +127,7 @@
"
underscore
"
:
"
^1.8.2
"
,
"
vinyl
"
:
"
^0.4.5
"
,
"
vinyl-fs
"
:
"
^2.4.3
"
,
"
vsce
"
:
"
1.
33.2
"
,
"
vsce
"
:
"
1.
48.0
"
,
"
vscode-nls-dev
"
:
"
3.2.2
"
,
"
webpack
"
:
"
^4.16.5
"
,
"
webpack-cli
"
:
"
^3.1.0
"
,
...
...
yarn.lock
浏览文件 @
74fa1d89
...
...
@@ -4568,6 +4568,10 @@ lodash@^4.0.0, lodash@^4.13.1, lodash@^4.14.0, lodash@^4.15.0, lodash@^4.3.0:
version "4.17.4"
resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.4.tgz#78203a4d1c328ae1d86dca6460e369b57f4055ae"
lodash@^4.17.10:
version "4.17.10"
resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.10.tgz#1b7793cf7259ea38fb3661d4d38b3260af8ae4e7"
lodash@~1.0.1:
version "1.0.2"
resolved "https://registry.yarnpkg.com/lodash/-/lodash-1.0.2.tgz#8f57560c83b59fc270bd3d561b690043430e2551"
...
...
@@ -7855,15 +7859,15 @@ vm-browserify@0.0.4:
dependencies:
indexof "0.0.1"
vsce@1.
33.2
:
version "1.
33.2
"
resolved "https://registry.yarnpkg.com/vsce/-/vsce-1.
33.2.tgz#3645f69aaf984e22f74ea49d35f38dd18d66ff5f
"
vsce@1.
48.0
:
version "1.
48.0
"
resolved "https://registry.yarnpkg.com/vsce/-/vsce-1.
48.0.tgz#31c1a4c6909c3b8bdc48b3d32cc8c8e94c7113a2
"
dependencies:
cheerio "^1.0.0-rc.1"
commander "^2.8.1"
denodeify "^1.2.1"
glob "^7.0.6"
lodash "^4.1
5.
0"
lodash "^4.1
7.1
0"
markdown-it "^8.3.1"
mime "^1.3.4"
minimatch "^3.0.3"
...
...
@@ -7873,7 +7877,7 @@ vsce@1.33.2:
semver "^5.1.0"
tmp "0.0.29"
url-join "^1.1.0"
vso-node-api "
^
6.1.2-preview"
vso-node-api "6.1.2-preview"
yauzl "^2.3.1"
yazl "^2.2.2"
...
...
@@ -7949,7 +7953,7 @@ vscode-xterm@3.8.0-beta1:
version "3.8.0-beta1"
resolved "https://registry.yarnpkg.com/vscode-xterm/-/vscode-xterm-3.8.0-beta1.tgz#d4e7810bc61c9798f353832844974c18f213c053"
vso-node-api@
^
6.1.2-preview:
vso-node-api@6.1.2-preview:
version "6.1.2-preview"
resolved "https://registry.yarnpkg.com/vso-node-api/-/vso-node-api-6.1.2-preview.tgz#aab3546df2451ecd894e071bb99b5df19c5fa78f"
dependencies:
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录