別點進來! Linux 與 Mac 下有趣但毫無用處的命令

Linux | Mac 下有趣但毫無用處的命令

引言

今天非常的有意思,在遠程 linux的時候瘋狂的查看當前列表時,不小心打快了。
將ls 輸出成了sl
結果出現了這樣的情況:
初始遇見sl

中間過程無法按q 或者 control+C來退出,第一次看見還以爲是中病毒了hh。
於是決定查閱和整理一下Mac OS下的安裝和展示。

1. sl

sl是Steam Locomotive 蒸汽火車的縮寫,因此就會有圖中這樣的情景出現。

安裝

Mac:
brew install sl
Linux:
sudo apt-get install sl

使用

sl

(有一說一我在服務器上遇到這個,是不是學長故意搞得哈哈哈)

2. cmatrix

cmatrix是模擬類似黑客帝國的數字雨場景來進行顯示,讓人覺得非常的高大上。

安裝

Mac:
brew install cmatrix
Linux:
sudo apt-get install cmatrix

使用

➜ ~ cmatrix -h
Usage: cmatrix -[abBfhlsVx] [-u delay] [-C color]
-a: 異步滾動
-b: 上面是黑體字符
-B: 所有字體都是黑體 (覆蓋 -b)
-f: 強制使用 linux $TERM 類型
-l: Linux 模式 (使用 matrix 控制檯字體)
-o: 使用舊樣式滾動
-h: 打印幫助信息
-n: 不用粗體 (覆蓋 -b and -B, default)
-s: 屏保模式,任意鍵退出
-x: X窗口模式,如果你使用xterm的mtx.pcf
-V: 現實版本信息
-u delay (0 - 10, default 4): Screen update delay
-C [color]: 使用自定義顏色 (默認 green 綠色)

效果:

在這裏插入圖片描述

可以將字體設置爲別的顏色,比如藍色:
在這裏插入圖片描述

3. ASCIIquarium

把終端變成五顏六色的海洋館

安裝

Mac:
brew install asciiquarium
Linux:
wget http://www.robobunny.com/projects/asciiquarium/asciiquarium.tar.gz
tar -zxvf asciiquarium.tar.gz
cd asciiquarium_1.1/
cp asciiquarium /usr/local/bin
chmod 0755 /usr/local/bin/asciiquarium

使用

asciiquarium

效果

在這裏插入圖片描述

4. cowsay

會說話的 ascii 奶牛

安裝

Mac:
brew install cowsay
Linux:
sudo apt-get install cowsay

使用

cowsay [想說的話]
cowsay -h
cow{say,think} version 3.03, © 1999 Tony Monroe
Usage: cowsay [-bdgpstwy] [-h] [-e eyes] [-f cowfile]
[-l] [-n] [-T tongue] [-W wrapcolumn] [message]

效果

在這裏插入圖片描述

5. lolcat

在命令行把輸出變成七彩顏色的

安裝

Mac:
brew install lolcat
Linux:
wget https://github.com/busyloop/lolcat/archive/master.zip
unzip master.zip
cd lolcat-master/bin
gem install lolcat

使用

command | lolcat

Usage: lolcat [OPTION]… [FILE]…

Concatenate FILE(s), or standard input, to standard output.
With no FILE, or when FILE is -, read standard input.
-p, --spread= Rainbow spread (default: 3.0)
-F, --freq= Rainbow frequency (default: 0.1)
-S, --seed= Rainbow seed, 0 = random (default: 0)
-a, --animate Enable psychedelics
-d, --duration= Animation duration (default: 12)
-s, --speed= Animation speed (default: 20.0)
-i, --invert Invert fg and bg
-t, --truecolor 24-bit (truecolor)
-f, --force Force color even when stdout is not a tty
-v, --version Print version and exit
-h, --help Show this message
Examples:
lolcat f - g Output f’s contents, then stdin, then g’s contents.
lolcat Copy standard input to standard output.
fortune | lolcat Display a rainbow cookie.
Report lolcat bugs to https://github.com/busyloop/lolcat/issues
lolcat home page: https://github.com/busyloop/lolcat/
Report lolcat translation bugs to http://speaklolcat.com/

值得一提的是,這個help的展示也是彩色的

效果

在這裏插入圖片描述

等等!如果lolcat能夠和ls配合,那麼能不能和sl配合?
在這裏插入圖片描述

果然是可以的哈哈哈哈

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章