cseverino / qlcolorcode

Automatically exported from code.google.com/p/qlcolorcode
0 stars 0 forks source link

'Highlight: unknown source file extension "xxx"' displayed at the top of the preview of unrecognised files #37

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
If you quicklook a file that highlight doesn't recognise, (e.g. a .xib) then at 
the top of the preview, the message 'Highlight: 
unknown source file extension "xib"' is displayed, followed by a plain text 
rendering of the file.

Redirecting standard error to /dev/null seems to fix this. I changed the last 
five lines of colorize.sh from:
setopt no_err_exit
go4it
# Uh-oh, it didn't work.  Fall back to rendering the file as plain
lang=txt
go4it

to:

setopt no_err_exit
go4it 2>/dev/null
# Uh-oh, it didn't work.  Fall back to rendering the file as plain
lang=txt
go4it

and it seems to do the trick.

Original issue reported on code.google.com by nshutchi...@gmail.com on 21 May 2009 at 8:52

GoogleCodeExporter commented 8 years ago
That's semi-intentional.  I want users to know why their files aren't being 
highlighted.  But it could be prettier, I 
suppose.

Original comment by n8gray@gmail.com on 1 Jun 2009 at 5:54

GoogleCodeExporter commented 8 years ago
That's semi-intentional.  I want users to know why their files aren't being 
highlighted.  But it could be prettier, I 
suppose.

Original comment by n8gray@gmail.com on 1 Jun 2009 at 5:55

GoogleCodeExporter commented 8 years ago
I get a similar message, except that the rest of the output completely missing.
It is the base name of the file, not its contents, nor its extension
The problem may be a "%" in the file name.
For example, try a file with name "%.txt" (without the quotes.

cat: (null): No such file or directory highlight: Unknown source file extension 
"(null)". cat: (null): No such file or 
directory

Original comment by ttrtil...@gmail.com on 27 Jul 2009 at 10:00

GoogleCodeExporter commented 8 years ago
This doesn't happen anymore in 2.0.1.  This means you need to look in 
Console.app to find out why a file didn't 
get highlighted but it also means you can get more debugging info when the 
preview totally fails to generate.

Original comment by n8gray@gmail.com on 18 Sep 2009 at 6:08