Update to 7.1
This commit is contained in:
41
vendor/assets/javascripts/highlight_js/languages/http.js
vendored
Normal file
41
vendor/assets/javascripts/highlight_js/languages/http.js
vendored
Normal file
@@ -0,0 +1,41 @@
|
||||
/*
|
||||
Language: HTTP
|
||||
Description: HTTP request and response headers with automatic body highlighting
|
||||
Author: Ivan Sagalaev <maniac@softwaremaniacs.org>
|
||||
*/
|
||||
|
||||
hljs.LANGUAGES['http'] = function(hljs) {
|
||||
return {
|
||||
defaultMode: {
|
||||
illegal: '\\S',
|
||||
contains: [
|
||||
{
|
||||
className: 'status',
|
||||
begin: '^HTTP/[0-9\\.]+', end: '$',
|
||||
contains: [{className: 'number', begin: '\\b\\d{3}\\b'}]
|
||||
},
|
||||
{
|
||||
className: 'request',
|
||||
begin: '^[A-Z]+ (.*?) HTTP/[0-9\\.]+$', returnBegin: true, end: '$',
|
||||
contains: [
|
||||
{
|
||||
className: 'string',
|
||||
begin: ' ', end: ' ',
|
||||
excludeBegin: true, excludeEnd: true
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
className: 'attribute',
|
||||
begin: '^\\w', end: ': ', excludeEnd: true,
|
||||
illegal: '\\n',
|
||||
starts: {className: 'string', end: '$'}
|
||||
},
|
||||
{
|
||||
begin: '\\n\\n',
|
||||
starts: {subLanguage: '', endsWithParent: true}
|
||||
}
|
||||
]
|
||||
}
|
||||
};
|
||||
}(hljs);
|
||||
Reference in New Issue
Block a user