<commit_before>" read the mailboxes list

let s:messagebufnr = -1

function! s:CreateWindowA()
  setlocal bufhidden=delete
  setlocal buftype=nofile
  setlocal nomodifiable
  setlocal noswapfile
  setlocal nowrap
  setlocal nonumber
  setlocal foldcolumn=0
  setlocal nospell
  setlocal nobuflisted
  setlocal textwidth=0
  setlocal noreadonly
  setlocal cursorline
  let s:mailboxesbufnr = bufnr('%')
  let s:dataDir = expand('%:h')
endfunction

call s:CreateWindowA()
let s:currentBox = getline('.')

function! s:CreateWindowB()
  split List
  setlocal bufhidden=delete
  setlocal buftype=nofile
  " setlocal nomodifiable
  setlocal noswapfile
  setlocal nowrap
  setlocal nonumber
  setlocal foldcolumn=0
  setlocal nospell
  setlocal nobuflisted
  setlocal textwidth=0
  setlocal noreadonly
  " hi CursorLine cterm=NONE ctermbg=darkred ctermfg=white guibg=darkred guifg=white 
  setlocal cursorline
  let s:listbufnr = bufnr('%')
endfunction

" the message display buffer window
function! s:CreateWindowC() 
  bot vne Message
  setlocal buftype=nofile
  setlocal noswapfile
  let s:messagebufnr = bufnr('%')
endfunction

call s:CreateWindowC()
call s:CreateWindowB()

" switch to WindowA
1 wincmd w
vertical resize 20
2 wincmd w

function! s:ListMessages()
  " load mailbox TOC
  1 wincmd w
  let s:currentMailboxDir = s:dataDir . "/" . getline(".") 
  let s:currentMailboxToc = s:currentMailboxDir . "/" . "TOC"
  2 wincmd w  " window 2 is the List
  1,$delete

  let l:res = system("mysql -uroot gmail_development -e 'select subject from messages'") 
  put =res
  

  1delete
  normal G
  1 wincmd w
endfunction

1 wincmd w<commit_msg>showing mailboxes in a crude way<commit_after>" read the mailboxes list

let s:messagebufnr = -1

function! s:CreateWindowA()
  let l:res = system("mysql -uroot gmail_development -e 'select label from mailboxes'") 
  put =res
  setlocal bufhidden=delete
  setlocal buftype=nofile
  setlocal nomodifiable
  setlocal noswapfile
  setlocal nowrap
  setlocal nonumber
  setlocal foldcolumn=0
  setlocal nospell
  setlocal nobuflisted
  setlocal textwidth=0
  setlocal noreadonly
  setlocal cursorline
  let s:mailboxesbufnr = bufnr('%')
  let s:dataDir = expand('%:h')
endfunction

call s:CreateWindowA()
let s:currentBox = getline('.')

function! s:CreateWindowB()
  split List
  setlocal bufhidden=delete
  setlocal buftype=nofile
  " setlocal nomodifiable
  setlocal noswapfile
  setlocal nowrap
  setlocal nonumber
  setlocal foldcolumn=0
  setlocal nospell
  setlocal nobuflisted
  setlocal textwidth=0
  setlocal noreadonly
  " hi CursorLine cterm=NONE ctermbg=darkred ctermfg=white guibg=darkred guifg=white 
  setlocal cursorline
  let s:listbufnr = bufnr('%')
endfunction

" the message display buffer window
function! s:CreateWindowC() 
  bot vne Message
  setlocal buftype=nofile
  setlocal noswapfile
  let s:messagebufnr = bufnr('%')
endfunction

call s:CreateWindowC()
call s:CreateWindowB()

" switch to WindowA
1 wincmd w
vertical resize 20
2 wincmd w

function! s:ListMessages()
  " load mailbox TOC
  1 wincmd w
  let s:currentMailboxDir = s:dataDir . "/" . getline(".") 
  let s:currentMailboxToc = s:currentMailboxDir . "/" . "TOC"
  2 wincmd w  " window 2 is the List
  1,$delete

  let l:res = system("mysql -uroot gmail_development -e 'select subject from messages'") 
  put =res

  1delete
  normal G
  1 wincmd w
endfunction

1 wincmd w
{'fraction_non_alphanumeric': 0.07622130665097115, 'fraction_numerical': 0.009417304296645085, 'mean_word_length': 4.386687797147385, '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': '7601704', 'n_tokens_mistral': 1231, 'n_tokens_neox': 1201, 'n_words': 348}