From: Joey Hess Date: Fri, 4 Dec 2015 20:46:00 +0000 (-0400) Subject: comments X-Git-Tag: archive/raspbian/10.20250416-2+rpi1~1^2~320^2~184^2~92 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=e8ca01cbc0383c724f63a8fe7ba468278285335a;p=git-annex.git comments --- diff --git a/Command/Smudge.hs b/Command/Smudge.hs index 07a3e1805f..ddf81af437 100644 --- a/Command/Smudge.hs +++ b/Command/Smudge.hs @@ -39,6 +39,8 @@ seek :: SmudgeOptions -> CommandSeek seek o = commandAction $ (if cleanOption o then clean else smudge) (smudgeFile o) +-- Smudge filter is fed git file content, and if it's a pointer, should +-- emit the annex object content. smudge :: FilePath -> CommandStart smudge _file = do liftIO $ fileEncoding stdin @@ -53,6 +55,8 @@ smudge _file = do =<< catchMaybeIO (B.readFile content) stop +-- Clean filter decides if a file should be stored in the annex, and +-- outputs a pointer to its injested content. clean :: FilePath -> CommandStart clean file = do ifM (shouldAnnex file)