tldr/pages/common/enscript.md

25 lines
905 B
Markdown
Raw Normal View History

2018-10-12 21:11:09 +03:00
# enscript
2019-08-04 17:05:15 +03:00
> Convert text files to PostScript, HTML, RTF, ANSI, and overstrikes.
2019-06-08 03:04:00 +03:00
> More information: <https://www.gnu.org/software/enscript>.
2018-10-12 21:11:09 +03:00
2019-08-04 17:05:15 +03:00
- Generate a PostScript file from a text file:
2018-10-12 21:11:09 +03:00
`enscript {{path/to/input_file}} --output={{path/to/output_file}}`
2019-08-04 17:05:15 +03:00
- Generate a file in a different language than PostScript:
2018-10-12 21:11:09 +03:00
2019-08-04 17:05:15 +03:00
`enscript {{path/to/input_file}} --language={{html|rtf|...}} --output={{path/to/output_file}}`
2018-10-12 21:11:09 +03:00
2019-08-04 17:05:15 +03:00
- Generate a PostScript file with a landscape layout, splitting the page into columns (maximum 9):
2018-10-12 21:11:09 +03:00
`enscript {{path/to/input_file}} --columns={{num}} --landscape --output={{path/to/output_file}}`
2019-08-04 17:05:15 +03:00
- Display available syntax highlighting languages and file formats:
2018-10-12 21:11:09 +03:00
`enscript --help-highlight`
2019-08-04 17:05:15 +03:00
- Generate a PostScript file with syntax highlighting and color for a specified language:
2018-10-12 21:11:09 +03:00
`enscript {{path/to/input_file}} --color=1 --highlight={{language}} --output={{path/to/output_file}}`