]> dgit.raspbian.org Git - git-annex.git/commitdiff
Revert "disable filter.annex.process in restagePointerFile"
authorJoey Hess <joeyh@joeyh.name>
Fri, 5 Nov 2021 16:43:33 +0000 (12:43 -0400)
committerJoey Hess <joeyh@joeyh.name>
Fri, 5 Nov 2021 16:43:33 +0000 (12:43 -0400)
This reverts commit afe327ac4947d6d32ff888e7485509be03d9baaf.

Unfortunately, disabling it by setting it to "" does not work, git
then ignores filter.annex.smudge/clean, and does not pass files through
git-annex at all.

I don't think there is a way to temporarily disable this git config
from the git command line. Which seems like a bug in git.

So, it may be more expensive than anticipated to enable
filter.annex.process, since git checkout etc will pipe all annexed files
being checked out through it.

Annex/Link.hs

index 9e019d7d6a9fe6111ba881506f20cf60ef67e81c..878228788df195657ba3a8eac7a98e1e87b4ce03 100644 (file)
@@ -221,18 +221,10 @@ restagePointerFile (Restage True) f orig = withTSDelta $ \tsd ->
                        let updatetmpindex = do
                                r' <- liftIO $ Git.Env.addGitEnv r Git.Index.indexEnv
                                        =<< Git.Index.indexEnvVal (toRawFilePath tmpindex)
+                               -- Avoid git warning about CRLF munging.
                                let r'' = r' { gitGlobalOpts = gitGlobalOpts r' ++
-                                       -- Avoid git warning about CRLF munging.
                                        [ Param "-c"
                                        , Param $ "core.safecrlf=" ++ boolConfig False
-                                       -- Avoid using git-annex
-                                       -- filter-process, because git
-                                       -- pipes the content of annexed
-                                       -- files into it; using
-                                       -- git-annex smudge --clean is
-                                       -- probably faster.
-                                       , Param "-c"
-                                       , Param $ "filter.annex.process="
                                        ] }
                                runsGitAnnexChildProcessViaGit' r'' $ \r''' ->
                                        liftIO $ Git.UpdateIndex.refreshIndex r''' $ \feed ->