summaryrefslogtreecommitdiff
path: root/git-mirror-gitlab-ce
diff options
context:
space:
mode:
authorLuke Shumaker <lukeshu@sbcglobal.net>2016-12-15 16:01:03 -0500
committerLuke Shumaker <lukeshu@sbcglobal.net>2016-12-15 16:01:03 -0500
commit71dc3b30449a4574455ff7eb9c390e30ad52ac4a (patch)
tree2f294aeb109bd4049876a598eaf9a43379c1fb90 /git-mirror-gitlab-ce
parenta043ff3446cce1e7000cf76bc227f9260199fce3 (diff)
fix (wip)
Diffstat (limited to 'git-mirror-gitlab-ce')
-rwxr-xr-xgit-mirror-gitlab-ce16
1 files changed, 13 insertions, 3 deletions
diff --git a/git-mirror-gitlab-ce b/git-mirror-gitlab-ce
index feb8602..1c628e8 100755
--- a/git-mirror-gitlab-ce
+++ b/git-mirror-gitlab-ce
@@ -121,7 +121,7 @@ class GitLabCE < GitMirrorBackend
end
info = JSON::parse(res.body)
end
- return self.get_meta
+ return nil
end
def repo_mode
@@ -133,6 +133,7 @@ class GitLabCE < GitMirrorBackend
def cmd_config(*args)
args.each do |arg|
key, val = arg.split('=', 2)
+ key = key.gsub('-', '_')
case key
when "apiurl"
val = URI(val)
@@ -142,19 +143,28 @@ class GitLabCE < GitMirrorBackend
end
@config[key] = val
end
+ return nil
end
def cmd_get_meta(project_id)
- return self.project(project_id).get_meta()
+ map = self.project(project_id).get_meta()
+ ret = {}
+ map.each do |key,val|
+ key = key.gsub('_', '-')
+ map[key] = val
+ end
+ return ret
end
def cmd_set_meta(project_id, *pairs)
map = {}
pairs.each do |pair|
key, val = arg.split('=', 2)
+ key = key.gsub('-', '_')
map[key] = val
end
- return self.project(project_id).set_meta(map)
+ self.project(project_id).set_meta(map)
+ return nil
end
def cmd_push_url(project_id)