Accept any svn tunnel scheme in repository URL (#3278).
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@2723 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
a7ea14f5af
commit
752e263d3a
|
@ -147,7 +147,7 @@ module RepositoriesHelper
|
|||
|
||||
def subversion_field_tags(form, repository)
|
||||
content_tag('p', form.text_field(:url, :size => 60, :required => true, :disabled => (repository && !repository.root_url.blank?)) +
|
||||
'<br />(http://, https://, svn://, file:///)') +
|
||||
'<br />(file:///, http://, https://, svn://, svn+[tunnelscheme]://)') +
|
||||
content_tag('p', form.text_field(:login, :size => 30)) +
|
||||
content_tag('p', form.password_field(:password, :size => 30, :name => 'ignore',
|
||||
:value => ((repository.new_record? || repository.password.blank?) ? '' : ('x'*15)),
|
||||
|
|
|
@ -20,7 +20,7 @@ require 'redmine/scm/adapters/subversion_adapter'
|
|||
class Repository::Subversion < Repository
|
||||
attr_protected :root_url
|
||||
validates_presence_of :url
|
||||
validates_format_of :url, :with => /^(http|https|svn|svn\+ssh|file):\/\/.+/i
|
||||
validates_format_of :url, :with => /^(http|https|svn(\+[^\s:\/\\]+)?|file):\/\/.+/i
|
||||
|
||||
def scm_adapter
|
||||
Redmine::Scm::Adapters::SubversionAdapter
|
||||
|
|
Loading…
Reference in New Issue