Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 244334 - app-text/enscript-1.6.4-r2 can't detect php scripts with -E
Summary: app-text/enscript-1.6.4-r2 can't detect php scripts with -E
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All All
: High enhancement (vote)
Assignee: Printing Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-10-25 16:57 UTC by Paul McDermott
Modified: 2011-06-02 10:48 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Paul McDermott 2008-10-25 16:57:00 UTC
Enscript should be able to work out which kind of file it is doing syntax highlighting for, without specifying the language after the '-E' flag. 'enscript -Ephp file.php' produces highlighted output, 'enscript -E file.php' does not.

Reproducible: Always

Steps to Reproduce:
1.enscript -E any_file.php
2.
3.

Actual Results:  
No syntax highlighting

Expected Results:  
Syntax highlighting

The following patch will update the enscript.st file to fix. Would be great if this could be included in the ebuild:

--- /usr/share/enscript/hl/enscript.st 2008-10-25 17:11:07.000000000 +0100
+++ /usr/share/enscript/hl/enscript.st 2008-10-25 17:11:37.000000000 +0100
@@ -512,6 +512,7 @@
   /\.(ebuild|eclass)$/                         ebuild;
   /\.wmlscript$/                               wmlscript;
   /\.wmls$/                                    wmlscript;
+  /\.php$/                                     php;
   /^.*$/                                       passthrough;
 }
Comment 1 Andreas K. Hüttel archtester gentoo-dev 2011-06-02 10:48:19 UTC
Patch added in 1.6.5.2-r1. Thanks!