trust, untrust, semitrust, dead: Warn when the trust level is overridden in .git/config.

This commit is contained in:
Joey Hess 2014-02-20 15:17:39 -04:00
parent 20c5bf8b41
commit 21610294da
3 changed files with 8 additions and 0 deletions

View file

@ -10,6 +10,7 @@ module Command.Trust where
import Common.Annex
import Command
import qualified Remote
import Types.TrustLevel
import Logs.Trust
import Logs.Group
@ -34,4 +35,7 @@ trustCommand cmd level = withWords start
trustSet uuid level
when (level == DeadTrusted) $
groupSet uuid S.empty
l <- lookupTrust uuid
when (l /= level) $
warning $ "This remote's trust level is locally overridden to " ++ showTrustLevel l ++ " via git config."
next $ return True