【RHCA+】fortune命令(输出一句话)
“ 目录RHCA - 2 有趣的命令 - 2 fortune命令输出一句话 ”显示随机选择的、幽默或诙谐的文本行语法格式fortune [参数]参数作用-a显示所有数据库中的fortune项-f使用文件作为fortune数据库-i忽略大小写-l显示fortune项的长度-s显示fortune项的简短版本-m pattern仅显示匹配给定模式的fortune项-n number显示指定数量的fortune项[#%] file/directory/all允许指定一个文件、目录或all来选择fortune项的来源#和%用于指定数据库中的特定fortune项1、安装[rootServer_8_200 ~]# vim /etc/yum.repos.d/epel.repo #创建一个epel仓库[epel]nameepel8baseurlhttp://dl.fedoraproject.org/pub/epel/8/Everything/x86_64/enabled1gpgcheck0[rootServer_8_200 ~]# yum clean all #清理旧缓存[rootServer_8_200 ~]# yum makecache #建立缓存[rootServer_8_200 ~]# dnf -y install fortune-mod #安装软件2、使用[rootServer_8_200 ~]# fortune #执行命令输出一句话The 80s -- when you cant tell hairstyles from chemotherapy.[rootServer_8_200 ~]# fortune #执行命令输出一句话Boomer Envy:Envy of material wealth and long-range material securityaccrued by older members of the baby boom generation by virtue offortunate births.-- Douglas Coupland, Generation X: Tales for an AcceleratedCulture[rootServer_8_200 ~]#