diff options
author | Joey Hess <joey@kitenet.net> | 2011-12-20 16:31:59 -0400 |
---|---|---|
committer | Joey Hess <joey@kitenet.net> | 2011-12-20 16:42:35 -0400 |
commit | 1c28237e0c7a920823354d4a10381b300aeb95e0 (patch) | |
tree | 06fd518394b3e94b07e4ffd71f5f21dabeba1e2f /Command/Map.hs | |
parent | 9308a60bb2457568bf600901f6dad5c96d6b53ba (diff) |
map: --fast disables use of dot to display map
Generally useful, and allows the test suite to test it.
Diffstat (limited to 'Command/Map.hs')
-rw-r--r-- | Command/Map.hs | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/Command/Map.hs b/Command/Map.hs index da129c8f6..0f32e1130 100644 --- a/Command/Map.hs +++ b/Command/Map.hs @@ -16,6 +16,7 @@ import qualified Git import qualified Git.Url import qualified Git.Config import qualified Git.Construct +import qualified Annex import Annex.UUID import Logs.UUID import Logs.Trust @@ -40,10 +41,14 @@ start = do trusted <- trustGet Trusted liftIO $ writeFile file (drawMap rs umap trusted) - showLongNote $ "running: dot -Tx11 " ++ file - showOutput - r <- liftIO $ boolSystem "dot" [Param "-Tx11", File file] - next $ next $ return r + next $ next $ do + fast <- Annex.getState Annex.fast + if fast + then return True + else do + showLongNote $ "running: dot -Tx11 " ++ file + showOutput + liftIO $ boolSystem "dot" [Param "-Tx11", File file] where file = "map.dot" |