fix fastDebug to check if debugging is actually enabled
Had to add to AnnexRead an indication of whether debugging is enabled. Could have just made setupConsole not install a debug output action that outputs, and have enableDebug be what installs that, but then in the common case where there is no debug selector, and so all debug output is selected, it would run the debug output action every time, which entails an IORef access. Which would make fastDebug too slow..
This commit is contained in:
parent
13c090b37a
commit
2e9d4ac754
5 changed files with 19 additions and 14 deletions
|
@ -59,7 +59,7 @@ git_annex_shell cs r command params fields
|
|||
dir = Git.repoPath r
|
||||
shellcmd = "git-annex-shell"
|
||||
getshellopts = do
|
||||
debugenabled <- annexDebug <$> Annex.getGitConfig
|
||||
debugenabled <- Annex.getRead Annex.debugenabled
|
||||
let params' = if debugenabled
|
||||
then Param "--debug" : params
|
||||
else params
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue