Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
gitlab-ce
Commits
5a5845e4
Commit
5a5845e4
authored
Oct 18, 2011
by
gitlabhq
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
few fixes
parent
2daa6161
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
10 additions
and
9 deletions
+10
-9
app/models/project.rb
app/models/project.rb
+1
-1
app/views/projects/_form.html.haml
app/views/projects/_form.html.haml
+1
-1
lib/gitosis.rb
lib/gitosis.rb
+8
-7
No files found.
app/models/project.rb
View file @
5a5845e4
...
@@ -29,7 +29,7 @@ class Project < ActiveRecord::Base
...
@@ -29,7 +29,7 @@ class Project < ActiveRecord::Base
:uniqueness
=>
true
,
:uniqueness
=>
true
,
:format
=>
{
:with
=>
/^[a-zA-Z0-9_\-]*$/
,
:format
=>
{
:with
=>
/^[a-zA-Z0-9_\-]*$/
,
:message
=>
"only letters, digits & '_' '-' allowed"
},
:message
=>
"only letters, digits & '_' '-' allowed"
},
:length
=>
{
:within
=>
3
..
16
}
:length
=>
{
:within
=>
3
..
255
}
validates
:owner
,
validates
:owner
,
:presence
=>
true
:presence
=>
true
...
...
app/views/projects/_form.html.haml
View file @
5a5845e4
...
@@ -24,7 +24,7 @@
...
@@ -24,7 +24,7 @@
%td
%td
.left
=
f
.
label
:code
.left
=
f
.
label
:code
%cite
.right
http://yourserver/
%cite
.right
http://yourserver/
%td
=
f
.
text_field
:code
,
:placeholder
=>
"example
(3..12 symbols only)
"
%td
=
f
.
text_field
:code
,
:placeholder
=>
"example"
.field
.field
=
f
.
label
:description
=
f
.
label
:description
%br
/
%br
/
...
...
lib/gitosis.rb
View file @
5a5845e4
...
@@ -27,13 +27,14 @@ class Gitosis
...
@@ -27,13 +27,14 @@ class Gitosis
def
configure
def
configure
status
=
Timeout
::
timeout
(
20
)
do
status
=
Timeout
::
timeout
(
20
)
do
File
.
open
(
File
.
join
(
Dir
.
tmpdir
,
"gitlabhq-gitosis.lock"
),
"w+"
)
do
|
f
|
File
.
open
(
File
.
join
(
Dir
.
tmpdir
,
"gitlabhq-gitosis.lock"
),
"w+"
)
do
|
f
|
f
.
flock
(
File
::
LOCK_EX
)
begin
f
.
flock
(
File
::
LOCK_EX
)
pull
pull
yield
(
self
)
yield
(
self
)
push
push
ensure
f
.
flock
(
File
::
LOCK_UN
)
f
.
flock
(
File
::
LOCK_UN
)
end
end
end
end
end
rescue
Exception
=>
ex
rescue
Exception
=>
ex
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment