ignore string starting with

This commit is contained in:
jb-alvarado 2021-02-04 17:56:25 +01:00
parent 3cef5529c7
commit fba5a2e1d3

View File

@ -61,7 +61,7 @@ export default {
formatStr (text) {
return text
.replace(/(".*")/g, '<span class="log-cmd">$1</span>')
.replace(/(\/.*)/g, '<span class="log-path">$1</span>')
.replace(/(?<!".*)(\/.*)/g, '<span class="log-path">$1</span>')
.replace(/(\/[\w\d.\-/]+\n)/g, '<span class="log-path">$1</span>')
.replace(/((tcp|https?):\/\/[\w\d.:]+)/g, '<span class="log-url">$1</span>')
.replace(/(\[\d{4}-\d{2}-\d{2} \d{2}:\d{2}:\d{2}[0-9,.]+\])/g, '<span class="log-time">$1</span>')