diff options
author | Joey Hess <joey@kitenet.net> | 2014-05-16 12:58:50 -0400 |
---|---|---|
committer | Joey Hess <joey@kitenet.net> | 2014-05-16 12:58:50 -0400 |
commit | 1143e6128d178005971c9eb3fd9ad9918a1c7be1 (patch) | |
tree | 71cfbcba1975761865ec53d210c14ae2aa4494f6 /Remote/Git.hs | |
parent | 322a89b0d1555d47bbde00d7ca9cba161d06e040 (diff) |
show a much longer message when annex-ignore is automatically set, to help the user fix their problem
Diffstat (limited to 'Remote/Git.hs')
-rw-r--r-- | Remote/Git.hs | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/Remote/Git.hs b/Remote/Git.hs index 83964e180..2a6ed0c77 100644 --- a/Remote/Git.hs +++ b/Remote/Git.hs @@ -197,7 +197,7 @@ tryGitConfigRead r ) case v of Left _ -> do - set_ignore "not usable by git-annex" + set_ignore "not usable by git-annex" False return r Right r' -> do -- Cache when http remote is not bare for @@ -225,15 +225,18 @@ tryGitConfigRead r configlist_failed = case Git.remoteName r of Nothing -> return r Just n -> do - whenM (inRepo $ Git.Command.runBool [Param "fetch", Param "--quiet", Param n]) $ - set_ignore "does not have git-annex installed" + whenM (inRepo $ Git.Command.runBool [Param "fetch", Param "--quiet", Param n]) $ do + set_ignore "does not have git-annex installed" True return r - set_ignore msg = do + set_ignore msg longmessage = do let k = "annex-ignore" case Git.remoteName r of Nothing -> noop - Just n -> warning $ "Remote " ++ n ++ " " ++ msg ++ "; setting " ++ k + Just n -> do + warning $ "Remote " ++ n ++ " " ++ msg ++ "; setting " ++ k + when longmessage $ + warning $ "This could be a problem with the git-annex installation on the remote. Please make sure that git-annex-shell is available in PATH when you ssh into the remote. Once you have fixed the git-annex installation, run: git config remote." ++ n ++ "." ++ k ++ " false" setremote k (Git.Config.boolConfig True) setremote k v = case Git.remoteName r of |