PINYIN-DEC(1)

NAME
pinyin-dec - decorate Pinyin text with its proper diacritics

SYNOPSIS
pinyin-dec [options] [string ...]

DESCRIPTION
This program converts numbered Hanyu Pinyin text into its proper form with diacritics. Input strings are read from command-line arguments, or if none are provided, the input text is read from standard input (stdin). Text that does not look like a Pinyin word is generally ignored, and is preserved in its original form in the output.

The program knows about six Pinyin tone numbers: 1 (high), 2 (rising), 3 (low), 4 (falling), and 0 or 5 (neutral). It also converts v or u: in Pinyin words into the proper form of ü. Capitalization also makes no difference, and pinyin-dec is able to handle Pinyin text regardless of its capitalization.

OPTIONS

-h, --help
    print usage information and then exit

-v, --verbose
    include information useful for debugging

EXIT STATUS
The exit status is 0 on normal termination, and 1 on error.

DIAGNOSTICS
Errors will print a message to the standard error stream. To enable stack traces for debugging, enable the “verbose” option.

EXAMPLES
$ pinyin-dec Han4yu3 Pin1yin1

Reformat numbered Pinyin given as command-line arguments.

$ pinyin-dec "Let's have some lu:4cha2 after class today."

Reformat numbered Pinyin while preserving the rest of the input.

$ cat mytext | pinyin-dec > fancy_text

Use pinyin-dec to reformat text read from the standard input.

BUGS
Please contact the author if any bugs are found, or file a bug report with the project. Incomplete or inaccurate documentation should be treated as a bug.

AUTHOR
yaoguai <http://lapislazulitexts.com/articles/pinyin_dec>