Skip to content

Commit

Permalink
• fixed function parameter tooltip invoked by typing "(" to parse cor…
Browse files Browse the repository at this point in the history
…rectly and avoid the output of entire HTML code if parsing failed

git-svn-id: http://svn.textmate.org/trunk/Bundles/R.tmbundle@12051 dfb7d73b-c2ec-0310-8fea-fb051d288c6d
  • Loading branch information
Hans-Jörg Bibiko committed Sep 8, 2011
1 parent 21c9384 commit 0dac9c9
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions Support/bin/parseHTMLForUsage.sh
Expand Up @@ -10,13 +10,15 @@ undef($/);
$w=$ENV{"WORD"};
$f=$ENV{"FLAG"};
$a=<>;
$a=~s!.*?<h.>Usage</h.>\s*<pre>[^>]*?($w\([^>]*?\))\n.*?</pre>.*!$1!ms;
$a=~s!.*?<h.>Usage</h.>\s*<pre>[^>]*?($w\([^>]*?\)).*?\n.*?</pre>.*!$1!ms;
$a=~s/"\t"/"\\t"/sg;
$a=~s/"\n"/"\\n"/sg;
if($f) {
$a=~s/\n//sg;
$a=~s/^$w//ms;
$a="" if($a!~m/^\(.*\)$/);
}
print $a;
if($a!~m/^</) {
print $a;
}
'

0 comments on commit 0dac9c9

Please sign in to comment.