Feature #1514
closed
Added by Stanislav German-Evtushenko over 16 years ago.
Updated about 16 years ago.
Description
Patch Redmine 0.7.1 for Parsing ftp URLs
Index: lib/redmine/wiki_formatting.rb
===================================================================
--- lib/redmine/wiki_formatting.rb (revision 1496)
+++ lib/redmine/wiki_formatting.rb (working copy)
@@ -126,6 +126,7 @@
)
(
(?:https?://)| # protocol spec, or
+ (?:ftp://)| #
(?:www\.) # www.*
)
(
- Category set to Wiki
- Status changed from New to Closed
- Target version set to 0.8
- Resolution set to Fixed
- Status changed from Closed to Reopened
I think the regex for parsing ftp:// links is a bit too aggressive as it tears apart sftp:// links.
The less aggressive approach would be to watch for whitespace before the ftp:// so the patch should be:
Index: lib/redmine/wiki_formatting.rb
===================================================================
--- lib/redmine/wiki_formatting.rb (revision 1496)
+++ lib/redmine/wiki_formatting.rb (working copy)
@@ -126,6 +126,7 @@
)
(
(?:https?://)| # protocol spec, or
+ (?:\sftp://)| #
(?:www\.) # www.*
)
(
Kevin Light wrote:
I think the regex for parsing ftp:// links is a bit too aggressive as it tears apart sftp:// links.
The less aggressive approach would be to watch for whitespace before the ftp:// so the patch should be:
[...]
You can use "inline code" to disable parsing. For example: sftp://myserv
- Status changed from Reopened to Closed
sftp and ftps proto are now properly turned into links (r2018).
Also available in: Atom
PDF