Permalink
Browse files

Corrected matching against content of TODO item instead of whole line.

git-svn-id: http://svn.textmate.org/trunk/Bundles/TODO.tmbundle@11787 dfb7d73b-c2ec-0310-8fea-fb051d288c6d
  • Loading branch information...
1 parent ac07daa commit ce7b1f1acc6c22d3a56fc77aa761a4b0f3e3e6d8 @Soryu Soryu committed Oct 18, 2009
Showing with 3 additions and 2 deletions.
  1. +3 −2 Support/todo.rb
View
@@ -83,13 +83,14 @@ def TextMate.file_link (file, line = 0)
:rendered => '',
:index => tag[:matches].length
}
+ part = $1
if tag[:label] == "RADAR" then
url, display = "http://openradar.appspot.com/" + $2, "rdar://" + $2
match[:match] = html_escape($1) + "<a href=\"" + url + "\" target=\"_blank\">" + html_escape(display) + "</a>" + html_escape($3)
else
- match[:match] = html_escape($1)
+ match[:match] = html_escape(part)
end
- match[:clean] = match[:content].gsub(/\s+/, " ").gsub(/[^\w@`~!@#\$%\^&*\(\)-=+\[\]|\\\'\"\{\}<>,.\/\? ]/i, "")
+ match[:clean] = part.gsub(/\s+/, " ").gsub(/[^\w@`~!@#\$%\^&*\(\)-=+\[\]|\\\'\"\{\}<>,.\/\? ]/i, "")
tag[:matches] << match
count = tag[:matches].length

0 comments on commit ce7b1f1

Please sign in to comment.