diff options
author | Joey Hess <joey@kitenet.net> | 2013-03-03 13:39:07 -0400 |
---|---|---|
committer | Joey Hess <joey@kitenet.net> | 2013-03-03 13:39:07 -0400 |
commit | 9bce151df7b073c5f2507ea15ca2237814ae9248 (patch) | |
tree | 653751d0c0f70475fc1bd7e89d0465fa76b8c630 /Config.hs | |
parent | e4fc1c290dba197a16c0e1cc0ff07ecfe2ee542b (diff) |
git subcommand cleanup
Pass subcommand as a regular param, which allows passing git parameters
like -c before it. This was already done in the pipeing set of functions,
but not the command running set.
Diffstat (limited to 'Config.hs')
-rw-r--r-- | Config.hs | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -23,13 +23,13 @@ getConfig (ConfigKey key) def = fromRepo $ Git.Config.get key def {- Changes a git config setting in both internal state and .git/config -} setConfig :: ConfigKey -> String -> Annex () setConfig (ConfigKey key) value = do - inRepo $ Git.Command.run "config" [Param key, Param value] + inRepo $ Git.Command.run [Param "config", Param key, Param value] Annex.changeGitRepo =<< inRepo Git.Config.reRead {- Unsets a git config setting. (Leaves it in state currently.) -} unsetConfig :: ConfigKey -> Annex () -unsetConfig (ConfigKey key) = inRepo $ Git.Command.run "config" - [Param "--unset", Param key] +unsetConfig (ConfigKey key) = inRepo $ Git.Command.run + [Param "config", Param "--unset", Param key] {- A per-remote config setting in git config. -} remoteConfig :: Git.Repo -> UnqualifiedConfigKey -> ConfigKey |