<commit_before>var prefix = 'SIG';
var names = [
  "HUP",
  "INT",
  "QUIT",
  "ILL",
  "TRAP",
  "ABRT",
  "EMT",
  "FPE",
  "KILL",
  "BUS",
  "SEGV",
  "SYS",
  "PIPE",
  "ALRM",
  "TERM",
  "URG",
  "STOP",
  "TSTP",
  "CONT",
  "CHLD",
  "TTIN",
  "TTOU",
  "IO",
  "XCPU",
  "XFSZ",
  "VTALRM",
  "PROF",
  "WINCH",
  "INFO",
  "USR1",
  "USR2"
];

module.exports = {
  prefix: prefix,
  names: names,
}<commit_msg>Add common signal number lookup to signals.<commit_after>var prefix = 'SIG';
var names = [
  "HUP",
  "INT",
  "QUIT",
  "ILL",
  "TRAP",
  "ABRT",
  "EMT",
  "FPE",
  "KILL",
  "BUS",
  "SEGV",
  "SYS",
  "PIPE",
  "ALRM",
  "TERM",
  "URG",
  "STOP",
  "TSTP",
  "CONT",
  "CHLD",
  "TTIN",
  "TTOU",
  "IO",
  "XCPU",
  "XFSZ",
  "VTALRM",
  "PROF",
  "WINCH",
  "INFO",
  "USR1",
  "USR2"
];

var map = {};
names.forEach(function each(name) {
  map[name.toLowerCase()] = name;
})

// map some common signal numbers to names
// man 2 kill (Darwin 10.8)
var numbers = {};
numbers[1] = map.hup;
numbers[2] = map.int;
numbers[3] = map.quit;
numbers[6] = map.abrt;
numbers[9] = map.kill;
numbers[14] = map.alrm;
numbers[15] = map.term;

module.exports = {
  map: map,
  prefix: prefix,
  names: names,
  default: prefix + map.term,
  numbers: numbers,
}
{'fraction_non_alphanumeric': 0.2317360565593087, 'fraction_numerical': 0.01335428122545169, 'mean_word_length': 2.9688473520249223, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '3460703', 'n_tokens_mistral': 627, 'n_tokens_neox': 610, 'n_words': 129}