讓man顯示中文

安裝中文幫助文件腳本

#下載解壓man中文包

[root@izm5e63wlhi02su9ssspzoz ~]# wget https://src.fedoraproject.org/repo/pkgs/man-pages-zh-CN/manpages-zh-1.5.1.tar.gz/13275fd039de8788b15151c896150bc4/manpages-zh-1.5.1.tar.gz

tar zxvf manpages-zh-1.5.1.tar.gz

#安裝該中文包

[root@izm5e63wlhi02su9ssspzoz ~]# cd manpages-zh-1.5.1/

[root@izm5e63wlhi02su9ssspzoz ~]# ./configure --prefix=/usr/local/zhman --disable-zhtw

[root@izm5e63wlhi02su9ssspzoz ~]# make

[root@izm5e63wlhi02su9ssspzoz ~]# make install

#使cman進入中文幫助文檔

[root@izm5e63wlhi02su9ssspzoz ~]# echo "alias cman='man -M /usr/local/zhman/share/man/zh_CN'" >> /etc/profile
[root@izm5e63wlhi02su9ssspzoz ~]# . /etc/profile

通過執行以上腳本就可以通過cman來獲取中文文檔了 如cman ls


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