I've noticed that reviewboard doesn't detect the language of a script from the #! line -- it appears to rely on the file extension. Would it be possible to use the #! line to detect the language type for syntax highlighting?
We use Pygments for our syntax highlighting. We can either tell it to guess the type (in which case it'll likely look at #!) or by file extension. We use the file extension because Pygments used to be horribly slow with some file types (XML, for example). I'm not sure if this has since been fixed. We can certainly experiment with it, but I'd like to add caching of the lexer type for the highlighting before we do that, so we only have to guess it once.
- Type-Defect - Priority-Medium + Type-Enhancement + Priority-Low + Component-DiffViewer
- Confirmed + PendingReview
Fixed in release-2.0.x (944a86d). This will ship in 2.0.21 and 2.5. Thanks!
- PendingReview + Fixed