用 screenfetch 和 linux_logo 显示带有酷炫 Linux 标志的基本硬

想在屏幕上显示出你的 Linux 发行版的酷炫标志和基本硬件信息吗?不用找了,来试试超赞的 screenfetch 和 linux_logo 工具。

用 screenfetch 和 linux_logo 显示带有酷炫 Linux 标志的基本硬

Linux Logo

 

来看看 screenfetch 吧

screenFetch 是一个能够在截屏中显示系统/主题信息的命令行脚本。它可以在 Linux,OS X,FreeBSD 以及其它的许多类Unix系统上使用。来自 man 手册的说明:

这个方便的 Bash 脚本可以用来生成那些漂亮的终端主题信息和用 ASCII 构成的发行版标志,就像如今你在别人的截屏里看到的那样。它会自动检测你的发行版并显示 ASCII 版的发行版标志,并且在右边显示一些有价值的信息。

 

在 Linux 上安装 screenfetch

打开终端应用。在基于 Debian 或 Ubuntu 或 Mint 的系统上只需要输入下列 apt-get 命令

  1. <span class="pln">$ </span><span class="kwd">sudo</span><span class="kwd">apt-get</span><span class="pln"> install screenfetch</span>

用 screenfetch 和 linux_logo 显示带有酷炫 Linux 标志的基本硬

图一:用 apt-get 安装 screenfetch

 

在 Mac OS X 上安装 screenfetch

输入下列命令:

  1. <span class="pln">$ brew install screenfetch</span>

用 screenfetch 和 linux_logo 显示带有酷炫 Linux 标志的基本硬

图二:用 brew 命令安装 screenfetch

 

在 FreeBSD 上安装 screenfetch

输入下列 pkg 命令:

  1. <span class="pln">$ </span><span class="kwd">sudo</span><span class="pln"> pkg install sysutils</span><span class="pun">/</span><span class="pln">screenfetch</span>

用 screenfetch 和 linux_logo 显示带有酷炫 Linux 标志的基本硬

图三:在 FreeBSD 用 pkg 安装 screenfetch

 

在 Fedora 上安装 screenfetch

输入下列 dnf 命令:

  1. <span class="pln">$ </span><span class="kwd">sudo</span><span class="pln"> dnf install screenfetch</span>

用 screenfetch 和 linux_logo 显示带有酷炫 Linux 标志的基本硬

图四:在 Fedora 22 用 dnf 安装 screenfetch

 

我该怎么使用 screefetch 工具?

只需输入以下命令:

  1. <span class="pln">$ screenfetch</span>

这是不同系统的输出:

用 screenfetch 和 linux_logo 显示带有酷炫 Linux 标志的基本硬

Fedora 上的 Screenfetch

用 screenfetch 和 linux_logo 显示带有酷炫 Linux 标志的基本硬

OS X 上的 Screenfetch

用 screenfetch 和 linux_logo 显示带有酷炫 Linux 标志的基本硬

FreeBSD 上的 Screenfetch

用 screenfetch 和 linux_logo 显示带有酷炫 Linux 标志的基本硬

Debian 上的 Screenfetch

 

获取截屏

要获取截屏并保存成文件,输入:

  1. <span class="pln">$ screenfetch </span><span class="pun">-</span><span class="pln">s</span>

你会看到一个文件 ~/Desktop/screenFetch-*.jpg。获取截屏并直接上传到 imgur,输入:

  1. <span class="pln">$ screenfetch </span><span class="pun">-</span><span class="kwd">su</span><span class="pln"> imgur</span>

