mirror of
https://github.com/correl/melpa.git
synced 2024-12-25 11:11:17 +00:00
ed473afce2
Conflicts: html/style.css
64 lines
1.3 KiB
JavaScript
64 lines
1.3 KiB
JavaScript
/*
|
|
Language: Diff
|
|
Description: Unified and context diff
|
|
Author: Vasily Polovnyov <vast@whiteants.net>
|
|
*/
|
|
|
|
hljs.LANGUAGES.diff = {
|
|
case_insensitive: true,
|
|
defaultMode: {
|
|
contains: [
|
|
{
|
|
className: 'chunk',
|
|
begin: '^\\@\\@ +\\-\\d+,\\d+ +\\+\\d+,\\d+ +\\@\\@$',
|
|
relevance: 10
|
|
},
|
|
{
|
|
className: 'chunk',
|
|
begin: '^\\*\\*\\* +\\d+,\\d+ +\\*\\*\\*\\*$',
|
|
relevance: 10
|
|
},
|
|
{
|
|
className: 'chunk',
|
|
begin: '^\\-\\-\\- +\\d+,\\d+ +\\-\\-\\-\\-$',
|
|
relevance: 10
|
|
},
|
|
{
|
|
className: 'header',
|
|
begin: 'Index: ', end: '$'
|
|
},
|
|
{
|
|
className: 'header',
|
|
begin: '=====', end: '=====$'
|
|
},
|
|
{
|
|
className: 'header',
|
|
begin: '^\\-\\-\\-', end: '$'
|
|
},
|
|
{
|
|
className: 'header',
|
|
begin: '^\\*{3} ', end: '$'
|
|
},
|
|
{
|
|
className: 'header',
|
|
begin: '^\\+\\+\\+', end: '$'
|
|
},
|
|
{
|
|
className: 'header',
|
|
begin: '\\*{5}', end: '\\*{5}$'
|
|
},
|
|
{
|
|
className: 'addition',
|
|
begin: '^\\+', end: '$'
|
|
},
|
|
{
|
|
className: 'deletion',
|
|
begin: '^\\-', end: '$'
|
|
},
|
|
{
|
|
className: 'change',
|
|
begin: '^\\!', end: '$'
|
|
}
|
|
]
|
|
}
|
|
};
|