fortunes
A collection of fortune database files for Chinese users.
Fortune is a Unix command-line tool that displays a random quote or saying every time you run it. Instead of seeing the same message twice, it pulls from a database of thousands of quotations, so there's always something new. This repository is a curated collection of fortune databases, especially tailored for Chinese-speaking users.
The repository contains five separate databases you can use. There's a general English quotes collection with over 5,000 items, a much larger Chinese quotes database with nearly 26,000 entries, and three specialized Chinese collections: classical poems from the Tang Dynasty (313 poems), poems from the Song Dynasty (95 poems), and a collection of diet-related proverbs (123 items). You install the tool itself through your system's package manager, then copy these database files to a standard location on your computer. Once set up, running the fortune command pulls a random item from whichever database you point it to.
People use this for a few practical reasons. The most common is adding a daily inspirational quote to your shell startup—so every time you open a terminal window, you see a random saying before you start working. It's a small way to get a moment of reflection or a smile while working at the command line. Developers, system administrators, and anyone who spends time in the terminal might enjoy this. For Chinese users especially, this repository is valuable because it includes culturally relevant quotes and classical poetry rather than just English content.
The setup is straightforward: install the fortune program (which most Linux and Mac users can do with a single package manager command), download the database files from this repository, and move them to the right folder. You can even create your own fortune database by writing items separated by percent signs and running a simple indexing command. The flexibility to mix multiple databases and weight them differently means you can customize which quotes appear more or less frequently when you run the command.