Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
xxadev
vscode
提交
dc2365d6
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,体验更适合开发者的 AI 搜索 >>
未验证
提交
dc2365d6
编写于
1月 08, 2021
作者:
J
João Moreno
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
wip
上级
a36fd18e
变更
19
显示空白变更内容
内联
并排
Showing
19 changed file
with
280 addition
and
110 deletion
+280
-110
.vscode/launch.json
.vscode/launch.json
+9
-0
build/esbuild.js
build/esbuild.js
+69
-0
build/esbuild.ts
build/esbuild.ts
+72
-0
src/bootstrap-window.js
src/bootstrap-window.js
+61
-61
src/main.js
src/main.js
+4
-3
src/vs/base/common/insane/insane.js
src/vs/base/common/insane/insane.js
+2
-2
src/vs/base/common/network.ts
src/vs/base/common/network.ts
+4
-1
src/vs/base/common/performance.js
src/vs/base/common/performance.js
+10
-10
src/vs/base/node/languagePacks.js
src/vs/base/node/languagePacks.js
+7
-7
src/vs/base/node/paths.ts
src/vs/base/node/paths.ts
+4
-3
src/vs/code/electron-browser/workbench/workbench.html
src/vs/code/electron-browser/workbench/workbench.html
+1
-1
src/vs/code/electron-main/window.ts
src/vs/code/electron-main/window.ts
+3
-2
src/vs/code/electron-sandbox/workbench/workbench.html
src/vs/code/electron-sandbox/workbench/workbench.html
+16
-12
src/vs/dummyloader.js
src/vs/dummyloader.js
+5
-0
src/vs/nls.js
src/vs/nls.js
+2
-0
src/vs/platform/environment/node/argv.ts
src/vs/platform/environment/node/argv.ts
+1
-1
src/vs/platform/instantiation/common/instantiation.ts
src/vs/platform/instantiation/common/instantiation.ts
+1
-1
src/vs/platform/product/common/product.ts
src/vs/platform/product/common/product.ts
+6
-3
src/vs/workbench/electron-browser/desktop.main.ts
src/vs/workbench/electron-browser/desktop.main.ts
+3
-3
未找到文件。
.vscode/launch.json
浏览文件 @
dc2365d6
...
@@ -192,6 +192,15 @@
...
@@ -192,6 +192,15 @@
"order"
:
6
"order"
:
6
}
}
},
},
{
"name"
:
"Attach"
,
"port"
:
9229
,
"request"
:
"attach"
,
"skipFiles"
:
[
"<node_internals>/**"
],
"type"
:
"pwa-node"
},
{
{
"type"
:
"pwa-chrome"
,
"type"
:
"pwa-chrome"
,
"request"
:
"attach"
,
"request"
:
"attach"
,
...
...
build/esbuild.js
0 → 100644
浏览文件 @
dc2365d6
"
use strict
"
;
/*---------------------------------------------------------------------------------------------
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
Object
.
defineProperty
(
exports
,
"
__esModule
"
,
{
value
:
true
});
const
esbuild
=
require
(
"
esbuild
"
);
const
buildfile
=
require
(
"
../src/buildfile
"
);
const
_
=
require
(
"
underscore
"
);
const
pkg
=
require
(
"
../package.json
"
);
const
dependencies
=
Object
.
keys
(
pkg
.
dependencies
);
const
entryPoints
=
_
.
flatten
([
buildfile
.
entrypoint
(
'
vs/workbench/workbench.desktop.main
'
),
buildfile
.
base
,
buildfile
.
workerExtensionHost
,
buildfile
.
workerNotebook
,
buildfile
.
workbenchDesktop
,
buildfile
.
code
]).
map
(
entrypoint
=>
`src/
${
entrypoint
.
name
}
.ts`
);
async
function
main
()
{
await
esbuild
.
build
({
entryPoints
:
[
...
entryPoints
,
'
src/main.js
'
,
'
src/vs/base/parts/sandbox/electron-browser/preload.js
'
,
'
src/vs/code/electron-sandbox/workbench/workbench.html
'
],
outdir
:
'
out
'
,
outbase
:
'
src
'
,
// format: 'iife',
platform
:
'
node
'
,
target
:
'
node12.18
'
,
bundle
:
true
,
tsconfig
:
'
src/tsconfig.json
'
,
logLevel
:
'
info
'
,
sourcemap
:
true
,
// minify: true,
loader
:
{
'
.png
'
:
'
file
'
,
'
.ttf
'
:
'
file
'
,
'
.svg
'
:
'
file
'
,
'
.html
'
:
'
file
'
},
inject
:
[
'
src/vs/dummyloader.js
'
],
external
:
[
...
dependencies
,
'
vs/css!*
'
,
// 'vs/nls',
'
*/sqlite
'
,
'
electron*
'
,
'
vscode-windows-registry
'
,
'
windows-process-tree
'
,
'
windows-mutex
'
,
'
windows-foreground-love
'
,
'
vscode-windows-ca-certs
'
,
'
*.node
'
,
'
*keymapping
'
,
'
*pty.node
'
]
});
}
if
(
require
.
main
===
module
)
{
main
().
catch
(
err
=>
{
// console.error(err);
process
.
exit
(
1
);
});
}
build/esbuild.ts
0 → 100644
浏览文件 @
dc2365d6
/*---------------------------------------------------------------------------------------------
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import
*
as
esbuild
from
'
esbuild
'
;
import
*
as
buildfile
from
'
../src/buildfile
'
;
import
*
as
_
from
'
underscore
'
;
import
*
as
pkg
from
'
../package.json
'
;
const
dependencies
=
Object
.
keys
(
pkg
.
dependencies
);
const
entryPoints
=
_
.
flatten
([
buildfile
.
entrypoint
(
'
vs/workbench/workbench.desktop.main
'
),
buildfile
.
base
,
buildfile
.
workerExtensionHost
,
buildfile
.
workerNotebook
,
buildfile
.
workbenchDesktop
,
buildfile
.
code
]).
map
(
entrypoint
=>
`src/
${
entrypoint
.
name
}
.ts`
);
async
function
main
()
{
await
esbuild
.
build
({
entryPoints
:
[
...
entryPoints
,
'
src/main.js
'
,
'
src/vs/base/parts/sandbox/electron-browser/preload.js
'
,
'
src/vs/code/electron-sandbox/workbench/workbench.html
'
],
outdir
:
'
out
'
,
outbase
:
'
src
'
,
// format: 'iife',
platform
:
'
node
'
,
target
:
'
node12.18
'
,
bundle
:
true
,
tsconfig
:
'
src/tsconfig.json
'
,
logLevel
:
'
info
'
,
sourcemap
:
true
,
// minify: true,
loader
:
{
'
.png
'
:
'
file
'
,
'
.ttf
'
:
'
file
'
,
'
.svg
'
:
'
file
'
,
'
.html
'
:
'
file
'
},
inject
:
[
'
src/vs/dummyloader.js
'
],
external
:
[
...
dependencies
,
'
vs/css!*
'
,
// 'vs/nls',
'
*/sqlite
'
,
'
electron*
'
,
'
vscode-windows-registry
'
,
'
windows-process-tree
'
,
'
windows-mutex
'
,
'
windows-foreground-love
'
,
'
vscode-windows-ca-certs
'
,
'
*.node
'
,
'
*keymapping
'
,
'
*pty.node
'
]
});
}
if
(
require
.
main
===
module
)
{
main
().
catch
(
err
=>
{
// console.error(err);
process
.
exit
(
1
);
});
}
src/bootstrap-window.js
浏览文件 @
dc2365d6
...
@@ -84,7 +84,7 @@
...
@@ -84,7 +84,7 @@
// replace the patched electron fs with the original node fs for all AMD code (TODO@sandbox non-sandboxed only)
// replace the patched electron fs with the original node fs for all AMD code (TODO@sandbox non-sandboxed only)
if
(
!
sandbox
)
{
if
(
!
sandbox
)
{
require
.
define
(
'
fs
'
,
[],
function
()
{
return
require
.
__$__nodeRequire
(
'
original-fs
'
);
});
//
require.define('fs', [], function () { return require.__$__nodeRequire('original-fs'); });
}
}
window
[
'
MonacoEnvironment
'
]
=
{};
window
[
'
MonacoEnvironment
'
]
=
{};
...
@@ -93,66 +93,66 @@
...
@@ -93,66 +93,66 @@
`
${
bootstrapLib
.
fileUriFromPath
(
configuration
.
appRoot
,
{
isWindows
:
safeProcess
.
platform
===
'
win32
'
,
scheme
:
'
vscode-file
'
,
fallbackAuthority
:
'
vscode-app
'
})}
/out`
:
`
${
bootstrapLib
.
fileUriFromPath
(
configuration
.
appRoot
,
{
isWindows
:
safeProcess
.
platform
===
'
win32
'
,
scheme
:
'
vscode-file
'
,
fallbackAuthority
:
'
vscode-app
'
})}
/out`
:
`
${
bootstrapLib
.
fileUriFromPath
(
configuration
.
appRoot
,
{
isWindows
:
safeProcess
.
platform
===
'
win32
'
})}
/out`
;
`
${
bootstrapLib
.
fileUriFromPath
(
configuration
.
appRoot
,
{
isWindows
:
safeProcess
.
platform
===
'
win32
'
})}
/out`
;
const
loaderConfig
=
{
//
const loaderConfig = {
baseUrl
,
//
baseUrl,
'
vs/nls
'
:
nlsConfig
,
//
'vs/nls': nlsConfig,
preferScriptTags
:
useCustomProtocol
//
preferScriptTags: useCustomProtocol
};
//
};
// use a trusted types policy when loading via script tags
//
//
use a trusted types policy when loading via script tags
if
(
loaderConfig
.
preferScriptTags
)
{
//
if (loaderConfig.preferScriptTags) {
loaderConfig
.
trustedTypesPolicy
=
window
.
trustedTypes
?.
createPolicy
(
'
amdLoader
'
,
{
//
loaderConfig.trustedTypesPolicy = window.trustedTypes?.createPolicy('amdLoader', {
createScriptURL
(
value
)
{
//
createScriptURL(value) {
if
(
value
.
startsWith
(
window
.
location
.
origin
))
{
//
if (value.startsWith(window.location.origin)) {
return
value
;
//
return value;
}
//
}
throw
new
Error
(
`Invalid script url:
${
value
}
`
);
//
throw new Error(`Invalid script url: ${value}`);
}
//
}
});
//
});
}
//
}
// Enable loading of node modules:
//
//
Enable loading of node modules:
// - sandbox: we list paths of webpacked modules to help the loader
//
//
- sandbox: we list paths of webpacked modules to help the loader
// - non-sandbox: we signal that any module that does not begin with
//
//
- non-sandbox: we signal that any module that does not begin with
// `vs/` should be loaded using node.js require()
//
//
`vs/` should be loaded using node.js require()
if
(
sandbox
)
{
//
if (sandbox) {
loaderConfig
.
paths
=
{
//
loaderConfig.paths = {
'
vscode-textmate
'
:
`../node_modules/vscode-textmate/release/main`
,
//
'vscode-textmate': `../node_modules/vscode-textmate/release/main`,
'
vscode-oniguruma
'
:
`../node_modules/vscode-oniguruma/release/main`
,
//
'vscode-oniguruma': `../node_modules/vscode-oniguruma/release/main`,
'
xterm
'
:
`../node_modules/xterm/lib/xterm.js`
,
//
'xterm': `../node_modules/xterm/lib/xterm.js`,
'
xterm-addon-search
'
:
`../node_modules/xterm-addon-search/lib/xterm-addon-search.js`
,
//
'xterm-addon-search': `../node_modules/xterm-addon-search/lib/xterm-addon-search.js`,
'
xterm-addon-unicode11
'
:
`../node_modules/xterm-addon-unicode11/lib/xterm-addon-unicode11.js`
,
//
'xterm-addon-unicode11': `../node_modules/xterm-addon-unicode11/lib/xterm-addon-unicode11.js`,
'
xterm-addon-webgl
'
:
`../node_modules/xterm-addon-webgl/lib/xterm-addon-webgl.js`
,
//
'xterm-addon-webgl': `../node_modules/xterm-addon-webgl/lib/xterm-addon-webgl.js`,
'
iconv-lite-umd
'
:
`../node_modules/iconv-lite-umd/lib/iconv-lite-umd.js`
,
//
'iconv-lite-umd': `../node_modules/iconv-lite-umd/lib/iconv-lite-umd.js`,
'
jschardet
'
:
`../node_modules/jschardet/dist/jschardet.min.js`
,
//
'jschardet': `../node_modules/jschardet/dist/jschardet.min.js`,
};
//
};
}
else
{
//
} else {
loaderConfig
.
amdModulesPattern
=
/^vs
\/
/
;
//
loaderConfig.amdModulesPattern = /^vs\//;
}
//
}
// cached data config
//
//
cached data config
if
(
configuration
.
nodeCachedDataDir
)
{
//
if (configuration.nodeCachedDataDir) {
loaderConfig
.
nodeCachedData
=
{
//
loaderConfig.nodeCachedData = {
path
:
configuration
.
nodeCachedDataDir
,
//
path: configuration.nodeCachedDataDir,
seed
:
modulePaths
.
join
(
''
)
//
seed: modulePaths.join('')
};
//
};
}
//
}
if
(
options
&&
typeof
options
.
beforeLoaderConfig
===
'
function
'
)
{
//
if (options && typeof options.beforeLoaderConfig === 'function') {
options
.
beforeLoaderConfig
(
configuration
,
loaderConfig
);
//
options.beforeLoaderConfig(configuration, loaderConfig);
}
//
}
require
.
config
(
loaderConfig
);
//
require.config(loaderConfig);
if
(
nlsConfig
.
pseudo
)
{
//
if (nlsConfig.pseudo) {
require
([
'
vs/nls
'
],
function
(
nlsPlugin
)
{
//
require(['vs/nls'], function (nlsPlugin) {
nlsPlugin
.
setPseudoTranslation
(
nlsConfig
.
pseudo
);
//
nlsPlugin.setPseudoTranslation(nlsConfig.pseudo);
});
//
});
}
//
}
if
(
options
&&
typeof
options
.
beforeRequire
===
'
function
'
)
{
//
if (options && typeof options.beforeRequire === 'function') {
options
.
beforeRequire
();
//
options.beforeRequire();
}
//
}
require
(
modulePaths
,
async
result
=>
{
require
(
modulePaths
,
async
result
=>
{
try
{
try
{
...
...
src/main.js
浏览文件 @
dc2365d6
...
@@ -194,9 +194,10 @@ function startup(cachedDataDir, nlsConfig) {
...
@@ -194,9 +194,10 @@ function startup(cachedDataDir, nlsConfig) {
// Load main in AMD
// Load main in AMD
perf
.
mark
(
'
code/willLoadMainBundle
'
);
perf
.
mark
(
'
code/willLoadMainBundle
'
);
require
(
'
./bootstrap-amd
'
).
load
(
'
vs/code/electron-main/main
'
,
()
=>
{
require
(
'
./vs/code/electron-main/main
'
);
// require('./bootstrap-amd').load('vs/code/electron-main/main', () => {
perf
.
mark
(
'
code/didLoadMainBundle
'
);
perf
.
mark
(
'
code/didLoadMainBundle
'
);
});
//
});
}
}
async
function
onReady
()
{
async
function
onReady
()
{
...
...
src/vs/base/common/insane/insane.js
浏览文件 @
dc2365d6
...
@@ -466,9 +466,9 @@ let __insane_func;
...
@@ -466,9 +466,9 @@ let __insane_func;
},
{},
[
4
]);
},
{},
[
4
]);
// ESM-comment-begin
// ESM-comment-begin
define
(
function
()
{
return
{
insane
:
__insane_func
};
});
// define(function
() { return { insane: __insane_func }; });
// ESM-comment-end
// ESM-comment-end
// ESM-uncomment-begin
// ESM-uncomment-begin
//
export var insane = __insane_func;
export
var
insane
=
__insane_func
;
// ESM-uncomment-end
// ESM-uncomment-end
src/vs/base/common/network.ts
浏览文件 @
dc2365d6
...
@@ -204,7 +204,10 @@ class FileAccessImpl {
...
@@ -204,7 +204,10 @@ class FileAccessImpl {
return
uriOrModule
;
return
uriOrModule
;
}
}
return
URI
.
parse
(
moduleIdToUrl
!
.
toUrl
(
uriOrModule
));
console
.
log
(
uriOrModule
);
return
URI
.
parse
(
`file:///home/joao/Work/vscode/out/
${
uriOrModule
}
`
);
// return URI.parse(moduleIdToUrl!.toUrl(uriOrModule));
}
}
}
}
...
...
src/vs/base/common/performance.js
浏览文件 @
dc2365d6
...
@@ -107,13 +107,13 @@ if (typeof global === 'object') {
...
@@ -107,13 +107,13 @@ if (typeof global === 'object') {
sharedObj
=
{};
sharedObj
=
{};
}
}
if
(
typeof
define
===
'
function
'
)
{
//
if (typeof define === 'function') {
// amd
//
// amd
define
([],
function
()
{
return
_factory
(
sharedObj
);
});
//
define([], function () { return _factory(sharedObj); });
}
else
if
(
typeof
module
===
'
object
'
&&
typeof
module
.
exports
===
'
object
'
)
{
//
} else if (typeof module === 'object' && typeof module.exports === 'object') {
// commonjs
// commonjs
module
.
exports
=
_factory
(
sharedObj
);
module
.
exports
=
_factory
(
sharedObj
);
}
else
{
//
} else {
console
.
trace
(
'
perf-util defined in UNKNOWN context (neither requirejs or commonjs)
'
);
//
console.trace('perf-util defined in UNKNOWN context (neither requirejs or commonjs)');
sharedObj
.
perf
=
_factory
(
sharedObj
);
//
sharedObj.perf = _factory(sharedObj);
}
//
}
src/vs/base/node/languagePacks.js
浏览文件 @
dc2365d6
...
@@ -301,14 +301,14 @@ function factory(nodeRequire, path, fs, perf) {
...
@@ -301,14 +301,14 @@ function factory(nodeRequire, path, fs, perf) {
}
}
if
(
typeof
define
===
'
function
'
)
{
//
if (typeof define === 'function') {
// amd
//
// amd
define
([
'
path
'
,
'
fs
'
,
'
vs/base/common/performance
'
],
function
(
path
,
fs
,
perf
)
{
return
factory
(
require
.
__$__nodeRequire
,
path
,
fs
,
perf
);
});
//
define(['path', 'fs', 'vs/base/common/performance'], function (path, fs, perf) { return factory(require.__$__nodeRequire, path, fs, perf); });
}
else
if
(
typeof
module
===
'
object
'
&&
typeof
module
.
exports
===
'
object
'
)
{
//
} else if (typeof module === 'object' && typeof module.exports === 'object') {
const
path
=
require
(
'
path
'
);
const
path
=
require
(
'
path
'
);
const
fs
=
require
(
'
fs
'
);
const
fs
=
require
(
'
fs
'
);
const
perf
=
require
(
'
../common/performance
'
);
const
perf
=
require
(
'
../common/performance
'
);
module
.
exports
=
factory
(
require
,
path
,
fs
,
perf
);
module
.
exports
=
factory
(
require
,
path
,
fs
,
perf
);
}
else
{
//
} else {
throw
new
Error
(
'
Unknown context
'
);
//
throw new Error('Unknown context');
}
//
}
src/vs/base/node/paths.ts
浏览文件 @
dc2365d6
...
@@ -3,9 +3,10 @@
...
@@ -3,9 +3,10 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
*--------------------------------------------------------------------------------------------*/
import
{
FileAccess
}
from
'
vs/base/common/network
'
;
//
import { FileAccess } from 'vs/base/common/network';
const
pathsPath
=
FileAccess
.
asFileUri
(
'
paths
'
,
require
).
fsPath
;
// const pathsPath = FileAccess.asFileUri('paths', require).fsPath;
const
paths
=
require
.
__$__nodeRequire
<
{
getDefaultUserDataPath
():
string
}
>
(
pathsPath
);
// const paths = require.__$__nodeRequire<{ getDefaultUserDataPath(): string }>(pathsPath);
const
paths
=
require
(
'
../../../paths.js
'
);
export
const
getDefaultUserDataPath
=
paths
.
getDefaultUserDataPath
;
export
const
getDefaultUserDataPath
=
paths
.
getDefaultUserDataPath
;
src/vs/code/electron-browser/workbench/workbench.html
浏览文件 @
dc2365d6
...
@@ -11,7 +11,7 @@
...
@@ -11,7 +11,7 @@
<!-- Init Bootstrap Helpers -->
<!-- Init Bootstrap Helpers -->
<script
src=
"../../../../bootstrap.js"
></script>
<script
src=
"../../../../bootstrap.js"
></script>
<
script
src=
"../../../../vs/loader.js"
></script
>
<
!-- <script src="../../../../vs/loader.js"></script> --
>
<script
src=
"../../../../bootstrap-window.js"
></script>
<script
src=
"../../../../bootstrap-window.js"
></script>
<!-- Startup via workbench.js -->
<!-- Startup via workbench.js -->
...
...
src/vs/code/electron-main/window.ts
浏览文件 @
dc2365d6
...
@@ -856,8 +856,9 @@ export class CodeWindow extends Disposable implements ICodeWindow {
...
@@ -856,8 +856,9 @@ export class CodeWindow extends Disposable implements ICodeWindow {
workbench
=
'
vs/code/electron-browser/workbench/workbench.html
'
;
workbench
=
'
vs/code/electron-browser/workbench/workbench.html
'
;
}
}
return
FileAccess
// return FileAccess
.
asBrowserUri
(
workbench
,
require
)
// .asBrowserUri(workbench, require)
return
URI
.
file
(
`/home/joao/Work/vscode/src/
${
workbench
}
`
)
.
with
({
query
:
`config=
${
encodeURIComponent
(
JSON
.
stringify
(
config
))}
`
})
.
with
({
query
:
`config=
${
encodeURIComponent
(
JSON
.
stringify
(
config
))}
`
})
.
toString
(
true
);
.
toString
(
true
);
}
}
...
...
src/vs/code/electron-sandbox/workbench/workbench.html
浏览文件 @
dc2365d6
<!-- Copyright (C) Microsoft Corporation. All rights reserved. -->
<!-- Copyright (C) Microsoft Corporation. All rights reserved. -->
<!DOCTYPE html>
<!DOCTYPE html>
<html>
<html>
<head>
<head>
<meta
charset=
"utf-8"
/>
<meta
charset=
"utf-8"
/>
<meta
http-equiv=
"Content-Security-Policy"
content=
"default-src 'none'; img-src 'self' https: data: blob: vscode-remote-resource:; media-src 'none'; frame-src 'self' vscode-webview: https://*.vscode-webview-test.com; object-src 'self'; script-src 'self' 'unsafe-eval'; style-src 'self' 'unsafe-inline'; connect-src 'self' https:; font-src 'self' https: vscode-remote-resource:;"
>
<meta
http-equiv=
"Content-Security-Policy"
</head>
content=
"default-src 'none'; img-src 'self' https: data: blob: vscode-remote-resource:; media-src 'none'; frame-src 'self' vscode-webview: https://*.vscode-webview-test.com; object-src 'self'; script-src 'self' 'unsafe-eval'; style-src 'self' 'unsafe-inline'; connect-src 'self' https:; font-src 'self' https: vscode-remote-resource:;"
>
<body
aria-label=
""
>
</head>
</body>
<body
aria-label=
""
>
</body>
<!-- Init Bootstrap Helpers -->
<script
src=
"../../../../bootstrap.js"
></script>
<!-- <script src="../../../../vs/loader.js"></script> -->
<script
src=
"../../../../bootstrap-window.js"
></script>
<!-- Init Bootstrap Helpers -->
<!-- Startup via workbench.js -->
<script
src=
"../../../../bootstrap.js"
></script>
<script
src=
"workbench.js"
></script>
<script
src=
"../../../../vs/loader.js"
></script>
<script
src=
"../../../../bootstrap-window.js"
></script>
<!-- Startup via workbench.js -->
<script
src=
"workbench.js"
></script>
</html>
</html>
src/vs/dummyloader.js
0 → 100644
浏览文件 @
dc2365d6
export
function
define
()
{
}
require
.
__$__nodeRequire
=
()
=>
{
}
src/vs/nls.js
浏览文件 @
dc2365d6
...
@@ -158,3 +158,5 @@ var NLSLoaderPlugin;
...
@@ -158,3 +158,5 @@ var NLSLoaderPlugin;
NLSLoaderPlugin
.
NLSPlugin
=
NLSPlugin
;
NLSLoaderPlugin
.
NLSPlugin
=
NLSPlugin
;
define
(
'
vs/nls
'
,
new
NLSPlugin
(
new
Environment
()));
define
(
'
vs/nls
'
,
new
NLSPlugin
(
new
Environment
()));
})(
NLSLoaderPlugin
||
(
NLSLoaderPlugin
=
{}));
})(
NLSLoaderPlugin
||
(
NLSLoaderPlugin
=
{}));
module
.
exports
.
localize
=
(
_
,
msg
)
=>
msg
;
src/vs/platform/environment/node/argv.ts
浏览文件 @
dc2365d6
...
@@ -3,7 +3,7 @@
...
@@ -3,7 +3,7 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
*--------------------------------------------------------------------------------------------*/
import
*
as
minimist
from
'
minimist
'
;
const
minimist
=
require
(
'
minimist
'
)
;
import
{
localize
}
from
'
vs/nls
'
;
import
{
localize
}
from
'
vs/nls
'
;
import
{
isWindows
}
from
'
vs/base/common/platform
'
;
import
{
isWindows
}
from
'
vs/base/common/platform
'
;
import
{
NativeParsedArgs
}
from
'
vs/platform/environment/common/argv
'
;
import
{
NativeParsedArgs
}
from
'
vs/platform/environment/common/argv
'
;
...
...
src/vs/platform/instantiation/common/instantiation.ts
浏览文件 @
dc2365d6
...
@@ -16,7 +16,7 @@ export namespace _util {
...
@@ -16,7 +16,7 @@ export namespace _util {
export
const
DI_DEPENDENCIES
=
'
$di$dependencies
'
;
export
const
DI_DEPENDENCIES
=
'
$di$dependencies
'
;
export
function
getServiceDependencies
(
ctor
:
any
):
{
id
:
ServiceIdentifier
<
any
>
,
index
:
number
,
optional
:
boolean
}[]
{
export
function
getServiceDependencies
(
ctor
:
any
):
{
id
:
ServiceIdentifier
<
any
>
,
index
:
number
,
optional
:
boolean
}[]
{
return
ctor
[
DI_DEPENDENCIES
]
||
[];
return
ctor
.
prototype
[
DI_DEPENDENCIES
]
||
[];
}
}
}
}
...
...
src/vs/platform/product/common/product.ts
浏览文件 @
dc2365d6
...
@@ -42,10 +42,13 @@ if (isWeb || typeof require === 'undefined' || typeof require.__$__nodeRequire !
...
@@ -42,10 +42,13 @@ if (isWeb || typeof require === 'undefined' || typeof require.__$__nodeRequire !
else
{
else
{
// Obtain values from product.json and package.json
// Obtain values from product.json and package.json
const
rootPath
=
dirname
(
FileAccess
.
asFileUri
(
''
,
require
));
//
const rootPath = dirname(FileAccess.asFileUri('', require));
product
=
require
.
__$__nodeRequire
(
joinPath
(
rootPath
,
'
product.json
'
).
fsPath
);
// product = require.__$__nodeRequire(joinPath(rootPath, 'product.json').fsPath);
const
pkg
=
require
.
__$__nodeRequire
(
joinPath
(
rootPath
,
'
package.json
'
).
fsPath
)
as
{
version
:
string
;
};
// const pkg = require.__$__nodeRequire(joinPath(rootPath, 'package.json').fsPath) as { version: string; };
product
=
require
(
'
../../../../../product.json
'
);
const
pkg
=
require
(
'
../../../../../package.json
'
);
// Running out of sources
// Running out of sources
if
(
env
[
'
VSCODE_DEV
'
])
{
if
(
env
[
'
VSCODE_DEV
'
])
{
...
...
src/vs/workbench/electron-browser/desktop.main.ts
浏览文件 @
dc2365d6
...
@@ -3,8 +3,8 @@
...
@@ -3,8 +3,8 @@
* Licensed under the MIT License. See License.txt in the project root for license information.
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
*--------------------------------------------------------------------------------------------*/
import
*
as
fs
from
'
fs
'
;
//
import * as fs from 'fs';
import
*
as
gracefulFs
from
'
graceful-fs
'
;
//
import * as gracefulFs from 'graceful-fs';
import
{
createHash
}
from
'
crypto
'
;
import
{
createHash
}
from
'
crypto
'
;
import
{
exists
,
stat
}
from
'
vs/base/node/pfs
'
;
import
{
exists
,
stat
}
from
'
vs/base/node/pfs
'
;
import
{
isLinux
,
isMacintosh
,
isWindows
}
from
'
vs/base/common/platform
'
;
import
{
isLinux
,
isMacintosh
,
isWindows
}
from
'
vs/base/common/platform
'
;
...
@@ -70,7 +70,7 @@ class DesktopMain extends Disposable {
...
@@ -70,7 +70,7 @@ class DesktopMain extends Disposable {
private
init
():
void
{
private
init
():
void
{
// Enable gracefulFs
// Enable gracefulFs
gracefulFs
.
gracefulify
(
fs
);
//
gracefulFs.gracefulify(fs);
// Massage configuration file URIs
// Massage configuration file URIs
this
.
reviveUris
();
this
.
reviveUris
();
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录