输出示例:

  1. <span class="pun">-/+:.</span><span class="pln"> veryv@Viveks</span><span class="pun">-</span><span class="typ">MacBook</span><span class="pun">-</span><span class="typ">Pro</span>
  2. <span class="pun">:++++.</span><span class="pln"> OS</span><span class="pun">:</span><span class="lit">64bit</span><span class="typ">Mac</span><span class="pln"> OS X </span><span class="lit">10.10</span><span class="pun">.</span><span class="lit">5</span><span class="lit">14F27</span>
  3. <span class="pun">/+++/.</span><span class="typ">Kernel</span><span class="pun">:</span><span class="pln"> x86_64 </span><span class="typ">Darwin</span><span class="lit">14.5</span><span class="pun">.</span><span class="lit">0</span>
  4. <span class="pun">.:-::-</span><span class="pun">.+/:-</span><span class="str">``</span><span class="pun">.::-</span><span class="typ">Uptime</span><span class="pun">:</span><span class="lit">3d</span><span class="lit">1h</span><span class="lit">36m</span>
  5. <span class="pun">.:</span><span class="str">/++++++/</span><span class="pun">::::</span><span class="str">/++++++/</span><span class="pun">:</span><span class="str">` Packages: 56</span>
  6. <span class="str">.:///////////////////////:`</span><span class="typ">Shell</span><span class="pun">:</span><span class="kwd">bash</span><span class="lit">3.2</span><span class="pun">.</span><span class="lit">57</span>
  7. <span class="com">////////////////////////` Resolution: 2560x1600 1920x1200</span>
  8. <span class="pun">-+++++++++++++++++++++++</span><span class="str">` DE: Aqua</span>
  9. <span class="str">/++++++++++++++++++++++/ WM: Quartz Compositor</span>
  10. <span class="str">/sssssssssssssssssssssss. WM Theme: Blue</span>
  11. <span class="str">:ssssssssssssssssssssssss- Font: Not Found</span>
  12. <span class="str">osssssssssssssssssssssssso/`</span><span class="pln"> CPU</span><span class="pun">:</span><span class="typ">Intel</span><span class="typ">Core</span><span class="pln"> i5</span><span class="pun">-</span><span class="lit">4288U</span><span class="pln"> CPU </span><span class="pun">@</span><span class="lit">2.60GHz</span>
  13. <span class="str">`syyyyyyyyyyyyyyyyyyyyyyyy+`</span><span class="pln"> GPU</span><span class="pun">:</span><span class="typ">Intel</span><span class="typ">Iris</span>
  14. <span class="str">`ossssssssssssssssssssss/ RAM: 6405MB / 8192MB</span>
  15. <span class="str">:ooooooooooooooooooo+.</span>
  16. <span class="str">`</span><span class="pun">:+</span><span class="pln">oo</span><span class="pun">+</span><span class="str">/:-..-:/</span><span class="pun">+</span><span class="pln">o</span><span class="pun">+/-</span>
  17. <span class="typ">Taking</span><span class="pln"> shot </span><span class="kwd">in</span><span class="lit">3.</span><span class="pun">.</span><span class="lit">2.</span><span class="pun">.</span><span class="lit">1.</span><span class="pun">.</span><span class="lit">0.</span>
  18. <span class="pun">==></span><span class="typ">Uploading</span><span class="pln"> your screenshot now</span><span class="pun">...</span><span class="pln">your screenshot can be viewed at http</span><span class="pun">:</span><span class="com">//imgur.com/HKIUznn</span>

你可以访问 http://imgur.com/HKIUznn 来查看上传的截屏。

 

再来看看 linux_logo

linux_logo 程序生成一个彩色的 ANSI 版企鹅图片,还包含一些来自 /proc 的系统信息。

 

安装

只需按照你的 Linux 发行版输入对应的命令:

 

Debian/Ubutnu/Mint

  1. <span class="com">#</span><span class="kwd">apt-get</span><span class="pln"> install linux_logo</span>

 

CentOS/RHEL/旧版 Fedora

  1. <span class="com">#</span><span class="kwd">yum</span><span class="pln"> install linux_logo</span>

 

Fedora Linux v22+ 或更新版本

  1. <span class="com">#</span><span class="pln"> dnf install linux_logo</span>

 

运行它

只需输入下列命令:

  1. <span class="pln">$ linux_logo</span>

用 screenfetch 和 linux_logo 显示带有酷炫 Linux 标志的基本硬

运行 linux_logo

 

等等,还有更多!

你可以用这个命令查看内置的标志列表:

  1. <span class="pln">$ linux_logo </span><span class="pun">-</span><span class="pln">f </span><span class="pun">-</span><span class="pln">L </span><span class="kwd">list</span>

