Skip to content

Commit

Permalink
fix image path
Browse files Browse the repository at this point in the history
  • Loading branch information
yuki-kimoto committed Dec 6, 2016
1 parent 6ef6305 commit d3a7c3c
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions templates/include/readme.html.ep
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@
my $readme = join "\n", @$lines;
$readme =~ s#^(\[.*\]:)(?!\s*https?://)\s*(\S*)#{"$1 " . url_for("/$user/$project/raw/$rev/$2")}#mge;
$readme =~ s#^(!\[.*\]\()(?!https?://)(\S*)#{$1 . url_for("/$user/$project/raw/$rev/$2")}#mge;
$readme =~ s#src="(?!https?://)(\S*)"#{'src="' . url_for("/$user/$project/raw/$rev/$1") . '"'}#mge;

$readme_e = $api->markdown($readme);
}
}
Expand Down

0 comments on commit d3a7c3c

Please sign in to comment.