Add -- before %f in the smudge/clean filter configuration
To support filenames starting with dashes. To update the config of existing repositories, you can re-run git-annex init. Perhaps it should check every time for the old config and update it, but that has several problems: - read-only repos - unexpected commands like `git annex find` changing git configs might be surprising behavior Since filenames starting with dashes are not super common and the user can re-init easily enough if their repo needs fixed, I went for the simplest fix.
This commit is contained in:
parent
e7f3e2a937
commit
60ca3ce043
4 changed files with 34 additions and 2 deletions
|
@ -24,8 +24,8 @@ configureSmudgeFilter = unlessM (fromRepo Git.repoIsLocalBare) $ do
|
|||
-- Avoid that problem by running git status now.
|
||||
inRepo $ Git.Command.runQuiet [Param "status", Param "--porcelain"]
|
||||
|
||||
setConfig (ConfigKey "filter.annex.smudge") "git-annex smudge %f"
|
||||
setConfig (ConfigKey "filter.annex.clean") "git-annex smudge --clean %f"
|
||||
setConfig (ConfigKey "filter.annex.smudge") "git-annex smudge -- %f"
|
||||
setConfig (ConfigKey "filter.annex.clean") "git-annex smudge --clean -- %f"
|
||||
lf <- Annex.fromRepo Git.attributesLocal
|
||||
gf <- Annex.fromRepo Git.attributes
|
||||
lfs <- readattr lf
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue