diff options
author | 2012-07-17 12:27:06 -0400 | |
---|---|---|
committer | 2012-07-17 12:27:06 -0400 | |
commit | f5f88794713ebbbbc177d064f074a80ca23e9b79 (patch) | |
tree | 977c789d3fa62af7f2b4a6c37f8ae32c9ed4e7fe | |
parent | dc2e0d0d9bc8d5fd106e7c1c8d871498f8012233 (diff) |
map: Write map.dot to .git/annex, which avoids watch trying to annex it.
-rw-r--r-- | Command/Map.hs | 4 | ||||
-rw-r--r-- | debian/changelog | 1 | ||||
-rw-r--r-- | doc/bugs/__34__git_annex_watch__34___adds_map.dot.mdwn | 6 | ||||
-rw-r--r-- | test.hs | 3 |
4 files changed, 8 insertions, 6 deletions
diff --git a/Command/Map.hs b/Command/Map.hs index 65e28945f..0773f6828 100644 --- a/Command/Map.hs +++ b/Command/Map.hs @@ -39,6 +39,8 @@ start = do umap <- uuidMap trusted <- trustGet Trusted + + file <- (</>) <$> fromRepo gitAnnexDir <*> pure "map.dot" liftIO $ writeFile file (drawMap rs umap trusted) next $ next $ @@ -49,8 +51,6 @@ start = do showOutput liftIO $ boolSystem "dot" [Param "-Tx11", File file] ) - where - file = "map.dot" {- Generates a graph for dot(1). Each repository, and any other uuids, are - displayed as a node, and each of its remotes is represented as an edge diff --git a/debian/changelog b/debian/changelog index 5eaf9d52e..f90763aca 100644 --- a/debian/changelog +++ b/debian/changelog @@ -11,6 +11,7 @@ git-annex (3.20120630) UNRELEASED; urgency=low faster than forking the more optimised external program. * SHAnE backends are now smarter about composite extensions, such as .tar.gz Closes: #680450 + * map: Write map.dot to .git/annex, which avoids watch trying to annex it. -- Joey Hess <joeyh@debian.org> Sun, 01 Jul 2012 15:04:37 -0400 diff --git a/doc/bugs/__34__git_annex_watch__34___adds_map.dot.mdwn b/doc/bugs/__34__git_annex_watch__34___adds_map.dot.mdwn index d6dc3e42d..94c495735 100644 --- a/doc/bugs/__34__git_annex_watch__34___adds_map.dot.mdwn +++ b/doc/bugs/__34__git_annex_watch__34___adds_map.dot.mdwn @@ -1,4 +1,8 @@ -"git annex watch" will add the file generated by "git annex map", which is probably not intended. Shouldn’t this file be created in /tmp or .git/annex/ or somewhere else? +"git annex watch" will add the file generated by "git annex map", which is +probably not intended. Shouldn’t this file be created in /tmp or +.git/annex/ or somewhere else? + +> Indeed, so [[done]] --[[Joey]] /tmp $ cd test/ /tmp/test $ git init @@ -550,9 +550,6 @@ test_map = "git-annex map" ~: intmpclonerepo $ do git_annex "describe" ["origin", "origin repo"] @? "describe 2 failed" -- --fast avoids it running graphviz, not a build dependency git_annex "map" ["--fast"] @? "map failed" - doesFileExist "map.dot" @? "map.dot not generated" - c <- readFile "map.dot" - ("this repo" `isInfixOf` c && "origin repo" `isInfixOf` c) @? ("map.dot bad content: " ++ c) test_uninit :: Test test_uninit = "git-annex uninit" ~: intmpclonerepo $ do |