@@ -77,6 +77,7 @@ import Text.Pandoc.Logging
7777import Text.Parsec (ParsecT)
7878import qualified Text.Pandoc.Compat.Time as IO (getCurrentTime)
7979import Text.Pandoc.MIME (MimeType, getMimeType)
80+import Data.Char (toLower)
8081import Data.Time.Clock.POSIX ( utcTimeToPOSIXSeconds
8182 , posixSecondsToUTCTime
8283 , POSIXTime )
@@ -106,7 +107,6 @@ import System.IO.Error
106107import System.IO (stderr)
107108import qualified Data.Map as M
108109import Text.Pandoc.Error
109−import Text.Printf (printf)
110110
111111class (Functor m, Applicative m, Monad m, MonadError PandocError m)
112112 => PandocMonad m where
@@ -251,17 +251,17 @@ instance PandocMonad PandocIO where
251251 getCommonState = PandocIO $ lift get
252252 putCommonState x = PandocIO $ lift $ put x
253253 logOutput msg = liftIO $ do
254− UTF8.hPutStr stderr $ printf "%-7s " (show (messageVerbosity msg))
255− hangingIndent 2 $ lines $ showLogMessage msg
254+ UTF8.hPutStr stderr $ "[" ++
255+ (map toLower $ show (messageVerbosity msg)) ++ "] "
256+ alertIndent $ lines $ showLogMessage msg
256257
257−hangingIndent :: Int -> [String] -> IO ()
258−hangingIndent _level [] = return ()
259−hangingIndent level (l:ls) = do
258+alertIndent :: [String] -> IO ()
259+alertIndent [] = return ()
260+alertIndent (l:ls) = do
260261 UTF8.hPutStrLn stderr l
261262 mapM_ go ls
262− where go l' = do UTF8.hPutStr stderr ind
263+ where go l' = do UTF8.hPutStr stderr "! "
263264 UTF8.hPutStrLn stderr l'
264− ind = replicate level ' '
265265
266266-- | Specialized version of parseURIReference that disallows
267267-- single-letter schemes. Reason: these are usually windows absolute