<commit_before>'use babel'

import { Point, Range } from 'atom'
import * as _ from 'lodash'
const linterName = 'Spelling'
const asciiDocLangPattern = /^:lang:\s*(\S+)/m

export function provideIntentions () {
  return {
    grammarScopes: ['*'],
    getIntentions: ({textEditor, bufferPosition}) => {
      if (global.linter) {
        const editorLinter = global.linter.getEditorLinter(textEditor)
        if (editorLinter) {
          for (const message of editorLinter.getMessages()) {
            if (message.linter === linterName && message.range && message.range.containsPoint(bufferPosition)) {
              return message.intentions
            }
          }
        }
      }
      return []
    }
  }
}

export function provideGrammar () {
  return [{
    grammarScopes: [
      'text.plain',
      'text.plain.null-grammar']
  }, {
    grammarScopes: [
      'text.git-commit'
    ],
    checkedScopes: {
      '.meta.scope.message.git-commit': true
    }
  }, {
    grammarScopes: [
      'source.asciidoc'
    ],
    findLanguageTags: textEditor => {
      let languages = []
      textEditor.scan(asciiDocLangPattern, ({match, stop}) => {
        languages.push(match[1])
        stop()
      })
      return languages
    },
    checkedScopes: {
      'entity.name.function.asciidoc': false,
      'entity.name.tag.yaml': false,
      'markup.blockid.asciidoc': false,
      'markup.code.asciidoc.properties.asciidoc': false,<commit_msg>Add ignores for language-todo<commit_after>'use babel'

import { Point, Range } from 'atom'
import * as _ from 'lodash'
const linterName = 'Spelling'
const asciiDocLangPattern = /^:lang:\s*(\S+)/m

export function provideIntentions () {
  return {
    grammarScopes: ['*'],
    getIntentions: ({textEditor, bufferPosition}) => {
      if (global.linter) {
        const editorLinter = global.linter.getEditorLinter(textEditor)
        if (editorLinter) {
          for (const message of editorLinter.getMessages()) {
            if (message.linter === linterName && message.range && message.range.containsPoint(bufferPosition)) {
              return message.intentions
            }
          }
        }
      }
      return []
    }
  }
}

export function provideGrammar () {
  return [{
    grammarScopes: [
      'text.plain',
      'text.plain.null-grammar'
    ],
    checkedScopes: {
      'text.plain': true,
      'text.plain.null-grammar': true,
      'storage.type.class.todo': false, // ignore from language-todo
      'storage.type.class.fixme': false,
      'storage.type.class.changed': false,
      'storage.type.class.xxx': false,
      'storage.type.class.idea': false,
      'storage.type.class.hack': false,
      'storage.type.class.note': false,
      'storage.type.class.review': false,
      'storage.type.class.nb': false,
      'storage.type.class.bug': false,
      'storage.type.class.radar': false
    }
  }, {
    grammarScopes: [
      'text.git-commit'
    ],
    checkedScopes: {
      '.meta.scope.message.git-commit': true
    }
  }, {
    grammarScopes: [
      'source.asciidoc'
    ],
    findLanguageTags: textEditor => {
      let languages = []
      textEditor.scan(asciiDocLangPattern, ({match, stop}) => {
        languages.push(match[1])
        stop()
      })
      return languages
    },
    checkedScopes: {
      'entity.name.function.asciidoc': false,
      'entity.name.tag.yaml': false,
      'markup.blockid.asciidoc': false,
      'markup.code.asciidoc.properties.asciidoc': false,
{'fraction_non_alphanumeric': 0.1420796333428817, 'fraction_numerical': 0.0005729017473503294, 'mean_word_length': 2.4134897360703813, 'pattern_counts': {'":': 0, '<': 3, '<?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': '757865', 'n_tokens_mistral': 1117, 'n_tokens_neox': 1132, 'n_words': 190}