<commit_before>// brush: "bash-script" aliases: []

//	This file is part of the "jQuery.Syntax" project, and is licensed under the GNU AGPLv3.
//	Copyright 2010 <NAME>. All rights reserved.
//	See <jquery.syntax.js> for licensing details.

Syntax.register('bash-script', function(brush) {
	var keywords = ["break", "case", "continue", "do", "done", "elif", "else", "eq", "fi", "for", "function", "ge", "gt", "if", "in", "le", "lt", "ne", "return", "then", "until", "while"];
	
	brush.push(keywords, {klass: 'keyword'});
	
	var operators = ["&", "|", ">", "<", "=", "`", "--"];
	brush.push(operators, {klass: 'operator'});
	
	brush.push({
		pattern: /^\s*((?:\S+=\S+\s+)*)\s*(\S+)((?:\s+.*?)?)$/gmi,
		matches: Syntax.extractMatches(
			{klass: 'env'},
			{klass: 'function'},
			{klass: 'remainder', allow: '*'}
		)
	});
	
	brush.push({
		pattern: /(?:\||&&)\s+(\S+)/g,
		matches: Syntax.extractMatches(
			{klass: 'function', only: ['remainder']}
		)
	});
	
	brush.push({
		pattern: /\$\w+/g,
		klass: 'variable'
	})
	
	brush.push({pattern: /\s\-+\w+/g, klass: 'option'})

	brush.push(Syntax.lib.perlStyleComment);
	brush.push(jQuery.extend({}, Syntax.lib.singleQuotedString, {allow: '*'}));
	brush.push(jQuery.extend({}, Syntax.lib.doubleQuotedString, {allow: '*'}));

	brush.push(Syntax.lib.webLink);
});
<commit_msg>Highlight sudo and the following command.<commit_after>// brush: "bash-script" aliases: []

//	This file is part of the "jQuery.Syntax" project, and is licensed under the GNU AGPLv3.
//	Copyright 2010 <NAME>. All rights reserved.
//	See <jquery.syntax.js> for licensing details.

Syntax.register('bash-script', function(brush) {
	var keywords = ["break", "case", "continue", "do", "done", "elif", "else", "eq", "fi", "for", "function", "ge", "gt", "if", "in", "le", "lt", "ne", "return", "then", "until", "while"];
	
	brush.push(keywords, {klass: 'keyword'});
	
	var operators = ["&", "|", ">", "<", "=", "`", "--"];
	brush.push(operators, {klass: 'operator'});
	
	brush.push({
		pattern: /^\s*((?:\S+=\S+\s+)*)\s*((?:sudo\s+)?\S+)((?:\s+.*?)?)$/gmi,
		matches: Syntax.extractMatches(
			{klass: 'env'},
			{klass: 'function'},
			{klass: 'remainder', allow: '*'}
		)
	});
	
	brush.push({
		pattern: /(?:\||&&)\s+(\S+)/g,
		matches: Syntax.extractMatches(
			{klass: 'function', only: ['remainder']}
		)
	});
	
	brush.push({
		pattern: /\$\w+/g,
		klass: 'variable'
	})
	
	brush.push({pattern: /\s\-+\w+/g, klass: 'option'})

	brush.push(Syntax.lib.perlStyleComment);
	brush.push(jQuery.extend({}, Syntax.lib.singleQuotedString, {allow: '*'}));
	brush.push(jQuery.extend({}, Syntax.lib.doubleQuotedString, {allow: '*'}));

	brush.push(Syntax.lib.webLink);
});

{'fraction_non_alphanumeric': 0.27238805970149255, 'fraction_numerical': 0.0037313432835820895, 'mean_word_length': 4.256862745098039, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1874492', 'n_tokens_mistral': 1124, 'n_tokens_neox': 1019, 'n_words': 209}