Linux command
cowsay 命令
趣味
复制后可按需替换文件名、目录或参数。
常用示例
Say
cowsay ["Hello World"]
Think
cowthink ["Hmm..."]
Different
cowsay -f [dragon] ["Message"]
List
cowsay -l
Dead
cowsay -d ["Message"]
说明
cowsay generates ASCII art of a cow saying a message. It's a whimsical program that displays text in a speech bubble with various animal ASCII art, commonly used for fun messages, fortune quotes, or MOTD displays. The program supports multiple "cow files" representing different animals and characters, each with their own ASCII art. Messages can be displayed as speech (cowsay) or thoughts (cowthink), and the cow's appearance can be modified with different eye and tongue states. cowsay has become an iconic part of Unix culture, often paired with fortune for random quotes or lolcat for colorful output. While purely for entertainment, it's widely used in login messages, shell prompts, and documentation to add personality to command-line interfaces.
参数
- -f _cowfile_
- Use the specified cow file.
- -l
- List available cow files on the current COWPATH.
- -e _eyes_
- Set eye appearance (first two characters; default oo).
- -T _tongue_
- Set tongue appearance (two characters; default blank).
- -W _width_
- Word-wrap column (default 40).
- -n
- Disable word wrapping; preserve the input as-is.
- -b
- Borg mode (eyes ==).
- -d
- Dead cow mode (eyes XX, tongue U).
- -g
- Greedy mode (eyes $$).
- -p
- Paranoid mode (eyes @@).
- -s
- Stoned mode (eyes **\*\*, tongue U**).
- -t
- Tired mode (eyes --).
- -w
- Wired mode (eyes OO).
- -y
- Youthful mode (eyes ..).
FAQ
What is the cowsay command used for?
cowsay generates ASCII art of a cow saying a message. It's a whimsical program that displays text in a speech bubble with various animal ASCII art, commonly used for fun messages, fortune quotes, or MOTD displays. The program supports multiple "cow files" representing different animals and characters, each with their own ASCII art. Messages can be displayed as speech (cowsay) or thoughts (cowthink), and the cow's appearance can be modified with different eye and tongue states. cowsay has become an iconic part of Unix culture, often paired with fortune for random quotes or lolcat for colorful output. While purely for entertainment, it's widely used in login messages, shell prompts, and documentation to add personality to command-line interfaces.
How do I run a basic cowsay example?
Run `cowsay ["Hello World"]` in a terminal, then adjust file names, paths, flags, or remote targets for your system.
What does -f _cowfile_ do in cowsay?
Use the specified cow file.