Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
xxadev
vscode
提交
172a32d5
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,发现更多精彩内容 >>
未验证
提交
172a32d5
编写于
4月 09, 2019
作者:
K
Keyi Xie
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
fix mispell
上级
56f1b479
变更
5
隐藏空白更改
内联
并排
Showing
5 changed file
with
9 addition
and
9 deletion
+9
-9
build/lib/i18n.ts
build/lib/i18n.ts
+2
-2
build/lib/task.js
build/lib/task.js
+1
-1
build/lib/task.ts
build/lib/task.ts
+2
-2
build/npm/update-localization-extension.js
build/npm/update-localization-extension.js
+2
-2
build/tsconfig.json
build/tsconfig.json
+2
-2
未找到文件。
build/lib/i18n.ts
浏览文件 @
172a32d5
...
@@ -24,7 +24,7 @@ function log(message: any, ...rest: any[]): void {
...
@@ -24,7 +24,7 @@ function log(message: any, ...rest: any[]): void {
}
}
export
interface
Language
{
export
interface
Language
{
id
:
string
;
// laguage id, e.g. zh-tw, de
id
:
string
;
// la
n
guage id, e.g. zh-tw, de
translationId
?:
string
;
// language id used in translation tools, e.g zh-hant, de (optional, if not set, the id is used)
translationId
?:
string
;
// language id used in translation tools, e.g zh-hant, de (optional, if not set, the id is used)
folderName
?:
string
;
// language specific folder name, e.g. cht, deu (optional, if not set, the id is used)
folderName
?:
string
;
// language specific folder name, e.g. cht, deu (optional, if not set, the id is used)
}
}
...
@@ -1370,4 +1370,4 @@ function decodeEntities(value: string): string {
...
@@ -1370,4 +1370,4 @@ function decodeEntities(value: string): string {
function
pseudify
(
message
:
string
)
{
function
pseudify
(
message
:
string
)
{
return
'
\
uFF3B
'
+
message
.
replace
(
/
[
aouei
]
/g
,
'
$&$&
'
)
+
'
\
uFF3D
'
;
return
'
\
uFF3B
'
+
message
.
replace
(
/
[
aouei
]
/g
,
'
$&$&
'
)
+
'
\
uFF3D
'
;
}
}
\ No newline at end of file
build/lib/task.js
浏览文件 @
172a32d5
...
@@ -32,7 +32,7 @@ async function _doExecute(task) {
...
@@ -32,7 +32,7 @@ async function _doExecute(task) {
// Always invoke as if it were a callback task
// Always invoke as if it were a callback task
return
new
Promise
((
resolve
,
reject
)
=>
{
return
new
Promise
((
resolve
,
reject
)
=>
{
if
(
task
.
length
===
1
)
{
if
(
task
.
length
===
1
)
{
// this is a calback task
// this is a cal
l
back task
task
((
err
)
=>
{
task
((
err
)
=>
{
if
(
err
)
{
if
(
err
)
{
return
reject
(
err
);
return
reject
(
err
);
...
...
build/lib/task.ts
浏览文件 @
172a32d5
...
@@ -54,7 +54,7 @@ async function _doExecute(task: Task): Promise<void> {
...
@@ -54,7 +54,7 @@ async function _doExecute(task: Task): Promise<void> {
// Always invoke as if it were a callback task
// Always invoke as if it were a callback task
return
new
Promise
((
resolve
,
reject
)
=>
{
return
new
Promise
((
resolve
,
reject
)
=>
{
if
(
task
.
length
===
1
)
{
if
(
task
.
length
===
1
)
{
// this is a calback task
// this is a cal
l
back task
task
((
err
)
=>
{
task
((
err
)
=>
{
if
(
err
)
{
if
(
err
)
{
return
reject
(
err
);
return
reject
(
err
);
...
@@ -122,4 +122,4 @@ export function define(name: string, task: Task): Task {
...
@@ -122,4 +122,4 @@ export function define(name: string, task: Task): Task {
task
.
taskName
=
name
;
task
.
taskName
=
name
;
task
.
displayName
=
name
;
task
.
displayName
=
name
;
return
task
;
return
task
;
}
}
\ No newline at end of file
build/npm/update-localization-extension.js
浏览文件 @
172a32d5
...
@@ -74,7 +74,7 @@ function update(options) {
...
@@ -74,7 +74,7 @@ function update(options) {
let
translationPaths
=
[];
let
translationPaths
=
[];
i18n
.
pullI18nPackFiles
(
server
,
userName
,
apiToken
,
{
id
:
languageId
},
translationPaths
)
i18n
.
pullI18nPackFiles
(
server
,
userName
,
apiToken
,
{
id
:
languageId
},
translationPaths
)
.
on
(
'
error
'
,
(
error
)
=>
{
.
on
(
'
error
'
,
(
error
)
=>
{
console
.
log
(
`Error occured while importing translations:`
);
console
.
log
(
`Error occur
r
ed while importing translations:`
);
translationPaths
=
undefined
;
translationPaths
=
undefined
;
if
(
Array
.
isArray
(
error
))
{
if
(
Array
.
isArray
(
error
))
{
error
.
forEach
(
console
.
log
);
error
.
forEach
(
console
.
log
);
...
@@ -100,7 +100,7 @@ function update(options) {
...
@@ -100,7 +100,7 @@ function update(options) {
gulp
.
src
(
path
.
join
(
location
,
languageId
,
'
**
'
,
'
*.xlf
'
))
gulp
.
src
(
path
.
join
(
location
,
languageId
,
'
**
'
,
'
*.xlf
'
))
.
pipe
(
i18n
.
prepareI18nPackFiles
(
i18n
.
externalExtensionsWithTranslations
,
translationPaths
,
languageId
===
'
ps
'
))
.
pipe
(
i18n
.
prepareI18nPackFiles
(
i18n
.
externalExtensionsWithTranslations
,
translationPaths
,
languageId
===
'
ps
'
))
.
on
(
'
error
'
,
(
error
)
=>
{
.
on
(
'
error
'
,
(
error
)
=>
{
console
.
log
(
`Error occured while importing translations:`
);
console
.
log
(
`Error occur
r
ed while importing translations:`
);
translationPaths
=
undefined
;
translationPaths
=
undefined
;
if
(
Array
.
isArray
(
error
))
{
if
(
Array
.
isArray
(
error
))
{
error
.
forEach
(
console
.
log
);
error
.
forEach
(
console
.
log
);
...
...
build/tsconfig.json
浏览文件 @
172a32d5
...
@@ -8,7 +8,7 @@
...
@@ -8,7 +8,7 @@
"resolveJsonModule"
:
true
,
"resolveJsonModule"
:
true
,
"experimentalDecorators"
:
true
,
"experimentalDecorators"
:
true
,
//
enable
JavaScript
type
checking
for
the
language
service
//
enable
JavaScript
type
checking
for
the
language
service
//
use
the
tsconfig.build.json
for
compiling
wich
disable
JavaScript
//
use
the
tsconfig.build.json
for
compiling
w
h
ich
disable
JavaScript
//
type
checking
so
that
JavaScript
file
are
not
transpiled
//
type
checking
so
that
JavaScript
file
are
not
transpiled
"allowJs"
:
true
,
"allowJs"
:
true
,
"checkJs"
:
true
,
"checkJs"
:
true
,
...
@@ -22,4 +22,4 @@
...
@@ -22,4 +22,4 @@
"exclude"
:
[
"exclude"
:
[
"node_modules/**"
"node_modules/**"
]
]
}
}
\ No newline at end of file
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录