Socket
Socket
Sign inDemoInstall

highlight.js

Package Overview
Dependencies
Maintainers
2
Versions
101
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

highlight.js - npm Package Compare versions

Comparing version 9.16.2 to 9.17.0

scss/gradient-dark.scss

202

lib/highlight.js

@@ -39,2 +39,6 @@ /*

// safe/production mode - swallows more errors, tries to keep running
// even if a single syntax or parse hits a fatal error
var SAFE_MODE = true;
// Regular expressions used throughout the highlight.js library.

@@ -50,2 +54,3 @@ var noHighlightRe = /^(no-?highlight|plain|text)$/i,

var spanEndTag = '</span>';
var LANGUAGE_NOT_FOUND = "Could not find the language '{}', did you forget to load/include a language module?";

@@ -62,3 +67,3 @@ // Global options used when within external APIs. This is modified when

// keywords that should have no default relevance value
var COMMON_KEYWORDS = 'of and for in not or if then'.split(' ')
var COMMON_KEYWORDS = 'of and for in not or if then'.split(' ');

@@ -94,3 +99,8 @@

if (match) {
return getLanguage(match[1]) ? match[1] : 'no-highlight';
var language = getLanguage(match[1]);
if (!language) {
console.warn(LANGUAGE_NOT_FOUND.replace("{}", match[1]));
console.warn("Falling back to no-highlight mode for this block.", block);
}
return language ? match[1] : 'no-highlight';
}

@@ -109,2 +119,8 @@

/**
* performs a shallow merge of multiple objects into one
*
* @arguments list of objects with properties to merge
* @returns a single new object
*/
function inherit(parent) { // inherit(parent, override_obj, override_obj, ...)

@@ -188,3 +204,5 @@ var key;

function open(node) {
function attr_str(a) {return ' ' + a.nodeName + '="' + escape(a.value).replace('"', '&quot;') + '"';}
function attr_str(a) {
return ' ' + a.nodeName + '="' + escape(a.value).replace(/"/g, '&quot;') + '"';
}
result += '<' + tag(node) + ArrayProto.map.call(node.attributes, attr_str).join('') + '>';

@@ -235,3 +253,3 @@ }

return mode.endsWithParent || dependencyOnParent(mode.starts)
return mode.endsWithParent || dependencyOnParent(mode.starts);
}

@@ -247,3 +265,3 @@

// EXPAND
// if we have variants then essentually "replace" the mode with the variants
// if we have variants then essentially "replace" the mode with the variants
// this happens in compileMode, where this function is called from

@@ -258,6 +276,9 @@ if (mode.cached_variants)

if (dependencyOnParent(mode))
return [inherit(mode, { starts: mode.starts ? inherit(mode.starts) : null })]
return [inherit(mode, { starts: mode.starts ? inherit(mode.starts) : null })];
if (Object.isFrozen(mode))
return [inherit(mode)];
// no special dependency issues, just return ourselves
return [mode]
return [mode];
}

@@ -268,4 +289,7 @@

obj.langApiRestored = true;
for(var key in API_REPLACES)
obj[key] && (obj[API_REPLACES[key]] = obj[key]);
for(var key in API_REPLACES) {
if (obj[key]) {
obj[API_REPLACES[key]] = obj[key];
}
}
(obj.contains || []).concat(obj.variants || []).forEach(restoreLanguageApi);

@@ -297,3 +321,3 @@ }

});
};
}
}

@@ -305,3 +329,3 @@

if (providedScore)
return Number(providedScore)
return Number(providedScore);

@@ -312,3 +336,3 @@ return commonKeyword(keyword) ? 0 : 1;

function commonKeyword(word) {
return COMMON_KEYWORDS.indexOf(word.toLowerCase()) != -1
return COMMON_KEYWORDS.indexOf(word.toLowerCase()) != -1;
}

@@ -410,3 +434,3 @@

var terminators = regexes.map(function(el) { return el[1] });
var terminators = regexes.map(function(el) { return el[1]; });
matcherRe = langRe(joinRe(terminators, '|'), true);

@@ -440,3 +464,3 @@

return match;
}
};

@@ -453,3 +477,3 @@ return matcher;

if (mode.keywords)
mode.keywords = compileKeywords(mode.keywords, language.case_insensitive)
mode.keywords = compileKeywords(mode.keywords, language.case_insensitive);

@@ -494,2 +518,13 @@ mode.lexemesRe = langRe(mode.lexemes || /\w+/, true);

// self is not valid at the top-level
if (language.contains && language.contains.indexOf('self') != -1) {
if (!SAFE_MODE) {
throw new Error("ERR: contains `self` is not supported at the top-level of a language. See documentation.")
} else {
// silently remove the broken rule (effectively ignoring it), this has historically
// been the behavior in the past, so this removal preserves compatibility with broken
// grammars when running in Safe Mode
language.contains = language.contains.filter(function(mode) { return mode != 'self'; });
}
}
compileMode(language);

@@ -530,5 +565,5 @@ }

function buildSpan(classname, insideSpan, leaveOpen, noPrefix) {
function buildSpan(className, insideSpan, leaveOpen, noPrefix) {
if (!leaveOpen && insideSpan === '') return '';
if (!classname) return insideSpan;
if (!className) return insideSpan;

@@ -539,3 +574,3 @@ var classPrefix = noPrefix ? '' : options.classPrefix,

openSpan += classname + '">';
openSpan += className + '">';

@@ -582,3 +617,3 @@ return openSpan + insideSpan + closeSpan;

// Counting embedded language score towards the host language may be disabled
// with zeroing the containing mode relevance. Usecase in point is Markdown that
// with zeroing the containing mode relevance. Use case in point is Markdown that
// allows XML everywhere and makes every XML snippet to have a much larger Markdown

@@ -625,3 +660,3 @@ // score.

}
startNewMode(new_mode, lexeme);
startNewMode(new_mode);
return new_mode.returnBegin ? 0 : lexeme.length;

@@ -632,3 +667,4 @@ }

var lexeme = match[0];
var end_mode = endOfMode(top, lexeme);
var matchPlusRemainder = value.substr(match.index);
var end_mode = endOfMode(top, matchPlusRemainder);
if (!end_mode) { return; }

@@ -661,3 +697,3 @@

}
startNewMode(end_mode.starts, '');
startNewMode(end_mode.starts);
}

@@ -686,3 +722,3 @@ return origin.returnEnd ? 0 : lexeme.length;

// spit the "skipped" character that our regex choked on back into the output sequence
mode_buffer += value.slice(match.index, match.index + 1)
mode_buffer += value.slice(match.index, match.index + 1);
return 1;

@@ -721,2 +757,3 @@ }

