diff options
author | Daniel Silverstone <dsilvers@digital-scurf.org> | 2012-06-17 16:24:25 +0100 |
---|---|---|
committer | Daniel Silverstone <dsilvers@digital-scurf.org> | 2012-06-17 16:24:25 +0100 |
commit | cc01f0632e76f45b22f97de23c5fc45b0428760b (patch) | |
tree | af85944c3feca868fcec901796fa9406bd1a02a7 | |
parent | d8c9ff2625e6095dd380564d0f44d97f83c3000a (diff) | |
download | gitano-cc01f0632e76f45b22f97de23c5fc45b0428760b.tar.gz |
GIT.REPOSITORY: Trivial config interface
-rw-r--r-- | lib/gitano/git/repository.lua | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/lib/gitano/git/repository.lua b/lib/gitano/git/repository.lua index ad3de6a..6ea0afb 100644 --- a/lib/gitano/git/repository.lua +++ b/lib/gitano/git/repository.lua @@ -202,6 +202,15 @@ function repomethod:symbolic_ref(name, toref) return false, "argh" end +function repomethod:config(confname, value) + -- Trivial interface to key/value in config + if not value then + return self:gather("config", confname) + else + self:gather("config", "--replace-all", confname, value) + end +end + local repomt = { __index = repomethod, __tostring = _repotostring |