Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
xxadev
vscode
提交
99ab6e8d
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,发现更多精彩内容 >>
提交
99ab6e8d
编写于
3月 08, 2017
作者:
M
Martin Aeschlimann
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
[theme] conversion script
上级
1eb82782
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
245 addition
and
2 deletion
+245
-2
build/npm/update-theme.js
build/npm/update-theme.js
+22
-1
extensions/theme-abyss/package.json
extensions/theme-abyss/package.json
+1
-1
extensions/theme-abyss/themes/abyss-color-theme.json
extensions/theme-abyss/themes/abyss-color-theme.json
+222
-0
未找到文件。
build/npm/update-theme.js
浏览文件 @
99ab6e8d
...
...
@@ -9,6 +9,11 @@ var path = require('path');
var
fs
=
require
(
'
fs
'
);
var
plist
=
require
(
'
fast-plist
'
);
var
mappings
=
{
"
ansiBlack
"
:
[
"
terminalAnsiBlack
"
],
"
ansiRed
"
:
[
"
terminalAnsiRed
"
],
"
ansiGreen
"
:
[
"
terminalAnsiGreen
"
],
"
ansiYellow
"
:
[
"
terminalAnsiYellow
"
],
"
ansiBlue
"
:
[
"
terminalAnsiBlue
"
],
"
ansiMagenta
"
:
[
"
terminalAnsiMagenta
"
],
"
ansiCyan
"
:
[
"
terminalAnsiCyan
"
],
"
ansiWhite
"
:
[
"
terminalAnsiWhite
"
],
"
ansiBrightBlack
"
:
[
"
terminalAnsiBrightBlack
"
],
"
ansiBrightRed
"
:
[
"
terminalAnsiBrightRed
"
],
"
ansiBrightGreen
"
:
[
"
terminalAnsiBrightGreen
"
],
"
ansiBrightYellow
"
:
[
"
terminalAnsiBrightYellow
"
],
"
ansiBrightBlue
"
:
[
"
terminalAnsiBrightBlue
"
],
"
ansiBrightMagenta
"
:
[
"
terminalAnsiBrightMagenta
"
],
"
ansiBrightCyan
"
:
[
"
terminalAnsiBrightCyan
"
],
"
ansiBrightWhite
"
:
[
"
terminalAnsiBrightWhite
"
],
"
background
"
:
[
"
editorBackground
"
],
"
hoverHighlight
"
:
[
"
editorHoverHighlight
"
,
"
editorHoverHighlight
"
],
"
linkForeground
"
:
[
"
editorLinkForeground
"
],
"
selection
"
:
[
"
editorSelection
"
],
"
inactiveSelection
"
:
[
"
editorInactiveSelection
"
],
"
selectionHighlightColor
"
:
[
"
editorSelectionHighlightColor
"
],
"
wordHighlight
"
:
[
"
editorWordHighlight
"
],
"
wordHighlightStrong
"
:
[
"
editorWordHighlightStrong
"
],
"
findMatchHighlight
"
:
[
"
editorFindMatchHighlight
"
,
"
referencesFindMatchHighlight
"
],
"
currentFindMatchHighlight
"
:
[
"
editorCurrentFindMatchHighlight
"
],
"
findRangeHighlight
"
:
[
"
editorFindRangeHighlight
"
],
"
referenceHighlight
"
:
[
"
referencesReferenceHighlight
"
],
"
lineHighlight
"
:
[
"
editorLineHighlight
"
],
"
rangeHighlight
"
:
[
"
editorRangeHighlight
"
],
"
caret
"
:
[
"
editorCursor
"
],
"
invisibles
"
:
[
"
editorInvisibles
"
],
"
guide
"
:
[
"
editorGuide
"
]
};
exports
.
update
=
function
(
srcName
,
destName
)
{
try
{
console
.
log
(
'
reading
'
,
srcName
);
...
...
@@ -17,6 +22,7 @@ exports.update = function (srcName, destName) {
let
theme
=
plist
.
parse
(
plistContent
);
let
settings
=
theme
.
settings
;
if
(
Array
.
isArray
(
settings
))
{
let
colorMap
=
{};
for
(
let
entry
of
settings
)
{
let
scope
=
entry
.
scope
;
if
(
scope
)
{
...
...
@@ -24,10 +30,25 @@ exports.update = function (srcName, destName) {
if
(
parts
.
length
>
1
)
{
entry
.
scope
=
parts
;
}
}
else
{
var
entrySettings
=
entry
.
settings
;
for
(
let
entry
in
entrySettings
)
{
let
mapping
=
mappings
[
entry
];
if
(
mapping
)
{
for
(
let
newKey
of
mapping
)
{
colorMap
[
newKey
]
=
entrySettings
[
entry
];
}
if
(
entry
!==
'
foreground
'
&&
entry
!==
'
background
'
)
{
delete
entrySettings
[
entry
];
}
}
}
}
}
result
.
name
=
theme
.
name
;
result
.
syntaxTokens
=
settings
;
result
.
colors
=
{}
;
result
.
colors
=
colorMap
;
}
fs
.
writeFileSync
(
destName
,
JSON
.
stringify
(
result
,
null
,
'
\t
'
));
}
catch
(
e
)
{
...
...
extensions/theme-abyss/package.json
浏览文件 @
99ab6e8d
...
...
@@ -8,7 +8,7 @@
{
"label"
:
"Abyss"
,
"uiTheme"
:
"vs-dark"
,
"path"
:
"./themes/
Abyss.tmTheme
"
"path"
:
"./themes/
abyss-color-theme.json
"
}
]
}
...
...
extensions/theme-abyss/themes/abyss-color-theme.json
0 → 100644
浏览文件 @
99ab6e8d
{
"name"
:
"Ofer 1"
,
"syntaxTokens"
:
[
{
"settings"
:
{
"background"
:
"#000c18"
,
"foreground"
:
"#6688cc"
}
},
{
"name"
:
"Comment"
,
"scope"
:
"comment"
,
"settings"
:
{
"foreground"
:
"#223355"
}
},
{
"name"
:
"String"
,
"scope"
:
"string"
,
"settings"
:
{
"foreground"
:
"#22aa44"
}
},
{
"name"
:
"Number"
,
"scope"
:
"constant.numeric"
,
"settings"
:
{
"foreground"
:
"#f280d0"
}
},
{
"name"
:
"Built-in constant"
,
"scope"
:
"constant.language"
,
"settings"
:
{
"foreground"
:
"#f280d0"
}
},
{
"name"
:
"User-defined constant"
,
"scope"
:
[
"constant.character"
,
"constant.other"
],
"settings"
:
{
"foreground"
:
"#f280d0"
}
},
{
"name"
:
"Variable"
,
"scope"
:
"variable"
,
"settings"
:
{
"fontStyle"
:
""
}
},
{
"name"
:
"Keyword"
,
"scope"
:
"keyword"
,
"settings"
:
{
"foreground"
:
"#225588"
}
},
{
"name"
:
"Storage"
,
"scope"
:
"storage"
,
"settings"
:
{
"fontStyle"
:
""
,
"foreground"
:
"#225588"
}
},
{
"name"
:
"Storage type"
,
"scope"
:
"storage.type"
,
"settings"
:
{
"fontStyle"
:
"italic"
,
"foreground"
:
"#9966b8"
}
},
{
"name"
:
"Class name"
,
"scope"
:
[
"entity.name.class"
,
"entity.name.type"
],
"settings"
:
{
"fontStyle"
:
"underline"
,
"foreground"
:
"#ffeebb"
}
},
{
"name"
:
"Inherited class"
,
"scope"
:
"entity.other.inherited-class"
,
"settings"
:
{
"fontStyle"
:
"italic underline"
,
"foreground"
:
"#ddbb88"
}
},
{
"name"
:
"Function name"
,
"scope"
:
"entity.name.function"
,
"settings"
:
{
"fontStyle"
:
""
,
"foreground"
:
"#ddbb88"
}
},
{
"name"
:
"Function argument"
,
"scope"
:
"variable.parameter"
,
"settings"
:
{
"fontStyle"
:
"italic"
,
"foreground"
:
"#2277ff"
}
},
{
"name"
:
"Tag name"
,
"scope"
:
"entity.name.tag"
,
"settings"
:
{
"fontStyle"
:
""
,
"foreground"
:
"#225588"
}
},
{
"name"
:
"Tag attribute"
,
"scope"
:
"entity.other.attribute-name"
,
"settings"
:
{
"fontStyle"
:
""
,
"foreground"
:
"#ddbb88"
}
},
{
"name"
:
"Library function"
,
"scope"
:
"support.function"
,
"settings"
:
{
"fontStyle"
:
""
,
"foreground"
:
"#9966b8"
}
},
{
"name"
:
"Library constant"
,
"scope"
:
"support.constant"
,
"settings"
:
{
"fontStyle"
:
""
,
"foreground"
:
"#9966b8"
}
},
{
"name"
:
"Library class/type"
,
"scope"
:
[
"support.type"
,
"support.class"
],
"settings"
:
{
"fontStyle"
:
"italic"
,
"foreground"
:
"#9966b8"
}
},
{
"name"
:
"Library variable"
,
"scope"
:
"support.other.variable"
,
"settings"
:
{
"fontStyle"
:
""
}
},
{
"name"
:
"Invalid"
,
"scope"
:
"invalid"
,
"settings"
:
{
"background"
:
"#F92672"
,
"fontStyle"
:
""
,
"foreground"
:
"#F8F8F0"
}
},
{
"name"
:
"Invalid deprecated"
,
"scope"
:
"invalid.deprecated"
,
"settings"
:
{
"background"
:
"#AE81FF"
,
"foreground"
:
"#F8F8F0"
}
},
{
"name"
:
"Markup Quote"
,
"scope"
:
"markup.quote"
,
"settings"
:
{
"foreground"
:
"#22aa44"
}
},
{
"name"
:
"Markup Styling"
,
"scope"
:
[
"markup.bold"
,
"markup.italic"
],
"settings"
:
{
"foreground"
:
"#22aa44"
}
},
{
"name"
:
"Markup Inline"
,
"scope"
:
"markup.inline.raw"
,
"settings"
:
{
"fontStyle"
:
""
,
"foreground"
:
"#9966b8"
}
},
{
"name"
:
"Markup Setext Header"
,
"scope"
:
"markup.heading.setext"
,
"settings"
:
{
"fontStyle"
:
""
,
"foreground"
:
"#ddbb88"
}
}
],
"colors"
:
{
"editorBackground"
:
"#000c18"
,
"editorCursor"
:
"#ddbb88"
,
"editorInvisibles"
:
"#002040"
,
"editorLineHighlight"
:
"#082050"
,
"editorSelection"
:
"#770811"
,
"editorGuide"
:
"#002952"
}
}
\ No newline at end of file
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录