if (!language) {
console.error(LANGUAGE_NOT_FOUND.replace("{}", name));
throw new Error('Unknown language: "' + name + '"');

@@ -759,4 +796,4 @@ }

};
} catch (e) {
if (e.message && e.message.indexOf('Illegal') !== -1) {
} catch (err) {
if (err.message && err.message.indexOf('Illegal') !== -1) {
return {

@@ -767,4 +804,12 @@ illegal: true,

};
} else if (SAFE_MODE) {
return {
relevance: 0,
value: escape(value),
language: name,
top: top,
errorRaised: err
};
} else {
throw e;
throw err;
}

@@ -817,12 +862,14 @@ }

function fixMarkup(value) {
return !(options.tabReplace || options.useBR)
? value
: value.replace(fixMarkupRe, function(match, p1) {
if (options.useBR && match === '\n') {
return '<br>';
} else if (options.tabReplace) {
return p1.replace(/\t/g, options.tabReplace);
}
return '';
});
if (!(options.tabReplace || options.useBR)) {
return value;
}
return value.replace(fixMarkupRe, function(match, p1) {
if (options.useBR && match === '\n') {
return '<br>';
} else if (options.tabReplace) {
return p1.replace(/\t/g, options.tabReplace);
}
return '';
});
}

@@ -857,3 +904,3 @@

if (options.useBR) {
node = document.createElementNS('http://www.w3.org/1999/xhtml', 'div');
node = document.createElement('div');
node.innerHTML = block.innerHTML.replace(/\n/g, '').replace(/<br[ \/]*>/g, '\n');

@@ -868,3 +915,3 @@ } else {

if (originalStream.length) {
resultNode = document.createElementNS('http://www.w3.org/1999/xhtml', 'div');
resultNode = document.createElement('div');
resultNode.innerHTML = result.value;

@@ -912,8 +959,22 @@ result.value = mergeStreams(originalStream, nodeStream(resultNode), text);

function initHighlightingOnLoad() {
addEventListener('DOMContentLoaded', initHighlighting, false);
addEventListener('load', initHighlighting, false);
window.addEventListener('DOMContentLoaded', initHighlighting, false);
window.addEventListener('load', initHighlighting, false);
}
var PLAINTEXT_LANGUAGE = { disableAutodetect: true };
function registerLanguage(name, language) {
var lang = languages[name] = language(hljs);
var lang;
try { lang = language(hljs); }
catch (error) {
console.error("Language definition for '{}' could not be registered.".replace("{}", name));
// hard or soft error
if (!SAFE_MODE) { throw error; } else { console.error(error); }
// languages that have serious errors are replaced with essentially a
// "plaintext" stand-in so that the code blocks will still get normal
// css classes applied to them - and one bad language won't break the
// entire highlighter
lang = PLAINTEXT_LANGUAGE;
}
languages[name] = lang;
restoreLanguageApi(lang);

@@ -931,2 +992,16 @@ lang.rawDefinition = language.bind(null,hljs);

/*
intended usage: When one language truly requires another
Unlike `getLanguage`, this will throw when the requested language
is not available.
*/
function requireLanguage(name) {
var lang = getLanguage(name);
if (lang) { return lang; }
var err = new Error('The \'{}\' language is required, but not loaded.'.replace('{}',name));
throw err;
}
function getLanguage(name) {

@@ -954,4 +1029,6 @@ name = (name || '').toLowerCase();

hljs.getLanguage = getLanguage;
hljs.requireLanguage = requireLanguage;
hljs.autoDetection = autoDetection;
hljs.inherit = inherit;
hljs.debugMode = function() { SAFE_MODE = false; }

@@ -1062,3 +1139,46 @@ // Common regexps

var constants = [
hljs.IDENT_RE,
hljs.UNDERSCORE_IDENT_RE,
hljs.NUMBER_RE,
hljs.C_NUMBER_RE,
hljs.BINARY_NUMBER_RE,
hljs.RE_STARTERS_RE,
hljs.BACKSLASH_ESCAPE,
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
hljs.PHRASAL_WORDS_MODE,
hljs.COMMENT,
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
hljs.HASH_COMMENT_MODE,
hljs.NUMBER_MODE,
hljs.C_NUMBER_MODE,
hljs.BINARY_NUMBER_MODE,
hljs.CSS_NUMBER_MODE,
hljs.REGEXP_MODE,
hljs.TITLE_MODE,
hljs.UNDERSCORE_TITLE_MODE,
hljs.METHOD_GUARD
]
constants.forEach(function(obj) { deepFreeze(obj); });
// https://github.com/substack/deep-freeze/blob/master/index.js
function deepFreeze (o) {
Object.freeze(o);
Object.getOwnPropertyNames(o).forEach(function (prop) {
if (o.hasOwnProperty(prop)
&& o[prop] !== null
&& (typeof o[prop] === "object" || typeof o[prop] === "function")
&& !Object.isFrozen(o[prop])) {
deepFreeze(o[prop]);
}
});
return o;
};
return hljs;
}));

@@ -89,3 +89,3 @@ module.exports = function(hljs) {

var ARDUINO = hljs.getLanguage('cpp').rawDefinition();
var ARDUINO = hljs.requireLanguage('cpp').rawDefinition();

@@ -92,0 +92,0 @@ var kws = ARDUINO.keywords;

@@ -42,3 +42,3 @@ module.exports = function(hljs) {

'if else elif endif define undef warning error line ' +
'pragma ifdef ifndef include'
'pragma _Pragma ifdef ifndef include'
},

@@ -52,3 +52,3 @@ contains: [

className: 'meta-string',
begin: /<[^\n>]*>/, end: /$/,
begin: /<.*?>/, end: /$/,
illegal: '\\n',

@@ -64,17 +64,17 @@ },

var CPP_KEYWORDS = {
keyword: 'int float while private char catch import module export virtual operator sizeof ' +
keyword: 'int float while private char char8_t char16_t char32_t catch import module export virtual operator sizeof ' +
'dynamic_cast|10 typedef const_cast|10 const for static_cast|10 union namespace ' +
'unsigned long volatile static protected bool template mutable if public friend ' +
'do goto auto void enum else break extern using asm case typeid ' +
'do goto auto void enum else break extern using asm case typeid wchar_t' +
'short reinterpret_cast|10 default double register explicit signed typename try this ' +
'switch continue inline delete alignof constexpr consteval constinit decltype ' +
'switch continue inline delete alignas alignof constexpr consteval constinit decltype ' +
'concept co_await co_return co_yield requires ' +
'noexcept static_assert thread_local restrict _Bool complex _Complex _Imaginary ' +
'noexcept static_assert thread_local restrict final override ' +
'atomic_bool atomic_char atomic_schar ' +
'atomic_uchar atomic_short atomic_ushort atomic_int atomic_uint atomic_long atomic_ulong atomic_llong ' +
'atomic_ullong new throw return ' +
'and or not',
'and and_eq bitand bitor compl not not_eq or or_eq xor xor_eq',
built_in: 'std string wstring cin cout cerr clog stdin stdout stderr stringstream istringstream ostringstream ' +
'auto_ptr deque list queue stack vector map set bitset multiset multimap unordered_set ' +
'unordered_map unordered_multiset unordered_multimap array shared_ptr abort abs acos ' +
'unordered_map unordered_multiset unordered_multimap array shared_ptr abort terminate abs acos ' +
'asin atan2 atan calloc ceil cosh cos exit exp fabs floor fmod fprintf fputs free frexp ' +

@@ -85,3 +85,3 @@ 'fscanf future isalnum isalpha iscntrl isdigit isgraph islower isprint ispunct isspace isupper ' +

'strcpy strcspn strlen strncat strncmp strncpy strpbrk strrchr strspn strstr tanh tan ' +
'vfprintf vprintf vsprintf endl initializer_list unique_ptr',
'vfprintf vprintf vsprintf endl initializer_list unique_ptr _Bool complex _Complex imaginary _Imaginary',
literal: 'true false nullptr NULL'

@@ -88,0 +88,0 @@ };

module.exports = function(hljs) {
var FUNCTION_LIKE = {
begin: /[\w-]+\(/, returnBegin: true,
contains: [
{
className: 'built_in',
begin: /[\w-]+/
},
{
begin: /\(/, end: /\)/,
contains: [
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
hljs.CSS_NUMBER_MODE,
]
}
]
}
var ATTRIBUTE = {
className: 'attribute',
begin: /\S/, end: ':', excludeEnd: true,
starts: {
endsWithParent: true, excludeEnd: true,
contains: [
FUNCTION_LIKE,
hljs.CSS_NUMBER_MODE,
hljs.QUOTE_STRING_MODE,
hljs.APOS_STRING_MODE,
hljs.C_BLOCK_COMMENT_MODE,
{
className: 'number', begin: '#[0-9A-Fa-f]+'
},
{
className: 'meta', begin: '!important'
}
]
}
}
var AT_IDENTIFIER = '@[a-z-]+' // @font-face
var AT_MODIFIERS = "and or not only"
var MEDIA_TYPES = "all print screen speech"
var AT_PROPERTY_RE = /@\-?\w[\w]*(\-\w+)*/ // @-webkit-keyframes
var IDENT_RE = '[a-zA-Z-][a-zA-Z0-9_-]*';

@@ -6,37 +47,3 @@ var RULE = {

contains: [
{
className: 'attribute',
begin: /\S/, end: ':', excludeEnd: true,
starts: {
endsWithParent: true, excludeEnd: true,
contains: [
{
begin: /[\w-]+\(/, returnBegin: true,
contains: [
{
className: 'built_in',
begin: /[\w-]+/
},
{
begin: /\(/, end: /\)/,
contains: [
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE
]
}
]
},
hljs.CSS_NUMBER_MODE,
hljs.QUOTE_STRING_MODE,
hljs.APOS_STRING_MODE,
hljs.C_BLOCK_COMMENT_MODE,
{
className: 'number', begin: '#[0-9A-Fa-f]+'
},
{
className: 'meta', begin: '!important'
}
]
}
}
ATTRIBUTE
]

@@ -59,3 +66,7 @@ };

begin: /\[/, end: /\]/,
illegal: '$'
illegal: '$',
contains: [
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
]
},

@@ -66,6 +77,9 @@ {

},
// matching these here allows us to treat them more like regular CSS
// rules so everything between the {} gets regular rule highlighting,
// which is what we want for page and font-face
{
begin: '@(font-face|page)',
lexemes: '[a-z-]+',
keywords: 'font-face page'
begin: '@(page|font-face)',
lexemes: AT_IDENTIFIER,
keywords: '@page @font-face'
},

@@ -78,6 +92,7 @@ {

illegal: /:/, // break on Less variables @var: ...
returnBegin: true,
contains: [
{
className: 'keyword',
begin: /\w+/
begin: AT_PROPERTY_RE
},

@@ -87,4 +102,10 @@ {

relevance: 0,
keywords: AT_MODIFIERS,
contains: [
hljs.APOS_STRING_MODE, hljs.QUOTE_STRING_MODE,
{
begin: /[a-z-]+:/,
className:"attribute"
},
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
hljs.CSS_NUMBER_MODE

@@ -91,0 +112,0 @@ ]

@@ -6,3 +6,3 @@ module.exports = function(hljs) {

className: "attribute",
begin: /^[ ]*[a-zA-Z][a-zA-Z-]*([\s-]+[a-zA-Z][a-zA-Z]*)*/
begin: /^[ ]*[a-zA-Z][a-zA-Z-_]*([\s-_]+[a-zA-Z][a-zA-Z]*)*/
};

@@ -16,8 +16,15 @@

var ruleBodyMode = {
begin: /=/, end: /;/,
begin: /=/, end: /[.;]/,
contains: [
commentMode,
specialSequenceMode,
// terminals
hljs.APOS_STRING_MODE, hljs.QUOTE_STRING_MODE
{
// terminals
className: 'string',
variants: [
hljs.APOS_STRING_MODE,
hljs.QUOTE_STRING_MODE,
{begin: '`', end: '`'},
]
},
]

@@ -24,0 +31,0 @@ };

@@ -14,2 +14,42 @@ module.exports = function(hljs) {

};
var SIGIL_DELIMITERS = '[/|([{<"\']'
var LOWERCASE_SIGIL = {
className: 'string',
begin: '~[a-z]' + '(?=' + SIGIL_DELIMITERS + ')',
contains: [
{
endsParent:true,
contains: [{
contains: [hljs.BACKSLASH_ESCAPE, SUBST],
variants: [
{ begin: /"/, end: /"/ },
{ begin: /'/, end: /'/ },
{ begin: /\//, end: /\// },
{ begin: /\|/, end: /\|/ },
{ begin: /\(/, end: /\)/ },
{ begin: /\[/, end: /\]/ },
{ begin: /\{/, end: /\}/ },
{ begin: /</, end: />/ }
]
}]
},
],
};
var UPCASE_SIGIL = {
className: 'string',
begin: '~[A-Z]' + '(?=' + SIGIL_DELIMITERS + ')',
contains: [
{ begin: /"/, end: /"/ },
{ begin: /'/, end: /'/ },
{ begin: /\//, end: /\// },
{ begin: /\|/, end: /\|/ },
{ begin: /\(/, end: /\)/ },
{ begin: /\[/, end: /\]/ },
{ begin: /\{/, end: /\}/ },
{ begin: /\</, end: /\>/ }
]
};
var STRING = {

@@ -20,2 +60,24 @@ className: 'string',

{
begin: /"""/, end: /"""/,
},
{
begin: /'''/, end: /'''/,
},
{
begin: /~S"""/, end: /"""/,
contains: []
},
{
begin: /~S"/, end: /"/,
contains: []
},
{
begin: /~S'''/, end: /'''/,
contains: []
},
{
begin: /~S'/, end: /'/,
contains: []
},
{
begin: /'/, end: /'/

@@ -25,3 +87,3 @@ },

begin: /"/, end: /"/
}
},
]

@@ -45,2 +107,4 @@ };

STRING,
UPCASE_SIGIL,
LOWERCASE_SIGIL,
hljs.HASH_COMMENT_MODE,

@@ -47,0 +111,0 @@ CLASS,

module.exports = function(hljs) {
var GML_KEYWORDS = {
keywords: 'begin end if then else while do for break continue with until ' +
keyword: 'begin end if then else while do for break continue with until ' +
'repeat exit and or xor not return mod div switch case default var ' +

@@ -5,0 +5,0 @@ 'globalvar enum #macro #region #endregion',

@@ -24,3 +24,3 @@ module.exports = function(hljs) {

hljs.QUOTE_STRING_MODE,
{begin: '\'', end: '[^\\\\]\''},
hljs.APOS_STRING_MODE,
{begin: '`', end: '`'},

@@ -27,0 +27,0 @@ ]

@@ -83,3 +83,3 @@ module.exports = function(hljs) {

return {
aliases: ['js', 'jsx'],
aliases: ['js', 'jsx', 'mjs', 'cjs'],
keywords: KEYWORDS,

@@ -102,2 +102,35 @@ contains: [

hljs.C_LINE_COMMENT_MODE,
hljs.COMMENT(
'/\\*\\*',
'\\*/',
{
relevance : 0,
contains : [
{
className : 'doctag',
begin : '@[A-Za-z]+',
contains : [
{
className: 'type',
begin: '\\{',
end: '\\}',
relevance: 0
},
{
className: 'variable',
begin: IDENT_RE + '(?=\\s*(-)|$)',
endsParent: true,
relevance: 0
},
// eat spaces (not newlines) so we can find
// types or variables
{
begin: /(?=[^\n])\s/,
relevance: 0
},
]
}
]
}
),
hljs.C_BLOCK_COMMENT_MODE,

@@ -104,0 +137,0 @@ NUMBER,

@@ -44,3 +44,3 @@ module.exports = function(hljs) {

{
begin: '"""', end: '"""',
begin: '"""', end: '"""(?=[^"])',
contains: [VARIABLE, SUBST]

@@ -47,0 +47,0 @@ },

@@ -40,12 +40,4 @@ module.exports = function(hljs) {

/* Variable assignment */
var VAR_ASSIG = {
begin: '^' + hljs.UNDERSCORE_IDENT_RE + '\\s*[:+?]?=',
illegal: '\\n',
returnBegin: true,
contains: [
{
begin: '^' + hljs.UNDERSCORE_IDENT_RE, end: '[:+?]?=',
excludeEnd: true,
}
]
var ASSIGNMENT = {
begin: '^' + hljs.UNDERSCORE_IDENT_RE + '\\s*(?=[:+?]?=)'
};

@@ -76,3 +68,3 @@ /* Meta targets (.PHONY) */

FUNC,
VAR_ASSIG,
ASSIGNMENT,
META,

@@ -79,0 +71,0 @@ TARGET,

@@ -45,2 +45,3 @@ module.exports = function(hljs) {

};
STRING.contains = STRING.contains.slice() // we need our own copy of contains
STRING.contains.push(STRING_FMT);

@@ -47,0 +48,0 @@

@@ -48,2 +48,3 @@ module.exports = function(hljs) {

hljs.QUOTE_STRING_MODE,
hljs.APOS_STRING_MODE,
{

@@ -56,6 +57,2 @@ className: 'string',

contains: [hljs.BACKSLASH_ESCAPE]
},
{
begin: '\'', end: '[^\\\\]\'',
illegal: '[^\\\\][^\']'
}

@@ -66,12 +63,20 @@ ]

className: 'meta',
begin: '#',
end: '$',
begin: /#\s*[a-z]+\b/, end: /$/,
keywords: {
'meta-keyword':
'if else elif endif define undef warning error line ' +
'pragma ifdef ifndef include'
},
contains: [
{
begin: /\\\n/, relevance: 0
},
hljs.inherit(hljs.QUOTE_STRING_MODE, {className: 'meta-string'}),
{
className: 'meta-string',
variants: [
{ begin: '\"', end: '\"' },
{ begin: '<', end: '>' }
]
}
begin: /<.*?>/, end: /$/,
illegal: '\\n',
},
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE
]

@@ -78,0 +83,0 @@ },

module.exports = function(hljs){
var TYPES =
["string", "char", "byte", "int", "long", "bool", "decimal", "single",
"double", "DateTime", "xml", "array", "hashtable", "void"];
// https://msdn.microsoft.com/en-us/library/ms714428(v=vs.85).aspx
var VALID_VERBS =
'Add|Clear|Close|Copy|Enter|Exit|Find|Format|Get|Hide|Join|Lock|' +
'Move|New|Open|Optimize|Pop|Push|Redo|Remove|Rename|Reset|Resize|' +
'Search|Select|Set|Show|Skip|Split|Step|Switch|Undo|Unlock|' +
'Watch|Backup|Checkpoint|Compare|Compress|Convert|ConvertFrom|' +
'ConvertTo|Dismount|Edit|Expand|Export|Group|Import|Initialize|' +
'Limit|Merge|New|Out|Publish|Restore|Save|Sync|Unpublish|Update|' +
'Approve|Assert|Complete|Confirm|Deny|Disable|Enable|Install|Invoke|Register|' +
'Request|Restart|Resume|Start|Stop|Submit|Suspend|Uninstall|' +
'Unregister|Wait|Debug|Measure|Ping|Repair|Resolve|Test|Trace|Connect|' +
'Disconnect|Read|Receive|Send|Write|Block|Grant|Protect|Revoke|Unblock|' +
'Unprotect|Use|ForEach|Sort|Tee|Where';
var COMPARISON_OPERATORS =
'-and|-as|-band|-bnot|-bor|-bxor|-casesensitive|-ccontains|-ceq|-cge|-cgt|' +
'-cle|-clike|-clt|-cmatch|-cne|-cnotcontains|-cnotlike|-cnotmatch|-contains|' +
'-creplace|-csplit|-eq|-exact|-f|-file|-ge|-gt|-icontains|-ieq|-ige|-igt|' +
'-ile|-ilike|-ilt|-imatch|-in|-ine|-inotcontains|-inotlike|-inotmatch|' +
'-ireplace|-is|-isnot|-isplit|-join|-le|-like|-lt|-match|-ne|-not|' +
'-notcontains|-notin|-notlike|-notmatch|-or|-regex|-replace|-shl|-shr|' +
'-split|-wildcard|-xor';
var KEYWORDS = {
keyword: 'if else foreach return do while until elseif begin for trap data dynamicparam ' +
'end break throw param continue finally in switch exit filter try process catch ' +
'hidden static parameter'
// TODO: 'validate[A-Z]+' can't work in keywords
};
var TITLE_NAME_RE = /\w[\w\d]*((-)[\w\d]+)*/;
var BACKTICK_ESCAPE = {
begin: "`[\\s\\S]",
relevance: 0,
begin: '`[\\s\\S]',
relevance: 0
};
var VAR = {
className: "variable",
variants: [{ begin: /\$[\w\d][\w\d_:]*/ }],
className: 'variable',
variants: [
{ begin: /\$\B/ },
{ className: 'keyword', begin: /\$this/ },
{ begin: /\$[\w\d][\w\d_:]*/ }
]
};
var LITERAL = {
className: "literal",
begin: /\$(null|true|false)\b/,
className: 'literal',
begin: /\$(null|true|false)\b/
};
var QUOTE_STRING = {

@@ -21,11 +65,14 @@ className: "string",

{
className: "variable",
begin: /\$[A-z]/,
end: /[^A-z]/,
},
],
className: 'variable',
begin: /\$[A-z]/, end: /[^A-z]/
}
]
};
var APOS_STRING = {
className: "string",
variants: [{ begin: /'/, end: /'/ }, { begin: /@'/, end: /^'@/ }],
className: 'string',
variants: [
{ begin: /'/, end: /'/ },
{ begin: /@'/, end: /^'@/ }
]
};

@@ -37,22 +84,148 @@

/* no paramater help tags */
{
begin: /\.(synopsis|description|example|inputs|outputs|notes|link|component|role|functionality)/,
begin: /\.(synopsis|description|example|inputs|outputs|notes|link|component|role|functionality)/
},
/* one parameter help tags */
{ begin: /\.(parameter|forwardhelptargetname|forwardhelpcategory|remotehelprunspace|externalhelp)\s+\S+/ }
]
};
var PS_COMMENT = hljs.inherit(
hljs.COMMENT(null, null),
{
variants: [
/* single-line comment */
{ begin: /#/, end: /$/ },
/* multi-line comment */
{ begin: /<#/, end: /#>/ }
],
contains: [PS_HELPTAGS]
}
);
var CMDLETS = {
className: 'built_in',
variants: [
{ begin: '('.concat(VALID_VERBS, ')+(-)[\\w\\d]+') }
]
};
var PS_CLASS = {
className: 'class',
beginKeywords: 'class enum', end: /\s*[{]/, excludeEnd: true,
relevance: 0,
contains: [hljs.TITLE_MODE]
};
var PS_FUNCTION = {
className: 'function',
begin: /function\s+/, end: /\s*\{|$/,
excludeEnd: true,
returnBegin: true,
relevance: 0,
contains: [
{ begin: "function", relevance: 0, className: "keyword" },
{ className: "title",
begin: TITLE_NAME_RE, relevance:0 },
{ begin: /\(/, end: /\)/, className: "params",
relevance: 0,
contains: [VAR] }
// CMDLETS
]
};
// Using statment, plus type, plus assembly name.
var PS_USING = {
begin: /using\s/, end: /$/,
returnBegin: true,
contains: [
QUOTE_STRING,
APOS_STRING,
{ className: 'keyword', begin: /(using|assembly|command|module|namespace|type)/ }
]
};
// Comperison operators & function named parameters.
var PS_ARGUMENTS = {
variants: [
// PS literals are pretty verbose so it's a good idea to accent them a bit.
{ className: 'operator', begin: '('.concat(COMPARISON_OPERATORS, ')\\b') },
{ className: 'literal', begin: /(-)[\w\d]+/, relevance:0 }
]
};
var STATIC_MEMBER = {
className: 'selector-tag',
begin: /::\w+\b/, end: /$/,
returnBegin: true,
contains: [
{ className: 'attribute', begin: /\w+/, endsParent: true }
]
};
var HASH_SIGNS = {
className: 'selector-tag',
begin: /\@\B/,
relevance: 0
};
var PS_NEW_OBJECT_TYPE = {
className: 'built_in',
begin: /New-Object\s+\w/, end: /$/,
returnBegin: true,
contains: [
{ begin: /New-Object\s+/, relevance: 0 },
{ className: 'meta', begin: /([\w\.])+/, endsParent: true }
]
};
// It's a very general rule so I'll narrow it a bit with some strict boundaries
// to avoid any possible false-positive collisions!
var PS_METHODS = {
className: 'function',
begin: /\[.*\]\s*[\w]+[ ]??\(/, end: /$/,
returnBegin: true,
relevance: 0,
contains: [
{
begin: /\.(parameter|forwardhelptargetname|forwardhelpcategory|remotehelprunspace|externalhelp)\s+\S+/,
className: 'keyword', begin: '('.concat(
KEYWORDS.keyword.toString().replace(/\s/g, '|'
), ')\\b'),
endsParent: true,
relevance: 0
},
],
hljs.inherit(hljs.TITLE_MODE, { endsParent: true })
]
};
var PS_COMMENT = hljs.inherit(hljs.COMMENT(null, null), {
variants: [
/* single-line comment */
{ begin: /#/, end: /$/ },
/* multi-line comment */
{ begin: /<#/, end: /#>/ },
],
contains: [PS_HELPTAGS],
});
var GENTLEMANS_SET = [
// STATIC_MEMBER,
PS_METHODS,
PS_COMMENT,
BACKTICK_ESCAPE,
hljs.NUMBER_MODE,
QUOTE_STRING,
APOS_STRING,
// PS_NEW_OBJECT_TYPE,
CMDLETS,
VAR,
LITERAL,
HASH_SIGNS
];
var PS_TYPE = {
begin: /\[/, end: /\]/,
excludeBegin: true,
excludeEnd: true,
relevance: 0,
contains: [].concat(
'self',
GENTLEMANS_SET,
{ begin: "(" + TYPES.join("|") + ")", className: "built_in", relevance:0 },
{ className: 'type', begin: /[\.\w\d]+/, relevance: 0 }
)
};
PS_METHODS.contains.unshift(PS_TYPE)
return {

@@ -62,213 +235,11 @@ aliases: ["ps", "ps1"],

case_insensitive: true,
keywords: {
keyword:
"if else foreach return function do while until elseif begin for trap data dynamicparam end break throw param continue finally in switch exit filter try process catch" +
"ValidateNoCircleInNodeResources ValidateNodeExclusiveResources ValidateNodeManager ValidateNodeResources ValidateNodeResourceSource ValidateNoNameNodeResources ThrowError IsHiddenResource" +
"IsPatternMatched ",
built_in:
"Add-Computer Add-Content Add-History Add-JobTrigger Add-Member Add-PSSnapin Add-Type Checkpoint-Computer Clear-Content " +
"Clear-EventLog Clear-History Clear-Host Clear-Item Clear-ItemProperty Clear-Variable Compare-Object Complete-Transaction Connect-PSSession " +
"Connect-WSMan Convert-Path ConvertFrom-Csv ConvertFrom-Json ConvertFrom-SecureString ConvertFrom-StringData ConvertTo-Csv ConvertTo-Html " +
"ConvertTo-Json ConvertTo-SecureString ConvertTo-Xml Copy-Item Copy-ItemProperty Debug-Process Disable-ComputerRestore Disable-JobTrigger " +
"Disable-PSBreakpoint Disable-PSRemoting Disable-PSSessionConfiguration Disable-WSManCredSSP Disconnect-PSSession Disconnect-WSMan " +
"Disable-ScheduledJob Enable-ComputerRestore Enable-JobTrigger Enable-PSBreakpoint Enable-PSRemoting Enable-PSSessionConfiguration " +
"Enable-ScheduledJob Enable-WSManCredSSP Enter-PSSession Exit-PSSession Export-Alias Export-Clixml Export-Console Export-Counter Export-Csv " +
"Export-FormatData Export-ModuleMember Export-PSSession ForEach-Object Format-Custom Format-List Format-Table Format-Wide Get-Acl Get-Alias " +
"Get-AuthenticodeSignature Get-ChildItem Get-Command Get-ComputerRestorePoint Get-Content Get-ControlPanelItem Get-Counter Get-Credential " +
"Get-Culture Get-Date Get-Event Get-EventLog Get-EventSubscriber Get-ExecutionPolicy Get-FormatData Get-Host Get-HotFix Get-Help Get-History " +
"Get-IseSnippet Get-Item Get-ItemProperty Get-Job Get-JobTrigger Get-Location Get-Member Get-Module Get-PfxCertificate Get-Process " +
"Get-PSBreakpoint Get-PSCallStack Get-PSDrive Get-PSProvider Get-PSSession Get-PSSessionConfiguration Get-PSSnapin Get-Random Get-ScheduledJob " +
"Get-ScheduledJobOption Get-Service Get-TraceSource Get-Transaction Get-TypeData Get-UICulture Get-Unique Get-Variable Get-Verb Get-WinEvent " +
"Get-WmiObject Get-WSManCredSSP Get-WSManInstance Group-Object Import-Alias Import-Clixml Import-Counter Import-Csv Import-IseSnippet " +
"Import-LocalizedData Import-PSSession Import-Module Invoke-AsWorkflow Invoke-Command Invoke-Expression Invoke-History Invoke-Item " +
"Invoke-RestMethod Invoke-WebRequest Invoke-WmiMethod Invoke-WSManAction Join-Path Limit-EventLog Measure-Command Measure-Object Move-Item " +
"Move-ItemProperty New-Alias New-Event New-EventLog New-IseSnippet New-Item New-ItemProperty New-JobTrigger New-Object New-Module " +
"New-ModuleManifest New-PSDrive New-PSSession New-PSSessionConfigurationFile New-PSSessionOption New-PSTransportOption " +
"New-PSWorkflowExecutionOption New-PSWorkflowSession New-ScheduledJobOption New-Service New-TimeSpan New-Variable New-WebServiceProxy " +
"New-WinEvent New-WSManInstance New-WSManSessionOption Out-Default Out-File Out-GridView Out-Host Out-Null Out-Printer Out-String Pop-Location " +
"Push-Location Read-Host Receive-Job Register-EngineEvent Register-ObjectEvent Register-PSSessionConfiguration Register-ScheduledJob " +
"Register-WmiEvent Remove-Computer Remove-Event Remove-EventLog Remove-Item Remove-ItemProperty Remove-Job Remove-JobTrigger Remove-Module " +
"Remove-PSBreakpoint Remove-PSDrive Remove-PSSession Remove-PSSnapin Remove-TypeData Remove-Variable Remove-WmiObject Remove-WSManInstance " +
"Rename-Computer Rename-Item Rename-ItemProperty Reset-ComputerMachinePassword Resolve-Path Restart-Computer Restart-Service Restore-Computer " +
"Resume-Job Resume-Service Save-Help Select-Object Select-String Select-Xml Send-MailMessage Set-Acl Set-Alias Set-AuthenticodeSignature " +
"Set-Content Set-Date Set-ExecutionPolicy Set-Item Set-ItemProperty Set-JobTrigger Set-Location Set-PSBreakpoint Set-PSDebug " +
"Set-PSSessionConfiguration Set-ScheduledJob Set-ScheduledJobOption Set-Service Set-StrictMode Set-TraceSource Set-Variable Set-WmiInstance " +
"Set-WSManInstance Set-WSManQuickConfig Show-Command Show-ControlPanelItem Show-EventLog Sort-Object Split-Path Start-Job Start-Process " +
"Start-Service Start-Sleep Start-Transaction Start-Transcript Stop-Computer Stop-Job Stop-Process Stop-Service Stop-Transcript Suspend-Job " +
"Suspend-Service Tee-Object Test-ComputerSecureChannel Test-Connection Test-ModuleManifest Test-Path Test-PSSessionConfigurationFile " +
"Trace-Command Unblock-File Undo-Transaction Unregister-Event Unregister-PSSessionConfiguration Unregister-ScheduledJob Update-FormatData " +
"Update-Help Update-List Update-TypeData Use-Transaction Wait-Event Wait-Job Wait-Process Where-Object Write-Debug Write-Error Write-EventLog " +
"Write-Host Write-Output Write-Progress Write-Verbose Write-Warning Add-MDTPersistentDrive Disable-MDTMonitorService Enable-MDTMonitorService " +
"Get-MDTDeploymentShareStatistics Get-MDTMonitorData Get-MDTOperatingSystemCatalog Get-MDTPersistentDrive Import-MDTApplication " +
"Import-MDTDriver Import-MDTOperatingSystem Import-MDTPackage Import-MDTTaskSequence New-MDTDatabase Remove-MDTMonitorData " +
"Remove-MDTPersistentDrive Restore-MDTPersistentDrive Set-MDTMonitorData Test-MDTDeploymentShare Test-MDTMonitorData Update-MDTDatabaseSchema " +
"Update-MDTDeploymentShare Update-MDTLinkedDS Update-MDTMedia Add-VamtProductKey Export-VamtData Find-VamtManagedMachine " +
"Get-VamtConfirmationId Get-VamtProduct Get-VamtProductKey Import-VamtData Initialize-VamtData Install-VamtConfirmationId " +
"Install-VamtProductActivation Install-VamtProductKey Update-VamtProduct Add-CIDatastore Add-KeyManagementServer Add-NodeKeys " +
"Add-NsxDynamicCriteria Add-NsxDynamicMemberSet Add-NsxEdgeInterfaceAddress Add-NsxFirewallExclusionListMember Add-NsxFirewallRuleMember " +
"Add-NsxIpSetMember Add-NsxLicense Add-NsxLoadBalancerPoolMember Add-NsxLoadBalancerVip Add-NsxSecondaryManager Add-NsxSecurityGroupMember " +
"Add-NsxSecurityPolicyRule Add-NsxSecurityPolicyRuleGroup Add-NsxSecurityPolicyRuleService Add-NsxServiceGroupMember " +
"Add-NsxTransportZoneMember Add-PassthroughDevice Add-VDSwitchPhysicalNetworkAdapter Add-VDSwitchVMHost Add-VMHost Add-VMHostNtpServer " +
"Add-VirtualSwitchPhysicalNetworkAdapter Add-XmlElement Add-vRACustomForm Add-vRAPrincipalToTenantRole Add-vRAReservationNetwork " +
"Add-vRAReservationStorage Clear-NsxEdgeInterface Clear-NsxManagerTimeSettings Compress-Archive Connect-CIServer Connect-CisServer " +
"Connect-HCXServer Connect-NIServer Connect-NsxLogicalSwitch Connect-NsxServer Connect-NsxtServer Connect-SrmServer Connect-VIServer " +
"Connect-Vmc Connect-vRAServer Connect-vRNIServer ConvertFrom-Markdown ConvertTo-MOFInstance Copy-DatastoreItem Copy-HardDisk Copy-NsxEdge " +
"Copy-VDisk Copy-VMGuestFile Debug-Runspace Disable-NsxEdgeSsh Disable-RunspaceDebug Disable-vRNIDataSource Disconnect-CIServer " +
"Disconnect-CisServer Disconnect-HCXServer Disconnect-NsxLogicalSwitch Disconnect-NsxServer Disconnect-NsxtServer Disconnect-SrmServer " +
"Disconnect-VIServer Disconnect-Vmc Disconnect-vRAServer Disconnect-vRNIServer Dismount-Tools Enable-NsxEdgeSsh Enable-RunspaceDebug " +
"Enable-vRNIDataSource Expand-Archive Export-NsxObject Export-SpbmStoragePolicy Export-VApp Export-VDPortGroup Export-VDSwitch " +
"Export-VMHostProfile Export-vRAIcon Export-vRAPackage Find-Command Find-DscResource Find-Module Find-NsxWhereVMUsed Find-Package " +
"Find-PackageProvider Find-RoleCapability Find-Script Format-Hex Format-VMHostDiskPartition Format-XML Generate-VersionInfo " +
"Get-AdvancedSetting Get-AlarmAction Get-AlarmActionTrigger Get-AlarmDefinition Get-Annotation Get-CDDrive Get-CIAccessControlRule " +
"Get-CIDatastore Get-CINetworkAdapter Get-CIRole Get-CIUser Get-CIVApp Get-CIVAppNetwork Get-CIVAppStartRule Get-CIVAppTemplate Get-CIVM " +
"Get-CIVMTemplate Get-CIView Get-Catalog Get-CisCommand Get-CisService Get-CloudCommand Get-Cluster Get-CompatibleVersionAddtionaPropertiesStr " +
"Get-ComplexResourceQualifier Get-ConfigurationErrorCount Get-ContentLibraryItem Get-CustomAttribute Get-DSCResourceModules Get-Datacenter " +
"Get-Datastore Get-DatastoreCluster Get-DrsClusterGroup Get-DrsRecommendation Get-DrsRule Get-DrsVMHostRule Get-DscResource Get-EdgeGateway " +
"Get-EncryptedPassword Get-ErrorReport Get-EsxCli Get-EsxTop Get-ExternalNetwork Get-FileHash Get-FloppyDrive Get-Folder Get-HAPrimaryVMHost " +
"Get-HCXAppliance Get-HCXApplianceCompute Get-HCXApplianceDVS Get-HCXApplianceDatastore Get-HCXApplianceNetwork Get-HCXContainer " +
"Get-HCXDatastore Get-HCXGateway Get-HCXInterconnectStatus Get-HCXJob Get-HCXMigration Get-HCXNetwork Get-HCXNetworkExtension " +
"Get-HCXReplication Get-HCXReplicationSnapshot Get-HCXService Get-HCXSite Get-HCXSitePairing Get-HCXVM Get-HardDisk Get-IScsiHbaTarget " +
"Get-InnerMostErrorRecord Get-InstallPath Get-InstalledModule Get-InstalledScript Get-Inventory Get-ItemPropertyValue Get-KeyManagementServer " +
"Get-KmipClientCertificate Get-KmsCluster Get-Log Get-LogType Get-MarkdownOption Get-Media Get-MofInstanceName Get-MofInstanceText Get-NetworkAdapter Get-NetworkPool " +
"Get-NfsUser Get-NicTeamingPolicy Get-NsxApplicableMember Get-NsxApplicableSecurityAction Get-NsxBackingDVSwitch Get-NsxBackingPortGroup Get-NsxCliDfwAddrSet " +
"Get-NsxCliDfwFilter Get-NsxCliDfwRule Get-NsxClusterStatus Get-NsxController Get-NsxDynamicCriteria Get-NsxDynamicMemberSet Get-NsxEdge Get-NsxEdgeBgp " +
"Get-NsxEdgeBgpNeighbour Get-NsxEdgeCertificate Get-NsxEdgeCsr Get-NsxEdgeFirewall Get-NsxEdgeFirewallRule Get-NsxEdgeInterface Get-NsxEdgeInterfaceAddress " +
"Get-NsxEdgeNat Get-NsxEdgeNatRule Get-NsxEdgeOspf Get-NsxEdgeOspfArea Get-NsxEdgeOspfInterface Get-NsxEdgePrefix Get-NsxEdgeRedistributionRule Get-NsxEdgeRouting " +
"Get-NsxEdgeStaticRoute Get-NsxEdgeSubInterface Get-NsxFirewallExclusionListMember Get-NsxFirewallGlobalConfiguration Get-NsxFirewallPublishStatus Get-NsxFirewallRule " +
"Get-NsxFirewallRuleMember Get-NsxFirewallSavedConfiguration Get-NsxFirewallSection Get-NsxFirewallThreshold Get-NsxIpPool Get-NsxIpSet Get-NsxLicense Get-NsxLoadBalancer " +
"Get-NsxLoadBalancerApplicationProfile Get-NsxLoadBalancerApplicationRule Get-NsxLoadBalancerMonitor Get-NsxLoadBalancerPool Get-NsxLoadBalancerPoolMember Get-NsxLoadBalancerStats " +
"Get-NsxLoadBalancerVip Get-NsxLogicalRouter Get-NsxLogicalRouterBgp Get-NsxLogicalRouterBgpNeighbour Get-NsxLogicalRouterBridge Get-NsxLogicalRouterBridging " +
"Get-NsxLogicalRouterInterface Get-NsxLogicalRouterOspf Get-NsxLogicalRouterOspfArea Get-NsxLogicalRouterOspfInterface Get-NsxLogicalRouterPrefix " +
"Get-NsxLogicalRouterRedistributionRule Get-NsxLogicalRouterRouting Get-NsxLogicalRouterStaticRoute Get-NsxLogicalSwitch Get-NsxMacSet Get-NsxManagerBackup " +
"Get-NsxManagerCertificate Get-NsxManagerComponentSummary Get-NsxManagerNetwork Get-NsxManagerRole Get-NsxManagerSsoConfig Get-NsxManagerSyncStatus Get-NsxManagerSyslogServer " +
"Get-NsxManagerSystemSummary Get-NsxManagerTimeSettings Get-NsxManagerVcenterConfig Get-NsxSecondaryManager Get-NsxSecurityGroup Get-NsxSecurityGroupEffectiveIpAddress " +
"Get-NsxSecurityGroupEffectiveMacAddress Get-NsxSecurityGroupEffectiveMember Get-NsxSecurityGroupEffectiveVirtualMachine Get-NsxSecurityGroupEffectiveVnic " +
"Get-NsxSecurityGroupMemberTypes Get-NsxSecurityPolicy Get-NsxSecurityPolicyHighestUsedPrecedence Get-NsxSecurityPolicyRule Get-NsxSecurityTag Get-NsxSecurityTagAssignment " +
"Get-NsxSegmentIdRange Get-NsxService Get-NsxServiceDefinition Get-NsxServiceGroup Get-NsxServiceGroupMember Get-NsxServiceProfile Get-NsxSpoofguardNic Get-NsxSpoofguardPolicy " +
"Get-NsxSslVpn Get-NsxSslVpnAuthServer Get-NsxSslVpnClientInstallationPackage Get-NsxSslVpnIpPool Get-NsxSslVpnPrivateNetwork Get-NsxSslVpnUser Get-NsxTransportZone " +
"Get-NsxUserRole Get-NsxVdsContext Get-NsxtPolicyService Get-NsxtService Get-OSCustomizationNicMapping Get-OSCustomizationSpec Get-Org Get-OrgNetwork Get-OrgVdc " +
"Get-OrgVdcNetwork Get-OvfConfiguration Get-PSCurrentConfigurationNode Get-PSDefaultConfigurationDocument Get-PSMetaConfigDocumentInstVersionInfo Get-PSMetaConfigurationProcessed " +
"Get-PSReadLineKeyHandler Get-PSReadLineOption Get-PSRepository Get-PSTopConfigurationName Get-PSVersion Get-Package Get-PackageProvider Get-PackageSource Get-PassthroughDevice " +
"Get-PositionInfo Get-PowerCLICommunity Get-PowerCLIConfiguration Get-PowerCLIHelp Get-PowerCLIVersion Get-PowerNsxVersion Get-ProviderVdc Get-PublicKeyFromFile " +
"Get-PublicKeyFromStore Get-ResourcePool Get-Runspace Get-RunspaceDebug Get-ScsiController Get-ScsiLun Get-ScsiLunPath Get-SecurityInfo Get-SecurityPolicy Get-Snapshot " +
"Get-SpbmCapability Get-SpbmCompatibleStorage Get-SpbmEntityConfiguration Get-SpbmFaultDomain Get-SpbmPointInTimeReplica Get-SpbmReplicationGroup Get-SpbmReplicationPair " +
"Get-SpbmStoragePolicy Get-Stat Get-StatInterval Get-StatType Get-Tag Get-TagAssignment Get-TagCategory Get-Task Get-Template Get-TimeZone Get-Uptime Get-UsbDevice Get-VAIOFilter " +
"Get-VApp Get-VDBlockedPolicy Get-VDPort Get-VDPortgroup Get-VDPortgroupOverridePolicy Get-VDSecurityPolicy Get-VDSwitch Get-VDSwitchPrivateVlan Get-VDTrafficShapingPolicy " +
"Get-VDUplinkLacpPolicy Get-VDUplinkTeamingPolicy Get-VDisk Get-VIAccount Get-VICommand Get-VICredentialStoreItem Get-VIEvent Get-VIObjectByVIView Get-VIPermission Get-VIPrivilege " +
"Get-VIProperty Get-VIRole Get-VM Get-VMGuest Get-VMHost Get-VMHostAccount Get-VMHostAdvancedConfiguration Get-VMHostAuthentication Get-VMHostAvailableTimeZone " +
"Get-VMHostDiagnosticPartition Get-VMHostDisk Get-VMHostDiskPartition Get-VMHostFirewallDefaultPolicy Get-VMHostFirewallException Get-VMHostFirmware Get-VMHostHardware " +
"Get-VMHostHba Get-VMHostModule Get-VMHostNetwork Get-VMHostNetworkAdapter Get-VMHostNtpServer Get-VMHostPatch Get-VMHostPciDevice Get-VMHostProfile " +
"Get-VMHostProfileImageCacheConfiguration Get-VMHostProfileRequiredInput Get-VMHostProfileStorageDeviceConfiguration Get-VMHostProfileUserConfiguration " +
"Get-VMHostProfileVmPortGroupConfiguration Get-VMHostRoute Get-VMHostService Get-VMHostSnmp Get-VMHostStartPolicy Get-VMHostStorage Get-VMHostSysLogServer Get-VMQuestion " +
"Get-VMResourceConfiguration Get-VMStartPolicy Get-VTpm Get-VTpmCSR Get-VTpmCertificate Get-VasaProvider Get-VasaStorageArray Get-View Get-VirtualPortGroup Get-VirtualSwitch " +
"Get-VmcSddcNetworkService Get-VmcService Get-VsanClusterConfiguration Get-VsanComponent Get-VsanDisk Get-VsanDiskGroup Get-VsanEvacuationPlan Get-VsanFaultDomain " +
"Get-VsanIscsiInitiatorGroup Get-VsanIscsiInitiatorGroupTargetAssociation Get-VsanIscsiLun Get-VsanIscsiTarget Get-VsanObject Get-VsanResyncingComponent Get-VsanRuntimeInfo " +
"Get-VsanSpaceUsage Get-VsanStat Get-VsanView Get-vRAApplianceServiceStatus Get-vRAAuthorizationRole Get-vRABlueprint Get-vRABusinessGroup Get-vRACatalogItem " +
"Get-vRACatalogItemRequestTemplate Get-vRACatalogPrincipal Get-vRAComponentRegistryService Get-vRAComponentRegistryServiceEndpoint Get-vRAComponentRegistryServiceStatus " +
"Get-vRAContent Get-vRAContentData Get-vRAContentType Get-vRACustomForm Get-vRAEntitledCatalogItem Get-vRAEntitledService Get-vRAEntitlement Get-vRAExternalNetworkProfile " +
"Get-vRAGroupPrincipal Get-vRAIcon Get-vRANATNetworkProfile Get-vRANetworkProfileIPAddressList Get-vRANetworkProfileIPRangeSummary Get-vRAPackage Get-vRAPackageContent " +
"Get-vRAPropertyDefinition Get-vRAPropertyGroup Get-vRARequest Get-vRARequestDetail Get-vRAReservation Get-vRAReservationComputeResource Get-vRAReservationComputeResourceMemory " +
"Get-vRAReservationComputeResourceNetwork Get-vRAReservationComputeResourceResourcePool Get-vRAReservationComputeResourceStorage Get-vRAReservationPolicy " +
"Get-vRAReservationTemplate Get-vRAReservationType Get-vRAResource Get-vRAResourceAction Get-vRAResourceActionRequestTemplate Get-vRAResourceMetric Get-vRAResourceOperation " +
"Get-vRAResourceType Get-vRARoutedNetworkProfile Get-vRAService Get-vRAServiceBlueprint Get-vRASourceMachine Get-vRAStorageReservationPolicy Get-vRATenant Get-vRATenantDirectory " +
"Get-vRATenantDirectoryStatus Get-vRATenantRole Get-vRAUserPrincipal Get-vRAUserPrincipalGroupMembership Get-vRAVersion Get-vRNIAPIVersion Get-vRNIApplication " +
"Get-vRNIApplicationTier Get-vRNIDataSource Get-vRNIDataSourceSNMPConfig Get-vRNIDatastore Get-vRNIDistributedSwitch Get-vRNIDistributedSwitchPortGroup Get-vRNIEntity " +
"Get-vRNIEntityName Get-vRNIFirewallRule Get-vRNIFlow Get-vRNIHost Get-vRNIHostVMKNic Get-vRNIIPSet Get-vRNIL2Network Get-vRNINSXManager Get-vRNINodes Get-vRNIProblem " +
"Get-vRNIRecommendedRules Get-vRNIRecommendedRulesNsxBundle Get-vRNISecurityGroup Get-vRNISecurityTag Get-vRNIService Get-vRNIServiceGroup Get-vRNIVM Get-vRNIVMvNIC " +
"Get-vRNIvCenter Get-vRNIvCenterCluster Get-vRNIvCenterDatacenter Get-vRNIvCenterFolder Grant-NsxSpoofguardNicApproval Import-CIVApp Import-CIVAppTemplate Import-NsxObject " +
"Import-PackageProvider Import-PowerShellDataFile Import-SpbmStoragePolicy Import-VApp Import-VMHostProfile Import-vRAContentData Import-vRAIcon Import-vRAPackage " +
"Initialize-ConfigurationRuntimeState Install-Module Install-NsxCluster Install-Package Install-PackageProvider Install-Script Install-VMHostPatch Invoke-DrsRecommendation " +
"Invoke-NsxCli Invoke-NsxClusterResolveAll Invoke-NsxManagerSync Invoke-NsxRestMethod Invoke-NsxWebRequest Invoke-VMHostProfile Invoke-VMScript Invoke-XpathQuery " +
"Invoke-vRADataCollection Invoke-vRARestMethod Invoke-vRATenantDirectorySync Invoke-vRNIRestMethod Join-String Mount-Tools Move-Cluster Move-Datacenter Move-Datastore Move-Folder " +
"Move-HardDisk Move-Inventory Move-NsxSecurityPolicyRule Move-ResourcePool Move-Template Move-VApp Move-VDisk Move-VM Move-VMHost New-AdvancedSetting New-AlarmAction " +
"New-AlarmActionTrigger New-CDDrive New-CIAccessControlRule New-CIVApp New-CIVAppNetwork New-CIVAppTemplate New-CIVM New-Cluster New-CustomAttribute New-Datacenter New-Datastore " +
"New-DatastoreCluster New-DatastoreDrive New-DrsClusterGroup New-DrsRule New-DrsVMHostRule New-DscChecksum New-FloppyDrive New-Folder New-Guid New-HCXAppliance New-HCXMigration " +
"New-HCXNetworkExtension New-HCXNetworkMapping New-HCXReplication New-HCXSitePairing New-HCXStaticRoute New-HardDisk New-IScsiHbaTarget New-KmipClientCertificate " +
"New-NetworkAdapter New-NfsUser New-NsxAddressSpec New-NsxClusterVxlanConfig New-NsxController New-NsxDynamicCriteriaSpec New-NsxEdge New-NsxEdgeBgpNeighbour New-NsxEdgeCsr " +
"New-NsxEdgeFirewallRule New-NsxEdgeInterfaceSpec New-NsxEdgeNatRule New-NsxEdgeOspfArea New-NsxEdgeOspfInterface New-NsxEdgePrefix New-NsxEdgeRedistributionRule " +
"New-NsxEdgeSelfSignedCertificate New-NsxEdgeStaticRoute New-NsxEdgeSubInterface New-NsxEdgeSubInterfaceSpec New-NsxFirewallRule New-NsxFirewallSavedConfiguration " +
"New-NsxFirewallSection New-NsxIpPool New-NsxIpSet New-NsxLoadBalancerApplicationProfile New-NsxLoadBalancerApplicationRule New-NsxLoadBalancerMemberSpec " +
"New-NsxLoadBalancerMonitor New-NsxLoadBalancerPool New-NsxLogicalRouter New-NsxLogicalRouterBgpNeighbour New-NsxLogicalRouterBridge New-NsxLogicalRouterInterface " +
"New-NsxLogicalRouterInterfaceSpec New-NsxLogicalRouterOspfArea New-NsxLogicalRouterOspfInterface New-NsxLogicalRouterPrefix New-NsxLogicalRouterRedistributionRule " +
"New-NsxLogicalRouterStaticRoute New-NsxLogicalSwitch New-NsxMacSet New-NsxManager New-NsxSecurityGroup New-NsxSecurityPolicy New-NsxSecurityPolicyAssignment " +
"New-NsxSecurityPolicyFirewallRuleSpec New-NsxSecurityPolicyGuestIntrospectionSpec New-NsxSecurityPolicyNetworkIntrospectionSpec New-NsxSecurityTag New-NsxSecurityTagAssignment " +
"New-NsxSegmentIdRange New-NsxService New-NsxServiceGroup New-NsxSpoofguardPolicy New-NsxSslVpnAuthServer New-NsxSslVpnClientInstallationPackage New-NsxSslVpnIpPool " +
"New-NsxSslVpnPrivateNetwork New-NsxSslVpnUser New-NsxTransportZone New-NsxVdsContext New-OSCustomizationNicMapping New-OSCustomizationSpec New-Org New-OrgNetwork New-OrgVdc " +
"New-OrgVdcNetwork New-ResourcePool New-ScriptFileInfo New-ScsiController New-Snapshot New-SpbmRule New-SpbmRuleSet New-SpbmStoragePolicy New-StatInterval New-Tag " +
"New-TagAssignment New-TagCategory New-Template New-TemporaryFile New-VAIOFilter New-VApp New-VDPortgroup New-VDSwitch New-VDSwitchPrivateVlan New-VDisk " +
"New-VICredentialStoreItem New-VIInventoryDrive New-VIPermission New-VIProperty New-VIRole New-VISamlSecurityContext New-VM New-VMHostAccount New-VMHostNetworkAdapter " +
"New-VMHostProfile New-VMHostProfileVmPortGroupConfiguration New-VMHostRoute New-VTpm New-VasaProvider New-VcsOAuthSecurityContext New-VirtualPortGroup New-VirtualSwitch " +
"New-VsanDisk New-VsanDiskGroup New-VsanFaultDomain New-VsanIscsiInitiatorGroup New-VsanIscsiInitiatorGroupTargetAssociation New-VsanIscsiLun New-VsanIscsiTarget " +
"New-vRABusinessGroup New-vRAEntitlement New-vRAExternalNetworkProfile New-vRAGroupPrincipal New-vRANATNetworkProfile New-vRANetworkProfileIPRangeDefinition New-vRAPackage " +
"New-vRAPropertyDefinition New-vRAPropertyGroup New-vRAReservation New-vRAReservationNetworkDefinition New-vRAReservationPolicy New-vRAReservationStorageDefinition " +
"New-vRARoutedNetworkProfile New-vRAService New-vRAStorageReservationPolicy New-vRATenant New-vRATenantDirectory New-vRAUserPrincipal New-vRNIApplication New-vRNIApplicationTier " +
"New-vRNIDataSource Open-VMConsoleWindow Publish-Module Publish-NsxSpoofguardPolicy Publish-Script Register-PSRepository Register-PackageSource Remove-AdvancedSetting " +
"Remove-AlarmAction Remove-AlarmActionTrigger Remove-Alias Remove-CDDrive Remove-CIAccessControlRule Remove-CIVApp Remove-CIVAppNetwork Remove-CIVAppTemplate Remove-Cluster " +
"Remove-CustomAttribute Remove-Datacenter Remove-Datastore Remove-DatastoreCluster Remove-DrsClusterGroup Remove-DrsRule Remove-DrsVMHostRule Remove-FloppyDrive Remove-Folder " +
"Remove-HCXAppliance Remove-HCXNetworkExtension Remove-HCXReplication Remove-HCXSitePairing Remove-HardDisk Remove-IScsiHbaTarget Remove-Inventory Remove-KeyManagementServer " +
"Remove-NetworkAdapter Remove-NfsUser Remove-NsxCluster Remove-NsxClusterVxlanConfig Remove-NsxController Remove-NsxDynamicCriteria Remove-NsxDynamicMemberSet Remove-NsxEdge " +
"Remove-NsxEdgeBgpNeighbour Remove-NsxEdgeCertificate Remove-NsxEdgeCsr Remove-NsxEdgeFirewallRule Remove-NsxEdgeInterfaceAddress Remove-NsxEdgeNatRule Remove-NsxEdgeOspfArea " +
"Remove-NsxEdgeOspfInterface Remove-NsxEdgePrefix Remove-NsxEdgeRedistributionRule Remove-NsxEdgeStaticRoute Remove-NsxEdgeSubInterface Remove-NsxFirewallExclusionListMember " +
"Remove-NsxFirewallRule Remove-NsxFirewallRuleMember Remove-NsxFirewallSavedConfiguration Remove-NsxFirewallSection Remove-NsxIpPool Remove-NsxIpSet Remove-NsxIpSetMember " +
"Remove-NsxLoadBalancerApplicationProfile Remove-NsxLoadBalancerMonitor Remove-NsxLoadBalancerPool Remove-NsxLoadBalancerPoolMember Remove-NsxLoadBalancerVip " +
"Remove-NsxLogicalRouter Remove-NsxLogicalRouterBgpNeighbour Remove-NsxLogicalRouterBridge Remove-NsxLogicalRouterInterface Remove-NsxLogicalRouterOspfArea " +
"Remove-NsxLogicalRouterOspfInterface Remove-NsxLogicalRouterPrefix Remove-NsxLogicalRouterRedistributionRule Remove-NsxLogicalRouterStaticRoute Remove-NsxLogicalSwitch " +
"Remove-NsxMacSet Remove-NsxSecondaryManager Remove-NsxSecurityGroup Remove-NsxSecurityGroupMember Remove-NsxSecurityPolicy Remove-NsxSecurityPolicyAssignment " +
"Remove-NsxSecurityPolicyRule Remove-NsxSecurityPolicyRuleGroup Remove-NsxSecurityPolicyRuleService Remove-NsxSecurityTag Remove-NsxSecurityTagAssignment " +
"Remove-NsxSegmentIdRange Remove-NsxService Remove-NsxServiceGroup Remove-NsxSpoofguardPolicy Remove-NsxSslVpnClientInstallationPackage Remove-NsxSslVpnIpPool " +
"Remove-NsxSslVpnPrivateNetwork Remove-NsxSslVpnUser Remove-NsxTransportZone Remove-NsxTransportZoneMember Remove-NsxVdsContext Remove-OSCustomizationNicMapping " +
"Remove-OSCustomizationSpec Remove-Org Remove-OrgNetwork Remove-OrgVdc Remove-OrgVdcNetwork Remove-PSReadLineKeyHandler Remove-PassthroughDevice Remove-ResourcePool " +
"Remove-Snapshot Remove-SpbmStoragePolicy Remove-StatInterval Remove-Tag Remove-TagAssignment Remove-TagCategory Remove-Template Remove-UsbDevice Remove-VAIOFilter Remove-VApp " +
"Remove-VDPortGroup Remove-VDSwitch Remove-VDSwitchPhysicalNetworkAdapter Remove-VDSwitchPrivateVlan Remove-VDSwitchVMHost Remove-VDisk Remove-VICredentialStoreItem " +
"Remove-VIPermission Remove-VIProperty Remove-VIRole Remove-VM Remove-VMHost Remove-VMHostAccount Remove-VMHostNetworkAdapter Remove-VMHostNtpServer Remove-VMHostProfile " +
"Remove-VMHostProfileVmPortGroupConfiguration Remove-VMHostRoute Remove-VTpm Remove-VasaProvider Remove-VirtualPortGroup Remove-VirtualSwitch " +
"Remove-VirtualSwitchPhysicalNetworkAdapter Remove-VsanDisk Remove-VsanDiskGroup Remove-VsanFaultDomain Remove-VsanIscsiInitiatorGroup " +
"Remove-VsanIscsiInitiatorGroupTargetAssociation Remove-VsanIscsiLun Remove-VsanIscsiTarget Remove-vRABusinessGroup Remove-vRACustomForm Remove-vRAExternalNetworkProfile " +
"Remove-vRAGroupPrincipal Remove-vRAIcon Remove-vRANATNetworkProfile Remove-vRAPackage Remove-vRAPrincipalFromTenantRole Remove-vRAPropertyDefinition Remove-vRAPropertyGroup " +
"Remove-vRAReservation Remove-vRAReservationNetwork Remove-vRAReservationPolicy Remove-vRAReservationStorage Remove-vRARoutedNetworkProfile Remove-vRAService " +
"Remove-vRAStorageReservationPolicy Remove-vRATenant Remove-vRATenantDirectory Remove-vRAUserPrincipal Remove-vRNIApplication Remove-vRNIApplicationTier Remove-vRNIDataSource " +
"Repair-NsxEdge Repair-VsanObject Request-vRACatalogItem Request-vRAResourceAction Restart-CIVApp Restart-CIVAppGuest Restart-CIVM Restart-CIVMGuest Restart-VM Restart-VMGuest " +
"Restart-VMHost Restart-VMHostService Resume-HCXReplication Revoke-NsxSpoofguardNicApproval Save-Module Save-Package Save-Script Search-Cloud Set-AdvancedSetting " +
"Set-AlarmDefinition Set-Annotation Set-CDDrive Set-CIAccessControlRule Set-CINetworkAdapter Set-CIVApp Set-CIVAppNetwork Set-CIVAppStartRule Set-CIVAppTemplate Set-Cluster " +
"Set-CustomAttribute Set-Datacenter Set-Datastore Set-DatastoreCluster Set-DrsClusterGroup Set-DrsRule Set-DrsVMHostRule Set-FloppyDrive Set-Folder Set-HCXAppliance " +
"Set-HCXMigration Set-HCXReplication Set-HardDisk Set-IScsiHbaTarget Set-KeyManagementServer Set-KmsCluster Set-MarkdownOption Set-NetworkAdapter Set-NfsUser Set-NicTeamingPolicy " +
"Set-NodeExclusiveResources Set-NodeManager Set-NodeResourceSource Set-NodeResources Set-NsxEdge Set-NsxEdgeBgp Set-NsxEdgeFirewall Set-NsxEdgeInterface Set-NsxEdgeNat " +
"Set-NsxEdgeOspf Set-NsxEdgeRouting Set-NsxFirewallGlobalConfiguration Set-NsxFirewallRule Set-NsxFirewallSavedConfiguration Set-NsxFirewallThreshold Set-NsxLoadBalancer " +
"Set-NsxLoadBalancerPoolMember Set-NsxLogicalRouter Set-NsxLogicalRouterBgp Set-NsxLogicalRouterBridging Set-NsxLogicalRouterInterface Set-NsxLogicalRouterOspf " +
"Set-NsxLogicalRouterRouting Set-NsxManager Set-NsxManagerRole Set-NsxManagerTimeSettings Set-NsxSecurityPolicy Set-NsxSecurityPolicyFirewallRule Set-NsxSslVpn " +
"Set-OSCustomizationNicMapping Set-OSCustomizationSpec Set-Org Set-OrgNetwork Set-OrgVdc Set-OrgVdcNetwork Set-PSCurrentConfigurationNode Set-PSDefaultConfigurationDocument " +
"Set-PSMetaConfigDocInsProcessedBeforeMeta Set-PSMetaConfigVersionInfoV2 Set-PSReadLineKeyHandler Set-PSReadLineOption Set-PSRepository Set-PSTopConfigurationName " +
"Set-PackageSource Set-PowerCLIConfiguration Set-ResourcePool Set-ScsiController Set-ScsiLun Set-ScsiLunPath Set-SecurityPolicy Set-Snapshot Set-SpbmEntityConfiguration " +
"Set-SpbmStoragePolicy Set-StatInterval Set-Tag Set-TagCategory Set-Template Set-VAIOFilter Set-VApp Set-VDBlockedPolicy Set-VDPort Set-VDPortgroup Set-VDPortgroupOverridePolicy " +
"Set-VDSecurityPolicy Set-VDSwitch Set-VDTrafficShapingPolicy Set-VDUplinkLacpPolicy Set-VDUplinkTeamingPolicy Set-VDVlanConfiguration Set-VDisk Set-VIPermission Set-VIRole Set-VM " +
"Set-VMHost Set-VMHostAccount Set-VMHostAdvancedConfiguration Set-VMHostAuthentication Set-VMHostDiagnosticPartition Set-VMHostFirewallDefaultPolicy Set-VMHostFirewallException " +
"Set-VMHostFirmware Set-VMHostHba Set-VMHostModule Set-VMHostNetwork Set-VMHostNetworkAdapter Set-VMHostProfile Set-VMHostProfileImageCacheConfiguration " +
"Set-VMHostProfileStorageDeviceConfiguration Set-VMHostProfileUserConfiguration Set-VMHostProfileVmPortGroupConfiguration Set-VMHostRoute Set-VMHostService Set-VMHostSnmp " +
"Set-VMHostStartPolicy Set-VMHostStorage Set-VMHostSysLogServer Set-VMQuestion Set-VMResourceConfiguration Set-VMStartPolicy Set-VTpm Set-VirtualPortGroup Set-VirtualSwitch " +
"Set-VsanClusterConfiguration Set-VsanFaultDomain Set-VsanIscsiInitiatorGroup Set-VsanIscsiLun Set-VsanIscsiTarget Set-vRABusinessGroup Set-vRACatalogItem Set-vRACustomForm " +
"Set-vRAEntitlement Set-vRAExternalNetworkProfile Set-vRANATNetworkProfile Set-vRAReservation Set-vRAReservationNetwork Set-vRAReservationPolicy Set-vRAReservationStorage " +
"Set-vRARoutedNetworkProfile Set-vRAService Set-vRAStorageReservationPolicy Set-vRATenant Set-vRATenantDirectory Set-vRAUserPrincipal Set-vRNIDataSourceSNMPConfig Show-Markdown " +
"Start-CIVApp Start-CIVM Start-HCXMigration Start-HCXReplication Start-SpbmReplicationFailover Start-SpbmReplicationPrepareFailover Start-SpbmReplicationPromote " +
"Start-SpbmReplicationReverse Start-SpbmReplicationTestFailover Start-ThreadJob Start-VApp Start-VM Start-VMHost Start-VMHostService Start-VsanClusterDiskUpdate " +
"Start-VsanClusterRebalance Start-VsanEncryptionConfiguration Stop-CIVApp Stop-CIVAppGuest Stop-CIVM Stop-CIVMGuest Stop-SpbmReplicationTestFailover Stop-Task Stop-VApp Stop-VM " +
"Stop-VMGuest Stop-VMHost Stop-VMHostService Stop-VsanClusterRebalance Suspend-CIVApp Suspend-CIVM Suspend-HCXReplication Suspend-VM Suspend-VMGuest Suspend-VMHost " +
"Sync-SpbmReplicationGroup Test-ConflictingResources Test-HCXMigration Test-HCXReplication Test-Json Test-ModuleReloadRequired Test-MofInstanceText Test-NodeManager " +
"Test-NodeResourceSource Test-NodeResources Test-ScriptFileInfo Test-VMHostProfileCompliance Test-VMHostSnmp Test-VsanClusterHealth Test-VsanNetworkPerformance " +
"Test-VsanStoragePerformance Test-VsanVMCreation Test-vRAPackage Uninstall-Module Uninstall-Package Uninstall-Script Unlock-VM Unregister-PSRepository Unregister-PackageSource " +
"Update-ConfigurationDocumentRef Update-ConfigurationErrorCount Update-DependsOn Update-LocalConfigManager Update-Module Update-ModuleManifest Update-ModuleVersion Update-PowerNsx " +
"Update-Script Update-ScriptFileInfo Update-Tools Update-VsanHclDatabase ValidateUpdate-ConfigurationData Wait-Debugger Wait-NsxControllerJob Wait-NsxGenericJob Wait-NsxJob " +
"Wait-Task Wait-Tools Write-Information Write-Log Write-MetaConfigFile Write-NodeMOFFile",
nomarkup:
"-ne -eq -lt -gt -ge -le -not -like -notlike -match -notmatch -contains -notcontains -in -notin -replace",
},
contains: [
BACKTICK_ESCAPE,
hljs.NUMBER_MODE,
QUOTE_STRING,
APOS_STRING,
LITERAL,
VAR,
PS_COMMENT,
],
keywords: KEYWORDS,
contains: GENTLEMANS_SET.concat(
PS_CLASS,
PS_FUNCTION,
PS_USING,
PS_ARGUMENTS,
PS_TYPE
)
};
};

@@ -93,2 +93,5 @@ module.exports = function(hljs) {

NUMBER,
// eat "if" prior to string so that it won't accidentally be
// labeled as an f-string as in:
{ beginKeywords: "if", relevance: 0 },
STRING,

@@ -95,0 +98,0 @@ hljs.HASH_COMMENT_MODE,

module.exports = function(hljs) {
var AT_IDENTIFIER = '@[a-z-]+' // @font-face
var AT_MODIFIERS = "and or not only"
var IDENT_RE = '[a-zA-Z-][a-zA-Z0-9_-]*';

@@ -53,5 +55,7 @@ var VARIABLE = {

{
className: 'selector-pseudo',
begin: ':(visited|valid|root|right|required|read-write|read-only|out-range|optional|only-of-type|only-child|nth-of-type|nth-last-of-type|nth-last-child|nth-child|not|link|left|last-of-type|last-child|lang|invalid|indeterminate|in-range|hover|focus|first-of-type|first-line|first-letter|first-child|first|enabled|empty|disabled|default|checked|before|after|active)'
},
{
className: 'selector-pseudo',
begin: '::(after|before|choices|first-letter|first-line|repeat-index|repeat-item|selection|value)'

@@ -62,3 +66,3 @@ },

className: 'attribute',
begin: '\\b(z-index|word-wrap|word-spacing|word-break|width|widows|white-space|visibility|vertical-align|unicode-bidi|transition-timing-function|transition-property|transition-duration|transition-delay|transition|transform-style|transform-origin|transform|top|text-underline-position|text-transform|text-shadow|text-rendering|text-overflow|text-indent|text-decoration-style|text-decoration-line|text-decoration-color|text-decoration|text-align-last|text-align|tab-size|table-layout|right|resize|quotes|position|pointer-events|perspective-origin|perspective|page-break-inside|page-break-before|page-break-after|padding-top|padding-right|padding-left|padding-bottom|padding|overflow-y|overflow-x|overflow-wrap|overflow|outline-width|outline-style|outline-offset|outline-color|outline|orphans|order|opacity|object-position|object-fit|normal|none|nav-up|nav-right|nav-left|nav-index|nav-down|min-width|min-height|max-width|max-height|mask|marks|margin-top|margin-right|margin-left|margin-bottom|margin|list-style-type|list-style-position|list-style-image|list-style|line-height|letter-spacing|left|justify-content|initial|inherit|ime-mode|image-orientation|image-resolution|image-rendering|icon|hyphens|height|font-weight|font-variant-ligatures|font-variant|font-style|font-stretch|font-size-adjust|font-size|font-language-override|font-kerning|font-feature-settings|font-family|font|float|flex-wrap|flex-shrink|flex-grow|flex-flow|flex-direction|flex-basis|flex|filter|empty-cells|display|direction|cursor|counter-reset|counter-increment|content|column-width|column-span|column-rule-width|column-rule-style|column-rule-color|column-rule|column-gap|column-fill|column-count|columns|color|clip-path|clip|clear|caption-side|break-inside|break-before|break-after|box-sizing|box-shadow|box-decoration-break|bottom|border-width|border-top-width|border-top-style|border-top-right-radius|border-top-left-radius|border-top-color|border-top|border-style|border-spacing|border-right-width|border-right-style|border-right-color|border-right|border-radius|border-left-width|border-left-style|border-left-color|border-left|border-image-width|border-image-source|border-image-slice|border-image-repeat|border-image-outset|border-image|border-color|border-collapse|border-bottom-width|border-bottom-style|border-bottom-right-radius|border-bottom-left-radius|border-bottom-color|border-bottom|border|background-size|background-repeat|background-position|background-origin|background-image|background-color|background-clip|background-attachment|background-blend-mode|background|backface-visibility|auto|animation-timing-function|animation-play-state|animation-name|animation-iteration-count|animation-fill-mode|animation-duration|animation-direction|animation-delay|animation|align-self|align-items|align-content)\\b',
begin: '\\b(src|z-index|word-wrap|word-spacing|word-break|width|widows|white-space|visibility|vertical-align|unicode-bidi|transition-timing-function|transition-property|transition-duration|transition-delay|transition|transform-style|transform-origin|transform|top|text-underline-position|text-transform|text-shadow|text-rendering|text-overflow|text-indent|text-decoration-style|text-decoration-line|text-decoration-color|text-decoration|text-align-last|text-align|tab-size|table-layout|right|resize|quotes|position|pointer-events|perspective-origin|perspective|page-break-inside|page-break-before|page-break-after|padding-top|padding-right|padding-left|padding-bottom|padding|overflow-y|overflow-x|overflow-wrap|overflow|outline-width|outline-style|outline-offset|outline-color|outline|orphans|order|opacity|object-position|object-fit|normal|none|nav-up|nav-right|nav-left|nav-index|nav-down|min-width|min-height|max-width|max-height|mask|marks|margin-top|margin-right|margin-left|margin-bottom|margin|list-style-type|list-style-position|list-style-image|list-style|line-height|letter-spacing|left|justify-content|initial|inherit|ime-mode|image-orientation|image-resolution|image-rendering|icon|hyphens|height|font-weight|font-variant-ligatures|font-variant|font-style|font-stretch|font-size-adjust|font-size|font-language-override|font-kerning|font-feature-settings|font-family|font|float|flex-wrap|flex-shrink|flex-grow|flex-flow|flex-direction|flex-basis|flex|filter|empty-cells|display|direction|cursor|counter-reset|counter-increment|content|column-width|column-span|column-rule-width|column-rule-style|column-rule-color|column-rule|column-gap|column-fill|column-count|columns|color|clip-path|clip|clear|caption-side|break-inside|break-before|break-after|box-sizing|box-shadow|box-decoration-break|bottom|border-width|border-top-width|border-top-style|border-top-right-radius|border-top-left-radius|border-top-color|border-top|border-style|border-spacing|border-right-width|border-right-style|border-right-color|border-right|border-radius|border-left-width|border-left-style|border-left-color|border-left|border-image-width|border-image-source|border-image-slice|border-image-repeat|border-image-outset|border-image|border-color|border-collapse|border-bottom-width|border-bottom-style|border-bottom-right-radius|border-bottom-left-radius|border-bottom-color|border-bottom|border|background-size|background-repeat|background-position|background-origin|background-image|background-color|background-clip|background-attachment|background-blend-mode|background|backface-visibility|auto|animation-timing-function|animation-play-state|animation-name|animation-iteration-count|animation-fill-mode|animation-duration|animation-direction|animation-delay|animation|align-self|align-items|align-content)\\b',
illegal: '[^\\s]'

@@ -82,6 +86,19 @@ },

},
// matching these here allows us to treat them more like regular CSS
// rules so everything between the {} gets regular rule highlighting,
// which is what we want for page and font-face
{
begin: '@(page|font-face)',
lexemes: AT_IDENTIFIER,
keywords: '@page @font-face'
},
{
begin: '@', end: '[{;]',
keywords: 'mixin include extend for if else each while charset import debug media page content font-face namespace warn',
returnBegin: true,
keywords: AT_MODIFIERS,
contains: [
{
begin: AT_IDENTIFIER,
className: "keyword"
},
VARIABLE,

@@ -92,6 +109,6 @@ hljs.QUOTE_STRING_MODE,

hljs.CSS_NUMBER_MODE,
{
begin: '\\s[A-Za-z0-9_.-]+',
relevance: 0
}
// {
// begin: '\\s[A-Za-z0-9_.-]+',
// relevance: 0
// }
]

@@ -98,0 +115,0 @@ }

@@ -138,3 +138,3 @@ module.exports = function(hljs) {

begin: '\'', end: '\'',
contains: [hljs.BACKSLASH_ESCAPE, {begin: '\'\''}]
contains: [{begin: '\'\''}]
},

@@ -144,8 +144,7 @@ {

begin: '"', end: '"',
contains: [hljs.BACKSLASH_ESCAPE, {begin: '""'}]
contains: [{begin: '""'}]
},
{
className: 'string',
begin: '`', end: '`',
contains: [hljs.BACKSLASH_ESCAPE]
begin: '`', end: '`'
},

@@ -152,0 +151,0 @@ hljs.C_NUMBER_MODE,

module.exports = function(hljs) {
var XML_IDENT_RE = '[A-Za-z0-9\\._:-]+';
var XML_ENTITIES = {
className: 'symbol',
begin: '&[a-z]+;|&#[0-9]+;|&#x[a-f0-9]+;'
};
var XML_META_KEYWORDS = {
begin: '\\s',
contains:[
{
className: 'meta-keyword',
begin: '#?[a-z_][a-z1-9_-]+',
illegal: '\\n',
}
]
};
var XML_META_PAR_KEYWORDS = hljs.inherit(XML_META_KEYWORDS, {begin: '\\(', end: '\\)'});
var APOS_META_STRING_MODE = hljs.inherit(hljs.APOS_STRING_MODE, {className: 'meta-string'});
var QUOTE_META_STRING_MODE = hljs.inherit(hljs.QUOTE_STRING_MODE, {className: 'meta-string'});
var TAG_INTERNALS = {

@@ -21,4 +38,4 @@ endsWithParent: true,

variants: [
{begin: /"/, end: /"/},
{begin: /'/, end: /'/},
{begin: /"/, end: /"/, contains: [XML_ENTITIES]},
{begin: /'/, end: /'/, contains: [XML_ENTITIES]},
{begin: /[^\s"'=<>`]+/}

@@ -37,5 +54,25 @@ ]

className: 'meta',
begin: '<!DOCTYPE', end: '>',
begin: '<![a-z]', end: '>',
relevance: 10,
contains: [{begin: '\\[', end: '\\]'}]
contains: [
XML_META_KEYWORDS,
QUOTE_META_STRING_MODE,
APOS_META_STRING_MODE,
XML_META_PAR_KEYWORDS,
{
begin: '\\[', end: '\\]',
contains:[
{
className: 'meta',
begin: '<![a-z]', end: '>',
contains: [
XML_META_KEYWORDS,
XML_META_PAR_KEYWORDS,
QUOTE_META_STRING_MODE,
APOS_META_STRING_MODE
]
}
]
}
]
},

@@ -53,2 +90,3 @@ hljs.COMMENT(

},
XML_ENTITIES,
{

@@ -55,0 +93,0 @@ className: 'meta',

@@ -9,3 +9,3 @@ {

"homepage": "https://highlightjs.org/",
"version": "9.16.2",
"version": "9.17.0",
"author": {

@@ -37,2 +37,6 @@ "name": "Ivan Sagalaev",

{
"name": "Josh Goebel",
"email": "hello@joshgoebel.com"
},
{
"name": "Ivan Sagalaev (original author)",

@@ -1096,2 +1100,10 @@ "email": "maniac@softwaremaniacs.org"

"email": "tom.p.reichel@gmail.com"
},
{
"name": "G8t Guy",
"email": "g8tguy@g8tguy.com"
},
{
"name": "Samia Ali",
"email": "samiaab1990@gmail.com"
}

@@ -1117,6 +1129,6 @@ ],

"devDependencies": {
"bluebird": "^3.5.5",
"cli-table": "^0.3.1",
"colors": "^1.1.2",
"bluebird": "^3.5.5",
"commander": "^3.0.1",
"commander": "^4.0.0",
"del": "^5.1.0",

@@ -1130,5 +1142,10 @@ "gear": "github:highlightjs/gear",

"mocha": "^6.2.0",
"rollup": "^1.27.8",
"rollup-plugin-commonjs": "^10.1.0",
"should": "^13.2.3",
"tiny-worker": "^2.3.0"
},
"dependencies": {
"handlebars": "^4.5.3"
}
}

@@ -30,4 +30,29 @@ # Highlight.js

Classes may also be prefixed with either `language-` or `lang-`.
```html
<pre><code class="language-html">...</code></pre>
```
### Plaintext and Disabling Highlighting
To style arbitrary text like code, but without any highlighting, use the
`plaintext` class:
```html
<pre><code class="plaintext">...</code></pre>
```
To disable highlighting of a tag completely, use the `nohighlight` class:
```html
<pre><code class="nohighlight">...</code></pre>
```
### Supported Languages
The table below shows the full list of supported languages (and corresponding classes) that are bundled with the library. Note: Which languages are available may depend on how you've built or included the library in your app. See [Getting the Library](#getting-the-library) below.
<details>
<summary>The list of supported languages and corresponding classes.</summary>
<summary>Reveal the full list of languages...</summary>

@@ -218,17 +243,3 @@ | Language | Classes | Package |

Classes can also be prefixed with either `language-` or `lang-`.
To make arbitrary text look like code, but without highlighting, use the
`plaintext` class:
```html
<pre><code class="plaintext">...</code></pre>
```
To disable highlighting altogether use the `nohighlight` class:
```html
<pre><code class="nohighlight">...</code></pre>
```
## Custom Initialization

@@ -235,0 +246,0 @@

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc