id = "enscript" name = "GNU Enscript" homepage = "https://www.gnu.org/software/enscript/" description = "A plain-text to PostScript, HTML, or RTF converter." executables = ["enscript"] [dotfiles] # GNU Enscript's manual documents ~/.enscriptrc as the per-user startup file # and ~/.enscript as the per-user resource directory. # https://www.gnu.org/software/enscript/enscript.html paths = ["~/.enscriptrc", "~/.enscript/"] secret = [] [commands] format = 1 label = "Convert text to PostScript" description = "Convert text or source files to PostScript with enscript, optionally with syntax highlighting, and write to a file or a printer. Fonts, filters, fancy headers, underlays and special escapes are left out." quality = "ai-draft" parser = { end_of_options = "--", interleave = "permute", long_equals = true, short_attached = true, short_bundles = true } [[commands.source]] id = "man" kind = "manual" url = "https://manpages.debian.org/bookworm/enscript/enscript.1.en.html" revision = "bookworm" evidence = """ -1, -2, -3, -4, -5, -6, -7, -8, -9, --columns=num Specify how many columns each page have. -a pages, --pages=pages Specify which pages are printed. -b header, --header=header Use the text header as a page header. -B, --no-header -C[start_line], --line-numbers[=start_line] -E[lang], --highlight[=lang] Highlight source code by creating a special input filter with the states program. -G, --fancy-header[=name] -j, --borders -p file, --output=file Leave the output to file file. If the file is `-', enscript sends the output to the standard output stdout. -P name, --printer=name Spool the output to the printer name. -q, --quiet, --silent -r, --landscape Print in the landscape mode; rotate page 90 degrees. -R, --portrait -t title, --title=title -T num, --tabsize=num Set the tabulator size to num characters. The default is 8. -M name, --media=name -n num, --copies=num """ [[commands.field]] id = "files" label = "Input files" description = "Leave empty to read standard input." type = "path" position = 0 multiple = true path = { kind = "file", role = "input", must_exist = true } sources = ["man"] [[commands.field]] id = "output" label = "Output file" description = "Write PostScript to this file instead of the default printer." type = "path" option = ["--output", "-p"] path = { kind = "file", role = "output", must_exist = false } effect = "overwrite" sources = ["man"] [[commands.field]] id = "printer" label = "Printer" description = "Spool the output to this named printer." type = "string" option = ["--printer", "-P"] sources = ["man"] [[commands.field]] id = "highlight" label = "Highlight language" description = "Syntax-highlight using this language name (enscript --help-highlight lists them)." type = "string" option = ["--highlight"] sources = ["man"] [[commands.field]] id = "columns" label = "Columns per page" type = "integer" option = ["--columns"] min = 1 sources = ["man"] [[commands.field]] id = "landscape" label = "Landscape" type = "boolean" option = ["--landscape", "-r"] sources = ["man"] [[commands.field]] id = "portrait" label = "Portrait" type = "boolean" option = ["--portrait", "-R"] sources = ["man"] [[commands.field]] id = "line_numbers" label = "Line numbers" type = "boolean" option = ["-C"] sources = ["man"] [[commands.field]] id = "no_header" label = "No page header" type = "boolean" option = ["--no-header", "-B"] sources = ["man"] [[commands.field]] id = "borders" label = "Page borders" type = "boolean" option = ["--borders", "-j"] sources = ["man"] [[commands.field]] id = "title" label = "Job title" type = "string" option = ["--title", "-t"] sources = ["man"] [[commands.field]] id = "tabsize" label = "Tab size" type = "integer" option = ["--tabsize", "-T"] min = 1 sources = ["man"] [[commands.field]] id = "media" label = "Media" description = "Paper size name, for example A4 or Letter." type = "string" option = ["--media", "-M"] suggestions = [{ value = "A4", label = "A4" }, { value = "Letter", label = "Letter" }] sources = ["man"] [[commands.field]] id = "copies" label = "Copies" type = "integer" option = ["--copies", "-n"] min = 1 sources = ["man"] [[commands.task]] id = "to-ps" label = "Convert to PostScript file" fields = ["files", "output", "highlight", "columns", "landscape", "line_numbers"] required = ["files", "output"] [[commands.task]] id = "print" label = "Print to a printer" fields = ["files", "printer", "highlight", "copies", "media"] required = ["files", "printer"] [[commands.group]] id = "basic" label = "Basic" fields = ["files", "output", "printer", "highlight", "columns", "landscape", "line_numbers"] [[commands.group]] id = "advanced" label = "Advanced" fields = ["portrait", "no_header", "borders", "title", "tabsize", "media", "copies"]