输出示例:

  1. <span class="typ">Available</span><span class="typ">Built</span><span class="pun">-</span><span class="kwd">in</span><span class="typ">Logos</span><span class="pun">:</span>
  2. <span class="typ">Num</span><span class="typ">Type</span><span class="typ">Ascii</span><span class="typ">Name</span><span class="typ">Description</span>
  3. <span class="lit">1</span><span class="typ">Classic</span><span class="typ">Yes</span><span class="pln"> aix AIX </span><span class="typ">Logo</span>
  4. <span class="lit">2</span><span class="typ">Banner</span><span class="typ">Yes</span><span class="pln"> bsd_banner </span><span class="typ">FreeBSD</span><span class="typ">Logo</span>
  5. <span class="lit">3</span><span class="typ">Classic</span><span class="typ">Yes</span><span class="pln"> bsd </span><span class="typ">FreeBSD</span><span class="typ">Logo</span>
  6. <span class="lit">4</span><span class="typ">Classic</span><span class="typ">Yes</span><span class="pln"> irix </span><span class="typ">Irix</span><span class="typ">Logo</span>
  7. <span class="lit">5</span><span class="typ">Banner</span><span class="typ">Yes</span><span class="pln"> openbsd_banner </span><span class="typ">OpenBSD</span><span class="typ">Logo</span>
  8. <span class="lit">6</span><span class="typ">Classic</span><span class="typ">Yes</span><span class="pln"> openbsd </span><span class="typ">OpenBSD</span><span class="typ">Logo</span>
  9. <span class="lit">7</span><span class="typ">Banner</span><span class="typ">Yes</span><span class="pln"> solaris </span><span class="typ">The</span><span class="typ">Default</span><span class="typ">Banner</span><span class="typ">Logos</span>
  10. <span class="lit">8</span><span class="typ">Banner</span><span class="typ">Yes</span><span class="pln"> banner </span><span class="typ">The</span><span class="typ">Default</span><span class="typ">Banner</span><span class="typ">Logo</span>
  11. <span class="lit">9</span><span class="typ">Banner</span><span class="typ">Yes</span><span class="pln"> banner</span><span class="pun">-</span><span class="pln">simp </span><span class="typ">Simplified</span><span class="typ">Banner</span><span class="typ">Logo</span>
  12. <span class="lit">10</span><span class="typ">Classic</span><span class="typ">Yes</span><span class="pln"> classic </span><span class="typ">The</span><span class="typ">Default</span><span class="typ">Classic</span><span class="typ">Logo</span>
  13. <span class="lit">11</span><span class="typ">Classic</span><span class="typ">Yes</span><span class="pln"> classic</span><span class="pun">-</span><span class="pln">nodots </span><span class="typ">The</span><span class="typ">Classic</span><span class="typ">Logo</span><span class="pun">,</span><span class="typ">No</span><span class="typ">Periods</span>
  14. <span class="lit">12</span><span class="typ">Classic</span><span class="typ">Yes</span><span class="pln"> classic</span><span class="pun">-</span><span class="pln">simp </span><span class="typ">Classic</span><span class="typ">No</span><span class="typ">Dots</span><span class="typ">Or</span><span class="typ">Letters</span>
  15. <span class="lit">13</span><span class="typ">Classic</span><span class="typ">Yes</span><span class="pln"> core </span><span class="typ">Core</span><span class="typ">Linux</span><span class="typ">Logo</span>
  16. <span class="lit">14</span><span class="typ">Banner</span><span class="typ">Yes</span><span class="pln"> debian_banner_2 </span><span class="typ">Debian</span><span class="typ">Banner</span><span class="lit">2</span>
  17. <span class="lit">15</span><span class="typ">Banner</span><span class="typ">Yes</span><span class="pln"> debian_banner </span><span class="typ">Debian</span><span class="typ">Banner</span><span class="pun">(</span><span class="pln">white</span><span class="pun">)</span>
  18. <span class="lit">16</span><span class="typ">Classic</span><span class="typ">Yes</span><span class="pln"> debian </span><span class="typ">Debian</span><span class="typ">Swirl</span><span class="typ">Logos</span>
  19. <span class="lit">17</span><span class="typ">Classic</span><span class="typ">Yes</span><span class="pln"> debian_old </span><span class="typ">Debian</span><span class="typ">Old</span><span class="typ">Penguin</span><span class="typ">Logos</span>
  20. <span class="lit">18</span><span class="typ">Classic</span><span class="typ">Yes</span><span class="pln"> gnu_linux </span><span class="typ">Classic</span><span class="pln"> GNU</span><span class="pun">/</span><span class="typ">Linux</span>
  21. <span class="lit">19</span><span class="typ">Banner</span><span class="typ">Yes</span><span class="pln"> mandrake </span><span class="typ">Mandrakelinux</span><span class="pun">(</span><span class="pln">TM</span><span class="pun">)</span><span class="typ">Banner</span>
  22. <span class="lit">20</span><span class="typ">Banner</span><span class="typ">Yes</span><span class="pln"> mandrake_banner </span><span class="typ">Mandrake</span><span class="pun">(</span><span class="pln">TM</span><span class="pun">)</span><span class="typ">Linux</span><span class="typ">Banner</span>
  23. <span class="lit">21</span><span class="typ">Banner</span><span class="typ">Yes</span><span class="pln"> mandriva </span><span class="typ">Mandriva</span><span class="pun">(</span><span class="pln">TM</span><span class="pun">)</span><span class="typ">Linux</span><span class="typ">Banner</span>
  24. <span class="lit">22</span><span class="typ">Banner</span><span class="typ">Yes</span><span class="pln"> pld PLD </span><span class="typ">Linux</span><span class="pln"> banner</span>
  25. <span class="lit">23</span><span class="typ">Classic</span><span class="typ">Yes</span><span class="pln"> raspi </span><span class="typ">An</span><span class="pln"> ASCII </span><span class="typ">Raspberry</span><span class="typ">Pi</span><span class="pln"> logo</span>
  26. <span class="lit">24</span><span class="typ">Banner</span><span class="typ">Yes</span><span class="pln"> RedHat </span><span class="typ">RedHat</span><span class="typ">Banner</span><span class="pun">(</span><span class="pln">white</span><span class="pun">)</span>
  27. <span class="lit">25</span><span class="typ">Banner</span><span class="typ">Yes</span><span class="pln"> slackware </span><span class="typ">Slackware</span><span class="typ">Logo</span>
  28. <span class="lit">26</span><span class="typ">Banner</span><span class="typ">Yes</span><span class="pln"> sme SME </span><span class="typ">Server</span><span class="typ">Banner</span><span class="typ">Logo</span>
  29. <span class="lit">27</span><span class="typ">Banner</span><span class="typ">Yes</span><span class="pln"> sourcemage_ban </span><span class="typ">Source</span><span class="typ">Mage</span><span class="pln"> GNU</span><span class="pun">/</span><span class="typ">Linux</span><span class="pln"> banner</span>
  30. <span class="lit">28</span><span class="typ">Banner</span><span class="typ">Yes</span><span class="pln"> sourcemage </span><span class="typ">Source</span><span class="typ">Mage</span><span class="pln"> GNU</span><span class="pun">/</span><span class="typ">Linux</span><span class="pln"> large</span>
  31. <span class="lit">29</span><span class="typ">Banner</span><span class="typ">Yes</span><span class="pln"> SUSE SUSE </span><span class="typ">Logo</span>
  32. <span class="lit">30</span><span class="typ">Banner</span><span class="typ">Yes</span><span class="pln"> ubuntu </span><span class="typ">Ubuntu</span><span class="typ">Logo</span>
  33. <span class="typ">Do</span><span class="str">"linux_logo -L num"</span><span class="kwd">where</span><span class="pln"> num </span><span class="kwd">is</span><span class="kwd">from</span><span class="pln"> above to </span><span class="kwd">get</span><span class="pln"> the appropriate logo</span><span class="pun">.</span>
  34. <span class="typ">Remember</span><span class="pln"> to also </span><span class="kwd">use</span><span class="pun">-</span><span class="pln">a to </span><span class="kwd">get</span><span class="pln"> ascii version</span><span class="pun">.</span>

