<commit_before>if exists(':CompilerSet') != 2
  command -nargs=* CompilerSet setlocal <args>
endif

let s:lint='yarn\ run\ tsc\ --noEmit'

execute 'CompilerSet makeprg=' . s:lint

CompilerSet errorformat=
      \%E%f:%l:%c%\\s%\\+-%\\s%\\+%trror%\\s%\\+TS%n:%\\s%\\+%m,
      \%-G%[%^\ 0-9]%.%#

finish " Sample output follows:
yarn run v1.17.3
$ tsc --noEmit
src/renderer/hooks/usePrevious.ts:24:5 - error TS2322: Type 'T' is not assignable to type 'undefined'.

24     ref.current = value;
       ~~~~~~~~~~~

src/renderer/index.tsx:11:14 - error TS2552: Cannot find name 'doscument'. Did you mean 'Document'?

11 const root = doscument.getElementById('root');
                ~~~~~~~~~

  node_modules/typescript/lib/lib.dom.d.ts:4952:13
    4952 declare var Document: {
                     ~~~~~~~~
    'Document' is declared here.

src/renderer/store/__tests__/filterNotes-test.ts:35:24 - error TS2345: Argument of type 'null' is not assignable to parameter of type 'string | undefined'.<commit_msg>feat(vim): trim blank lines from tsc errorformat output<commit_after>if exists(':CompilerSet') != 2
  command -nargs=* CompilerSet setlocal <args>
endif

let s:lint='yarn\ run\ tsc\ --noEmit'

execute 'CompilerSet makeprg=' . s:lint

CompilerSet errorformat=
      \%E%f:%l:%c%\\s%\\+-%\\s%\\+%trror%\\s%\\+TS%n:%\\s%\\+%m,
      \%-G%[%^\ 0-9]%.%#,
      \%-G%\\s%#

finish " Sample output follows:
yarn run v1.17.3
$ tsc --noEmit
src/renderer/hooks/usePrevious.ts:24:5 - error TS2322: Type 'T' is not assignable to type 'undefined'.

24     ref.current = value;
       ~~~~~~~~~~~

src/renderer/index.tsx:11:14 - error TS2552: Cannot find name 'doscument'. Did you mean 'Document'?

11 const root = doscument.getElementById('root');
                ~~~~~~~~~

  node_modules/typescript/lib/lib.dom.d.ts:4952:13
    4952 declare var Document: {
                     ~~~~~~~~
    'Document' is declared here.

src/renderer/store/__tests__/filterNotes-test.ts:35:24 - error TS2345: Argument of type 'null' is not assignable to parameter of type 'string | undefined'.
{'fraction_non_alphanumeric': 0.18454106280193236, 'fraction_numerical': 0.04251207729468599, 'mean_word_length': 3.1172962226640157, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, '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': '7052146', 'n_tokens_mistral': 790, 'n_tokens_neox': 736, 'n_words': 181}