Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
xxadev
vscode
提交
bb95f3aa
V
vscode
项目概览
xxadev
/
vscode
与 Fork 源项目一致
从无法访问的项目Fork
通知
2
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
V
vscode
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
未验证
提交
bb95f3aa
编写于
7月 07, 2020
作者:
A
Alex Dima
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Adopt loader's `amdModulesPattern` option
上级
bf2299cd
变更
4
显示空白变更内容
内联
并排
Showing
4 changed file
with
6 addition
and
17 deletion
+6
-17
build/gulpfile.vscode.js
build/gulpfile.vscode.js
+1
-12
build/lib/optimize.js
build/lib/optimize.js
+2
-2
build/lib/optimize.ts
build/lib/optimize.ts
+2
-2
src/bootstrap-window.js
src/bootstrap-window.js
+1
-1
未找到文件。
build/gulpfile.vscode.js
浏览文件 @
bb95f3aa
...
@@ -37,11 +37,6 @@ const { compileBuildTask } = require('./gulpfile.compile');
...
@@ -37,11 +37,6 @@ const { compileBuildTask } = require('./gulpfile.compile');
const
{
compileExtensionsBuildTask
}
=
require
(
'
./gulpfile.extensions
'
);
const
{
compileExtensionsBuildTask
}
=
require
(
'
./gulpfile.extensions
'
);
const
productionDependencies
=
deps
.
getProductionDependencies
(
path
.
dirname
(
__dirname
));
const
productionDependencies
=
deps
.
getProductionDependencies
(
path
.
dirname
(
__dirname
));
const
baseModules
=
Object
.
keys
(
process
.
binding
(
'
natives
'
)).
filter
(
n
=>
!
/^_|
\/
/
.
test
(
n
));
const
nodeModules
=
[
'
electron
'
,
'
original-fs
'
]
.
concat
(
Object
.
keys
(
product
.
dependencies
||
{}))
.
concat
(
_
.
uniq
(
productionDependencies
.
map
(
d
=>
d
.
name
)))
.
concat
(
baseModules
);
// Build
// Build
const
vscodeEntryPoints
=
_
.
flatten
([
const
vscodeEntryPoints
=
_
.
flatten
([
...
@@ -94,7 +89,7 @@ const optimizeVSCodeTask = task.define('optimize-vscode', task.series(
...
@@ -94,7 +89,7 @@ const optimizeVSCodeTask = task.define('optimize-vscode', task.series(
src
:
'
out-build
'
,
src
:
'
out-build
'
,
entryPoints
:
vscodeEntryPoints
,
entryPoints
:
vscodeEntryPoints
,
resources
:
vscodeResources
,
resources
:
vscodeResources
,
loaderConfig
:
common
.
loaderConfig
(
nodeModules
),
loaderConfig
:
common
.
loaderConfig
(),
out
:
'
out-vscode
'
,
out
:
'
out-vscode
'
,
bundleInfo
:
undefined
bundleInfo
:
undefined
})
})
...
@@ -105,12 +100,6 @@ const sourceMappingURLBase = `https://ticino.blob.core.windows.net/sourcemaps/${
...
@@ -105,12 +100,6 @@ const sourceMappingURLBase = `https://ticino.blob.core.windows.net/sourcemaps/${
const
minifyVSCodeTask
=
task
.
define
(
'
minify-vscode
'
,
task
.
series
(
const
minifyVSCodeTask
=
task
.
define
(
'
minify-vscode
'
,
task
.
series
(
optimizeVSCodeTask
,
optimizeVSCodeTask
,
util
.
rimraf
(
'
out-vscode-min
'
),
util
.
rimraf
(
'
out-vscode-min
'
),
()
=>
{
const
fullpath
=
path
.
join
(
process
.
cwd
(),
'
out-vscode/bootstrap-window.js
'
);
const
contents
=
fs
.
readFileSync
(
fullpath
).
toString
();
const
newContents
=
contents
.
replace
(
'
[/*BUILD->INSERT_NODE_MODULES*/]
'
,
JSON
.
stringify
(
nodeModules
));
fs
.
writeFileSync
(
fullpath
,
newContents
);
},
common
.
minifyTask
(
'
out-vscode
'
,
`
${
sourceMappingURLBase
}
/core`
)
common
.
minifyTask
(
'
out-vscode
'
,
`
${
sourceMappingURLBase
}
/core`
)
));
));
gulp
.
task
(
minifyVSCodeTask
);
gulp
.
task
(
minifyVSCodeTask
);
...
...
build/lib/optimize.js
浏览文件 @
bb95f3aa
...
@@ -28,13 +28,13 @@ const REPO_ROOT_PATH = path.join(__dirname, '../..');
...
@@ -28,13 +28,13 @@ const REPO_ROOT_PATH = path.join(__dirname, '../..');
function
log
(
prefix
,
message
)
{
function
log
(
prefix
,
message
)
{
fancyLog
(
ansiColors
.
cyan
(
'
[
'
+
prefix
+
'
]
'
),
message
);
fancyLog
(
ansiColors
.
cyan
(
'
[
'
+
prefix
+
'
]
'
),
message
);
}
}
function
loaderConfig
(
emptyPaths
)
{
function
loaderConfig
()
{
const
result
=
{
const
result
=
{
paths
:
{
paths
:
{
'
vs
'
:
'
out-build/vs
'
,
'
vs
'
:
'
out-build/vs
'
,
'
vscode
'
:
'
empty:
'
'
vscode
'
:
'
empty:
'
},
},
nodeModules
:
emptyPaths
||
[]
amdModulesPattern
:
/^vs
\/
/
};
};
result
[
'
vs/css
'
]
=
{
inlineResources
:
true
};
result
[
'
vs/css
'
]
=
{
inlineResources
:
true
};
return
result
;
return
result
;
...
...
build/lib/optimize.ts
浏览文件 @
bb95f3aa
...
@@ -32,13 +32,13 @@ function log(prefix: string, message: string): void {
...
@@ -32,13 +32,13 @@ function log(prefix: string, message: string): void {
fancyLog
(
ansiColors
.
cyan
(
'
[
'
+
prefix
+
'
]
'
),
message
);
fancyLog
(
ansiColors
.
cyan
(
'
[
'
+
prefix
+
'
]
'
),
message
);
}
}
export
function
loaderConfig
(
emptyPaths
?:
string
[]
)
{
export
function
loaderConfig
()
{
const
result
:
any
=
{
const
result
:
any
=
{
paths
:
{
paths
:
{
'
vs
'
:
'
out-build/vs
'
,
'
vs
'
:
'
out-build/vs
'
,
'
vscode
'
:
'
empty:
'
'
vscode
'
:
'
empty:
'
},
},
nodeModules
:
emptyPaths
||
[]
amdModulesPattern
:
/^vs
\/
/
};
};
result
[
'
vs/css
'
]
=
{
inlineResources
:
true
};
result
[
'
vs/css
'
]
=
{
inlineResources
:
true
};
...
...
src/bootstrap-window.js
浏览文件 @
bb95f3aa
...
@@ -87,7 +87,7 @@
...
@@ -87,7 +87,7 @@
const
loaderConfig
=
{
const
loaderConfig
=
{
baseUrl
:
`
${
bootstrap
.
uriFromPath
(
configuration
.
appRoot
)}
/out`
,
baseUrl
:
`
${
bootstrap
.
uriFromPath
(
configuration
.
appRoot
)}
/out`
,
'
vs/nls
'
:
nlsConfig
,
'
vs/nls
'
:
nlsConfig
,
nodeModules
:
[
/*BUILD->INSERT_NODE_MODULES*/
]
amdModulesPattern
:
/^vs
\/
/
,
};
};
// cached data config
// cached data config
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录