美文网首页
windows terminal配色

windows terminal配色

作者: leoxiaobei | 来源:发表于2020-05-03 16:55 被阅读0次

以前用zsh+oh_my_zsh,后来用fluent terminal,现在用Windwos Terminal(preview ),直接从win10商店下载即可
修改默认打开的shell为Ubuntu,Ubuntu的guid值在list里面找(就是source显示为Windows.Terminal.Wsl的那个)

    "defaultProfile": "{guid值}",

其他修改:

{
  "guid": "{guid值}",
  "hidden": false,
  "name": "Ubuntu",
  "tabTitle" :"Ubuntu",
  "source": "Windows.Terminal.Wsl",
  "fontFace": "Sarasa Mono SC",#一种可以显示中文的字体
  "fontSize": 12,
  "acrylicOpacity": 0.5,#亚克力背景透明度
  "useAcrylic": true,#启用亚克力效果
  "startingDirectory": "C:\\Users\\用户名\\AppData\\Local\\Packages\\CanonicalGroupLimited.UbuntuonWindows_79rhkp1fndgsc\\LocalState\\rootfs",#用户主目录
  "colorScheme": "Vintage",#使用的配色主题,在大括号内定义的颜色会替换当前使用主题的默认配色
  "cursorColor": "#FFFFFF",#光标颜色
  "foreground": "#073642",
  "background": "#FDF6E3",
  "cursorShape": "bar",#光标形状
  "backgroundImage": "C:\\Users\\ZSY\\Pictures\\2.jpg",#自定义背景图片
  "backgroundImageOpacity": 1,#背景透明度,1为不透明
  "backgroundImageStretchMode": "uniformToFill",#按图片比例拉伸并铺满屏幕
  "closeOnExit": "always",#退出时不提醒
  "snapOnInput" : true#键入时窗口将滚动到命令输入行
}
效果图

后续:在此基础上继续使用了zsh+oh-my-zsh并使用了alien主题
修改的.zshrc如下:

export ALIEN_THEME="blue"
export ALIEN_SECTION_USER_HOST=1
export ALIEN_SECTIONS_LEFT=(
  exit
  time
  user
  path
  vcs_branch:async
  vcs_status:async
  vcs_dirty:async
  newline
  ssh
  venv
  prompt
  source ~/alien/alien.zsh
  )

修改的windows terminal参数如下:

"guid": "{c6eaf9f4-32a7-5fdc-b5cf-066e8a4b1e40}",
"hidden": false,
"name": "Ubuntu 18.04 LTS on WSL",
"tabTitle" : "Ubuntu 18.04 LTS on WSL", 
"source": "Windows.Terminal.Wsl",
"startingDirectory": "C:\\Users\\XXX\\AppData\\Local\\Packages\\CanonicalGroupLimited.Ubuntu18.04onWindows_79rhkp1fndgsc\\LocalState\\rootfs",
"alwaysShowTabs": true,
"closeOnExit": true,
"snapOnInput" : true,
"padding" : "0, 0, 0, 0",
"suppressApplicationTitle": true,
"acrylicOpacity": 0,
"useAcrylic": true,
"fontFace": "MesloLGS NF",
"fontSize": 12,
//"colorScheme":"Solarized Dark",
//"colorScheme": "Vintage",
"cursorColor": "#FFFFFF",
"cursorShape": "bar",
//"foreground": "#253494",
"backgroundImage": "C:\\Users\\XXX\\Pictures\\4.png",
"backgroundImageOpacity": 0.8,
"backgroundImageAlignment" : "center",
"backgroundImageStretchMode": "Fill"

搭配后的效果如下:


111.JPG

部分参考自:https://zhuanlan.zhihu.com/p/104720872?utm_source=wechat_session

相关文章

网友评论

      本文标题:windows terminal配色

      本文链接:https://www.haomeiwen.com/subject/bwidghtx.html