debugging improvements

add timestamps to debug messages

Add lots of debug output in the assistant's threads.
This commit is contained in:
Joey Hess 2012-07-20 19:29:59 -04:00
parent 42e73537d1
commit b48d7747a3
11 changed files with 175 additions and 44 deletions

21
Assistant/Common.hs Normal file
View file

@ -0,0 +1,21 @@
{- Common infrastructure for the git-annex assistant threads.
-
- Copyright 2012 Joey Hess <joey@kitenet.net>
-
- Licensed under the GNU GPL version 3 or higher.
-}
module Assistant.Common (
module X,
ThreadName,
debug
) where
import Common.Annex as X
import System.Log.Logger
type ThreadName = String
debug :: ThreadName -> [String] -> IO ()
debug threadname ws = debugM threadname $ unwords $ (threadname ++ ":") : ws