File tree Expand file tree Collapse file tree 2 files changed +2
-3
lines changed
src/main/resources/embedding/assets Expand file tree Collapse file tree 2 files changed +2
-3
lines changed Original file line number Diff line number Diff line change @@ -41,8 +41,7 @@ example2: `http://localhost/root/gitbucket/blob/19f0431a3fb4a9c3560dbf9b1d74f207
4141
4242## Limitation
4343
44- Because of path processing, currently this plugin can handle GitBucket which in running without url prefix.
45- And branch name icludes ` / ` may occur error.
44+ user name, repo name, branch name includes ` / ` may occur error.
4645
4746## Version
4847
Original file line number Diff line number Diff line change @@ -44,7 +44,7 @@ $(function(){
4444 } ;
4545
4646 function convertLinks ( ) {
47- var matchPattern = new RegExp ( 'https?://' + location . host + '(/\\w+)?/(\\w+)/(\\w+)/blob/(\\w+)/([\\w\\.]+)#L([0-9]+)(-L[0-9]+)?$' ) ;
47+ var matchPattern = new RegExp ( 'https?://' + location . host + '(/[ \\w-\\.] +)?/([ \\w-\\.] +)/([ \\w-\\.] +)/blob/([ \\w-\\.] +)/([\\w- \\.]+)#L([0-9]+)(-L[0-9]+)?$' ) ;
4848 var elements = $ ( '.markdown-body p a' ) ;
4949 var element ;
5050 var url ;
You can’t perform that action at this time.
0 commit comments