查看 aix 的标志,输入:

  1. <span class="pln">$ linux_logo </span><span class="pun">-</span><span class="pln">f </span><span class="pun">-</span><span class="pln">L aix</span>

查看 openbsd 的标志:

  1. <span class="pln">$ linux_logo </span><span class="pun">-</span><span class="pln">f </span><span class="pun">-</span><span class="pln">L openbsd</span>

或者只是随机看看一些 Linux 标志:

  1. <span class="pln">$ linux_logo </span><span class="pun">-</span><span class="pln">f </span><span class="pun">-</span><span class="pln">L random_xy</span>

可以像下面那样结合 bash 的循环来显示不同的标志,输入:

用 screenfetch 和 linux_logo 显示带有酷炫 Linux 标志的基本硬

动图1: linux_logo 和 bash 循环,既有趣又能发朋友圈耍酷

 

获取帮助

输入下列命令:

  1. <span class="pln">$ screefetch </span><span class="pun">-</span><span class="pln">h</span>
  2. <span class="pln">$ linux_logo </span><span class="pun">-</span><span class="pln">h</span>

参考


via: http://www.cyberciti.biz/hardware/howto-display-linux-logo-in-bash-terminal-using-screenfetch-linux_logo/

作者:Vivek Gite 译者:alim0x 校对:wxy

本文由 LCTT 原创编译,Linux中国 荣誉推出

相关推荐