few fixes
This commit is contained in:
parent
2daa6161fd
commit
5a5845e490
|
@ -29,7 +29,7 @@ class Project < ActiveRecord::Base
|
|||
:uniqueness => true,
|
||||
:format => { :with => /^[a-zA-Z0-9_\-]*$/,
|
||||
:message => "only letters, digits & '_' '-' allowed" },
|
||||
:length => { :within => 3..16 }
|
||||
:length => { :within => 3..255 }
|
||||
|
||||
validates :owner,
|
||||
:presence => true
|
||||
|
|
|
@ -24,7 +24,7 @@
|
|||
%td
|
||||
.left= f.label :code
|
||||
%cite.right http://yourserver/
|
||||
%td= f.text_field :code, :placeholder => "example (3..12 symbols only)"
|
||||
%td= f.text_field :code, :placeholder => "example"
|
||||
.field
|
||||
= f.label :description
|
||||
%br/
|
||||
|
|
|
@ -27,13 +27,14 @@ class Gitosis
|
|||
def configure
|
||||
status = Timeout::timeout(20) do
|
||||
File.open(File.join(Dir.tmpdir,"gitlabhq-gitosis.lock"), "w+") do |f|
|
||||
f.flock(File::LOCK_EX)
|
||||
|
||||
pull
|
||||
yield(self)
|
||||
push
|
||||
|
||||
f.flock(File::LOCK_UN)
|
||||
begin
|
||||
f.flock(File::LOCK_EX)
|
||||
pull
|
||||
yield(self)
|
||||
push
|
||||
ensure
|
||||
f.flock(File::LOCK_UN)
|
||||
end
|
||||
end
|
||||
end
|
||||
rescue Exception => ex
|
||||
|
|
Loading…
Reference in a new issue