<commit_before>" MIT License. Copyright (c) 2013-2019 <NAME> et al.
" vim: et ts=2 sts=2 sw=2

scriptencoding utf-8

function! airline#extensions#term#apply(...)
  if &buftype == 'terminal'
    let spc = g:airline_symbols.space

    let name=get(g:airline_mode_map, 't', 't')
    call a:1.add_section('airline_a', spc.name.spc)
    call a:1.add_section('airline_b', '')
    call a:1.add_section('airline_term', spc.s:termname())
    call a:1.split()
    call a:1.add_section('airline_y', '')
    call a:1.add_section('airline_z', spc.airline#section#create_right(['linenr', 'maxlinenr']))
    return 1
  endif<commit_msg>term: Make terminal extension work on entering it<commit_after>" MIT License. Copyright (c) 2013-2019 <NAME> al.
" vim: et ts=2 sts=2 sw=2

scriptencoding utf-8

function! airline#extensions#term#apply(...)
  if &buftype == 'terminal' || bufname('%')[0] == '!'
    let spc = g:airline_symbols.space

    let name=get(g:airline_mode_map, 't', 't')
    call a:1.add_section('airline_a', spc.name.spc)
    call a:1.add_section('airline_b', '')
    call a:1.add_section('airline_term', spc.s:termname())
    call a:1.split()
    call a:1.add_section('airline_y', '')
    call a:1.add_section('airline_z', spc.airline#section#create_right(['linenr', 'maxlinenr']))
    return 1
  endif
{'fraction_non_alphanumeric': 0.17294388931591084, 'fraction_numerical': 0.02997694081475788, 'mean_word_length': 4.540425531914893, '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': '7231577', 'n_tokens_mistral': 532, 'n_tokens_neox': 505, 'n_words': 100}