diff options
author | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2013-02-05 10:42:01 +0200 |
---|---|---|
committer | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2013-02-05 10:42:01 +0200 |
commit | 23c76715a8a3fcf2fca20891d709c63ba4131fa5 (patch) | |
tree | 7abfe9881e932e36a5c268d0e286a4b126dff55e /lib/gitlab_projects.rb | |
parent | c902d83b45ac981d186540dfea80a887882501cf (diff) | |
download | gitlab-shell-23c76715a8a3fcf2fca20891d709c63ba4131fa5.tar.gz |
let test adding repo for real
Diffstat (limited to 'lib/gitlab_projects.rb')
-rw-r--r-- | lib/gitlab_projects.rb | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/gitlab_projects.rb b/lib/gitlab_projects.rb index ae8cb2d..83f542a 100644 --- a/lib/gitlab_projects.rb +++ b/lib/gitlab_projects.rb @@ -3,7 +3,7 @@ require 'fileutils' require_relative 'gitlab_config' class GitlabProjects - attr_accessor :project_name + attr_reader :project_name, :full_path def initialize @command = ARGV.shift @@ -25,12 +25,12 @@ class GitlabProjects protected def add_project - FileUtils.mkdir_p(@full_path, mode: 0770) - cmd = "cd #{@full_path} && git init --bare && ln -s #{@hook_path} #{@full_path}/hooks/post-receive" + FileUtils.mkdir_p(full_path, mode: 0770) + cmd = "cd #{full_path} && git init --bare && ln -s #{@hook_path} #{full_path}/hooks/post-receive" system(cmd) end def rm_project - FileUtils.rm_rf(@full_path) + FileUtils.rm_rf(full_path) end end |