Leif160519的blog Leif160519的blog

——————

目录
解决yakuake下agnoster主题乱码问题
/      

解决yakuake下agnoster主题乱码问题

背景

ubuntu20.04上安装了yakuake终端,感觉非常好用,搭配oh-my-zsh简直就是神器,但是当我使用agnoster主题时发现有乱码了(无图,解决的时候忘了截图了。。。)

解决办法

下载字体:fonts

git clone https://github.com/powerline/fonts
cd fonts
./install.sh
重启yakuake

或者
apt-get install powerline
重启yakuake

在某些linux发行版中,powerline默认被忽略,必须明确允许使用,可以在~/.config/fontconfig/conf.d(没有就创建)下写入一个配置文件50-enable-terminess-powerline.conf,内容如下

<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
<fontconfig>
  <selectfont>
    <acceptfont>
      <pattern>
        <patelt name="family"><string>terminess powerline</string></patelt>
      </pattern>
    </acceptfont>
  </selectfont>
</fontconfig>

之后执行fc-cache -vf,重启yakuake即可看到效果

如果是mac用户,使用的iTem2终端的话,需要在Preferences -> Profiles -> Text中勾选Use built-in Powerline glyphs即可

参考

agnoster主题乱码问题


“The first 90% of the code accounts for the first 90% of the development time. The remaining 10% of the code accounts for the other 90% of the development time.” – Tom Cargill

标  题解决yakuake下agnoster主题乱码问题
作  者Leif160519
出  处https://github.icu/articles/2021/07/14/1626242574623.html
关于博主:坐标南京,运维工程师,如有问题探讨可以直接下方留言。
声援博主:如果您觉得文章对您有帮助,可以评论、订阅、收藏。您的鼓励是博主的最大动力!