Linux command
preconv 命令
文件
复制后可按需替换文件名、目录或参数。
常用示例
Convert encoding for groff
preconv [file]
Specify input encoding
preconv -e [utf-8] [file]
Debug mode
preconv -d [file]
说明
preconv is a groff preprocessor that converts input files from various character encodings (UTF-8, Latin-1, etc.) into a format that groff can process. It translates non-ASCII characters into groff escape sequences, enabling groff to handle Unicode and other multi-byte encodings. The tool is typically invoked automatically by groff when needed, but can also be used explicitly in preprocessing pipelines. It detects the input encoding from BOM markers, coding tags, or locale settings.
参数
- -e _ENCODING_
- Input encoding.
- -d
- Debug output.
- -r
- Do not add .lf lines.
FAQ
What is the preconv command used for?
preconv is a groff preprocessor that converts input files from various character encodings (UTF-8, Latin-1, etc.) into a format that groff can process. It translates non-ASCII characters into groff escape sequences, enabling groff to handle Unicode and other multi-byte encodings. The tool is typically invoked automatically by groff when needed, but can also be used explicitly in preprocessing pipelines. It detects the input encoding from BOM markers, coding tags, or locale settings.
How do I run a basic preconv example?
Run `preconv [file]` in a terminal, then adjust file names, paths, flags, or remote targets for your system.
What does -e _ENCODING_ do in preconv?
Input encoding.