darcs repository web UI and hosting app. This is the main darcsden trunk, which also runs hub.darcs.net. (https://hub.darcs.net)
#3browsing binary files, eg images, gives an error
Eg: http://hub.darcs.net/simon/darcsden/browse/public/images/added.gif
Currently highlighter is run on the content of all files but it expects utf-8-encoded data, at least in the way that it is called here.
http://hub.darcs.net/simon/darcsden/browse/src/DarcsDen/Handler/Repository.hs#L-154
http://hub.darcs.net/simon/darcsden/browse/src/DarcsDen/Handler/Repository/Util.hs#L-35
- description updated
- description updated
This attempted fix in browseRepo fails to catch the exception:
(_, Just source) -> do highlighted <- liftIO $ (return $ highlightBlob (last f) (strictLBS source)) `E.catch` (\(_ :: SomeException) -> return $ BS8.pack $ ("Could not highlight, here is the <a href=\"raw/"++last f++"\">raw file content</a>"))
- status set to closed
Due to laziness. Fixed now.