mirror of
https://github.com/wahyd4/gitlabhq.git
synced 2026-08-21 10:36:04 +10:00
Allow underscore as the first char for project names.
Not sure if the default_regex really has to be expanded for this special use case. We tried to extend only the project_name_regex first, but that didn't help.
This commit is contained in:
+2
-2
@@ -7,7 +7,7 @@ module Gitlab
|
||||
end
|
||||
|
||||
def project_name_regex
|
||||
/\A[a-zA-Z0-9][a-zA-Z0-9_\-\. ]*\z/
|
||||
/\A[a-zA-Z0-9_][a-zA-Z0-9_\-\. ]*\z/
|
||||
end
|
||||
|
||||
def name_regex
|
||||
@@ -49,7 +49,7 @@ module Gitlab
|
||||
protected
|
||||
|
||||
def default_regex
|
||||
/\A[.?]?[a-zA-Z0-9][a-zA-Z0-9_\-\.]*(?<!\.git)\z/
|
||||
/\A[.?]?[a-zA-Z0-9_][a-zA-Z0-9_\-\.]*(?<!\.git)\z/
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user