Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
掘金者说
vscode
提交
5fca20a9
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,发现更多精彩内容 >>
提交
5fca20a9
编写于
4月 10, 2018
作者:
B
Benjamin Pasero
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
💄
symbols upload
上级
609c4ba1
变更
4
隐藏空白更改
内联
并排
Showing
4 changed file
with
28 addition
and
24 deletion
+28
-24
build/lib/compilation.js
build/lib/compilation.js
+1
-1
build/lib/i18n.js
build/lib/i18n.js
+1
-1
build/lib/nls.js
build/lib/nls.js
+0
-3
build/tfs/common/symbols.ts
build/tfs/common/symbols.ts
+26
-19
未找到文件。
build/lib/compilation.js
浏览文件 @
5fca20a9
...
...
@@ -22,7 +22,7 @@ var rootDir = path.join(__dirname, '../../src');
var
options
=
require
(
'
../../src/tsconfig.json
'
).
compilerOptions
;
options
.
verbose
=
false
;
options
.
sourceMap
=
true
;
if
(
process
.
env
[
'
VSCODE_NO_SOURCEMAP
'
])
{
// To be used by developers in a hurry
if
(
process
.
env
[
'
VSCODE_NO_SOURCEMAP
'
])
{
options
.
sourceMap
=
false
;
}
options
.
rootDir
=
rootDir
;
...
...
build/lib/i18n.js
浏览文件 @
5fca20a9
...
...
@@ -1083,7 +1083,7 @@ function prepareI18nPackFiles(externalExtensions, resultingTranslationPaths, pse
extPack
=
extensionsPacks
[
resource
]
=
{
version
:
i18nPackVersion
,
contents
:
{}
};
}
var
externalId
=
externalExtensions
[
resource
];
if
(
!
externalId
)
{
// internal extension: remove 'extensions/extensionId/' segnent
if
(
!
externalId
)
{
var
secondSlash
=
path
.
indexOf
(
'
/
'
,
firstSlash
+
1
);
extPack
.
contents
[
path
.
substr
(
secondSlash
+
1
)]
=
file
.
messages
;
}
...
...
build/lib/nls.js
浏览文件 @
5fca20a9
...
...
@@ -150,16 +150,13 @@ function isImportNode(node) {
.
filter
(
function
(
d
)
{
return
d
.
importClause
.
namedBindings
.
kind
===
ts
.
SyntaxKind
.
NamespaceImport
;
})
.
map
(
function
(
d
)
{
return
d
.
importClause
.
namedBindings
.
name
;
})
.
concat
(
importEqualsDeclarations
.
map
(
function
(
d
)
{
return
d
.
name
;
}))
// find read-only references to `nls`
.
map
(
function
(
n
)
{
return
service
.
getReferencesAtPosition
(
filename
,
n
.
pos
+
1
);
})
.
flatten
()
.
filter
(
function
(
r
)
{
return
!
r
.
isWriteAccess
;
})
// find the deepest call expressions AST nodes that contain those references
.
map
(
function
(
r
)
{
return
collect
(
sourceFile
,
function
(
n
)
{
return
isCallExpressionWithinTextSpanCollectStep
(
r
.
textSpan
,
n
);
});
})
.
map
(
function
(
a
)
{
return
lazy
(
a
).
last
();
})
.
filter
(
function
(
n
)
{
return
!!
n
;
})
.
map
(
function
(
n
)
{
return
n
;
})
// only `localize` calls
.
filter
(
function
(
n
)
{
return
n
.
expression
.
kind
===
ts
.
SyntaxKind
.
PropertyAccessExpression
&&
n
.
expression
.
name
.
getText
()
===
'
localize
'
;
});
// `localize` named imports
var
allLocalizeImportDeclarations
=
importDeclarations
...
...
build/tfs/common/symbols.ts
浏览文件 @
5fca20a9
...
...
@@ -136,6 +136,7 @@ async function downloadAsset(repository, assetName: string, targetPath: string,
}
interface
IOptions
{
repository
:
string
;
platform
:
Platform
;
versions
:
{
code
:
string
;
insiders
:
boolean
;
electron
:
string
;
};
access
:
{
hockeyAppToken
:
string
;
hockeyAppId
:
string
;
githubToken
:
string
};
...
...
@@ -147,7 +148,7 @@ async function ensureVersionAndSymbols(options: IOptions) {
console
.
log
(
`HockeyApp: checking for existing version
${
options
.
versions
.
code
}
(
${
options
.
platform
}
)`
);
const
versions
=
await
getVersions
({
accessToken
:
options
.
access
.
hockeyAppToken
,
appId
:
options
.
access
.
hockeyAppId
});
if
(
versions
.
app_versions
.
some
(
v
=>
v
.
version
===
options
.
versions
.
code
))
{
console
.
log
(
`Returning without uploading symbols because version
${
options
.
versions
.
code
}
(
${
options
.
platform
}
) was already found`
);
console
.
log
(
`
HockeyApp:
Returning without uploading symbols because version
${
options
.
versions
.
code
}
(
${
options
.
platform
}
) was already found`
);
return
;
}
...
...
@@ -155,7 +156,7 @@ async function ensureVersionAndSymbols(options: IOptions) {
const
symbolsName
=
symbolsZipName
(
options
.
platform
,
options
.
versions
.
electron
,
options
.
versions
.
insiders
);
const
symbolsPath
=
await
tmpFile
(
'
symbols.zip
'
);
console
.
log
(
`HockeyApp: downloading symbols
${
symbolsName
}
for electron
${
options
.
versions
.
electron
}
(
${
options
.
platform
}
) into
${
symbolsPath
}
`
);
await
downloadAsset
(
new
github
({
repo
:
'
Microsoft/vscode-electron-prebuilt
'
,
token
:
options
.
access
.
githubToken
}),
symbolsName
,
symbolsPath
,
options
.
versions
.
electron
);
await
downloadAsset
(
new
github
({
repo
:
options
.
repository
,
token
:
options
.
access
.
githubToken
}),
symbolsName
,
symbolsPath
,
options
.
versions
.
electron
);
// Create version
console
.
log
(
`HockeyApp: creating new version
${
options
.
versions
.
code
}
(
${
options
.
platform
}
)`
);
...
...
@@ -172,6 +173,7 @@ async function ensureVersionAndSymbols(options: IOptions) {
// Environment
const
pakage
=
require
(
'
../../../package.json
'
);
const
product
=
require
(
'
../../../product.json
'
);
const
repository
=
product
.
electronRepository
;
const
codeVersion
=
pakage
.
version
;
const
electronVersion
=
require
(
'
../../lib/electron
'
).
getElectronVersion
();
const
insiders
=
product
.
quality
!==
'
stable
'
;
...
...
@@ -190,20 +192,25 @@ if (process.platform === 'darwin') {
}
// Create version and upload symbols in HockeyApp
ensureVersionAndSymbols
({
platform
,
versions
:
{
code
:
codeVersion
,
insiders
,
electron
:
electronVersion
},
access
:
{
githubToken
,
hockeyAppToken
,
hockeyAppId
}
}).
then
(()
=>
{
console
.
log
(
'
HockeyApp: done
'
);
},
error
=>
{
console
.
error
(
`HockeyApp: error (
${
error
}
)`
);
});
\ No newline at end of file
if
(
repository
&&
codeVersion
&&
electronVersion
)
{
ensureVersionAndSymbols
({
repository
,
platform
,
versions
:
{
code
:
codeVersion
,
insiders
,
electron
:
electronVersion
},
access
:
{
githubToken
,
hockeyAppToken
,
hockeyAppId
}
}).
then
(()
=>
{
console
.
log
(
'
HockeyApp: done
'
);
},
error
=>
{
console
.
error
(
`HockeyApp: error (
${
error
}
)`
);
});
}
else
{
console
.
log
(
`HockeyApp: skipping due to insufficient context (repository:
${
repository
}
, codeVersion:
${
codeVersion
}
, electronVersion:
${
electronVersion
}
)`
);
}
\ No newline at end of file
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录