|NO.Z.00020|——————————|NavigationLog|——|偽黑客命令&cmartix&blessed-contrib&hollywood&sl&cowsay&yes&cal&ASCII|
阿新 • • 發佈:2022-03-22
[NavigationIng:偽黑客命令] [NavigationIng.了不起]
一、cmartix部署教程
### --- 下載cmartix部署原始碼包:cmatrix-1.2.tar.gz ~~~ # 下載cmartix部署原始碼包:cmatrix-1.2.tar.gz ~~~ cmartix原始碼包地址:https://github.com/abishekvashok/cmatrix/releases
### --- 部署安裝:
~~~ # 安裝環境依賴包,上傳軟體包並解壓
[root@localhost ~]# yum install -y gcc gcc-c++ cc ncurses-devel ncurses / /安裝軟體依賴包及環境:
[root@localhost ~]# tar -zxvf cmatrix-1.2.tar.gz
[root@localhost ~]# cd cmatrix-1.2.tar/
~~~ # 執行預編譯,編譯,安裝 [root@localhost cmatrix-1.2]# ./configure --prefix=/opt/cmatrix/ [root@localhost cmatrix-1.2]# make make all-am make[1]: Entering directory `/root/cmatrix-1.2' gcc -DHAVE_CONFIG_H -I. -g -O2 -MT cmatrix.o -MD -MP -MF .deps/cmatrix.Tpo -c -o cmatrix.o cmatrix.c mv -f .deps/cmatrix.Tpo .deps/cmatrix.Po gcc -g -O2 -o cmatrix cmatrix.o -lncurses -lncurses make[1]: Leaving directory `/root/cmatrix-1.2' [root@localhost cmatrix-1.2]# make install make[1]: Entering directory `/root/cmatrix-1.2' /usr/bin/mkdir -p '/opt/cmatrix/bin' /usr/bin/install -c cmatrix '/opt/cmatrix/bin' Installing matrix fonts in /usr/lib/kbd/consolefonts... /usr/bin/mkdir -p '/opt/cmatrix/share/man/man1' /usr/bin/install -c -m 644 cmatrix.1 '/opt/cmatrix/share/man/man1' make[1]: Leaving directory `/root/cmatrix-1.2'
~~~ # 建立軟連線並測試是否OK [root@localhost ~]# ln -s /opt/cmatrix/bin/cmatrix /usr/local/bin/cmatrix [root@localhost ~]# ll /usr/local/bin/cmatrix lrwxrwxrwx 1 root root 24 Nov 27 15:39 /usr/local/bin/cmatrix -> /opt/cmatrix/bin/cmatrix [root@localhost ~]# cmatrix -V CMatrix version 1.2 (compiled 15:19:21, Nov 27 2020) Email: [email protected] Web: https://github.com/abishekvashok/cmatrix
### --- 選項及使用說明:
~~~ # 選項及使用說明:
[root@localhost ~]# cmatrix
~~~ 常用選項引數:
-a: 非同步滾動
-b: 啟用粗體字元
-B: 所有粗體字元(覆蓋-b)
-f: 強制啟用linux$term型別
-l: linux模式(使用矩陣控制檯字型)
-o: 使用舊式滾動
-h: 列印使用和退出
-n: 無粗體字元(覆蓋-b和-b,預設)
-s: “螢幕保護程式”模式,在第一次按鍵時退出
-x: 視窗模式,如果您的xterm使用mtx.pcf,則使用
-v: 列印版本資訊並退出
-u: 延遲(0-10,預設4):螢幕更新延遲
-C [顏色]:將此顏色用於矩陣(預設為綠色)
~~~ # 在執行時使用的快捷鍵:
a B b n ! @ # $ 1、2、3、4、5、6、7、8、9
[root@localhost ~]# cmatrix -a
[root@localhost ~]# cmatrix -a -C red
[root@localhost ~]# cmatrix -b -C blue
[root@localhost ~]# cmatrix // -s鍵盤輸入第一個字母時退出程式
附錄一:
### --- 問題現象:
[root@localhost ~]# make // .h標頭檔案找不到,安裝依賴包
cmatrix.c:40:20: fatal error: curses.h: No such file or directory
### --- 解決方案:
[root@localhost ~]# yum install ncurses-devel ncurses ncurses-libs // 安裝依賴包
二、blessed-contrib部署教程:
### --- 下載blessed-contrib軟體包:blessed-contrib-master.zip
~~~ 下載blessed-contrib軟體包:blessed-contrib-master.zip
~~~ blessed-contribution包下載地址:https://github.com/yaronn/blessed-contrib
### --- 部署blessed-contrib程式檔案:
~~~ # 安裝npm工具:
[root@localhost ~]# curl --silent --location https://rpm.nodesource.com/setup_10.x | bash - //下載nodejs擴充套件源
[root@localhost ~]# ll /etc/yum.repos.d/
-rw-r--r-- 1 root root 474 Apr 25 2018 nodesource-el7.repo
[root@localhost ~]# yum install -y nodejs // 安裝nodejs
[root@localhost ~]# npm install -g cnpm --registry=https://registry.npm.taobao.org //安裝淘寶映象,不安裝也可以
[root@localhost ~]# npm run build // 執行構建專案+專案名稱
[root@localhost ~]# node -v // 檢視node版本
v10.23.0
[root@localhost ~]# npm -v // 檢視npm版本
6.14.8
~~~ # 安裝blessed-contrib工具:
[root@localhost ~]# unzip blessed-contrib-master.zip
[root@localhost ~]# cd blessed-contrib-master/
[root@localhost blessed-contrib-master]# npm install
[root@localhost blessed-contrib-master]# npm audit fix
~~~ # 執行blessed-contrib:
[root@localhost blessed-contrib-master]# node ./examples/dashboard.js // 執行dashboard
附錄一:
### --- 問題現象:
[root@localhost blessed-contrib-master]# npm install
found 7 vulnerabilities (6 low, 1 moderate) // 發現7個漏洞
run `npm audit fix` to fix them, or `npm audit` for details // 使用npm audit fix來修復
### --- 解決方案:
[root@localhost blessed-contrib-master]# npm audit fix
added 1 package from 1 contributor, removed 1 package and updated 3 packages in 6.501s
fixed 7 of 7 vulnerabilities in 251 scanned packages
三、hollywood部署教程
### --- hollywood部署教程
[root@localhost ~]# yum install -y ppa:hollywood/ppa
[root@localhost ~]# yum install -y hollywood
[root@localhost ~]# yum install -y byobu
[root@localhost ~]# hollywood
四、常用的比較高逼格的命令:
### --- sl命令
~~~ # 安裝sl命令
[root@localhost ~]# yum install -y sl
~~~ # 常用選項:
-a An accident seems to happen. You'll feel pity for people who cry for help.
-l shows little one.
-F It flies.
-e Allow interrupt by Ctrl+C.
[root@localhost ~]# alias ls=sl // ls和sl等價命令
alias ls='ls --color=auto'
~~~ # sl使用
[root@localhost ~]# sl
(@@) ( ) (@) ( ) @@ () @ O @ O @
( )
(@@@@)
( )
(@@@)
==== ________ ___________
_D _| |_______/ \__I_I_____===__|_________|
|(_)--- | H\________/ | | =|___ ___| _________________
/ | | H | | | | ||_| |_|| _| \_____A
| | | H |__--------------------| [___] | =| |
| ________|___H__/__|_____/[][]~\_______| | -| |
|/ | |-----------I_____I [][] [] D |=======|____|________________________|_
__/ =| o |=-~~\ /~~\ /~~\ /~~\ ____Y___________|__|__________________________|_
|/-=|___|= || || || |_____/~\___/ |_D__D__D_| |_D__D__D_|
\_/ \O=====O=====O=====O_/ \_/ \_/ \_/ \_/ \_/
### --- cowsay命令:
~~~ # cowsay命令:
~~~ # 用 ASCII 字元列印牛,羊等動物,還有個cowthink,
[root@localhost ~]# yum install -y cowsay
[root@localhost ~]# cowsay "I am not a cow, hahaha"
________________________
< I am not a cow, hahaha >
------------------------
\ ^__^
\ (oo)\_______
(__)\ )\/\
||----w |
|| ||
[root@localhost ~]# cowsay -l // 檢視其它動物的名字,然後 -f 跟上動物名.
~~~ # cowsay命令:
[root@localhost ~]# cowsay -f tux "坑爹啊"
_____
< 坑爹啊 >
-----
\
\
.--.
|o_o |
|:_/ |
// \ \
(| | )
/'\_ _/`\
\___)=(___/
[root@localhost ~]# fortune | cowsay // 還可以讓 cowsay 說出 fortune 的內容,就像這樣:
### --- yes 命令:
~~~ # yes 命令:
[root@localhost ~]# yum -y install yes
[root@localhost ~]# yes 我很NB
### --- cal
~~~ # cal
[root@localhost ~]# yum -y install cal
[root@localhost ~]# cal 9 1752
September 1752
Su Mo Tu We Th Fr Sa
1 2 14 15 16
17 18 19 20 21 22 23
24 25 26 27 28 29 30
[root@localhost ~]# cal
November 2020
Su Mo Tu We Th Fr Sa
1 2 3 4 5 6 7
8 9 10 11 12 13 14
15 16 17 18 19 20 21
22 23 24 25 26 27 28
29 30
### --- ASCII 藝術框:box 命令
~~~ # ASCII 藝術框:box 命令
[root@localhost ~]# yum -y install boxes boxes
[root@localhost ~]# echo "Tongji Univerisity" | boxes
/**********************/
/* Tongji Univerisity */
/**********************/
[root@localhost ~]# echo "Tongji Univerisity" | boxes -d dog
__ _,--="=--,_ __
/ \." .-. "./ \
/ ,/ _ : : _ \/` \
\ `| /o\ :_: /o\ |\__/
`-'| :="~` _ `~"=: |
\` (_) `/
.-"-. \ | / .-"-.
.---{ }--| /,.-'-.,\ |--{ }---.
) (_)_)_) \_/`~-===-~`\_/ (_(_(_) (
( Tongji Univerisity )
) (
'---------------------------------------'
===============================END===============================
Walter Savage Landor:strove with none,for none was worth my strife.Nature I loved and, next to Nature, Art:I warm'd both hands before the fire of life.It sinks, and I am ready to depart ——W.S.Landor
來自為知筆記(Wiz)