2014-08-03 07:16:30 +02:00
|
|
|
|
#!/usr/bin/vim -S
|
2014-08-27 21:42:04 +02:00
|
|
|
|
set encoding=utf-8
|
2014-09-05 20:13:51 +02:00
|
|
|
|
let g:powerline_config_paths = [expand('<sfile>:p:h:h') . '/powerline/config_files']
|
2014-08-03 07:16:30 +02:00
|
|
|
|
source powerline/bindings/vim/plugin/powerline.vim
|
|
|
|
|
edit abc
|
|
|
|
|
tabedit def
|
|
|
|
|
tabedit ghi
|
2014-08-03 10:49:18 +02:00
|
|
|
|
|
2014-09-04 06:32:36 +02:00
|
|
|
|
redir => g:messages
|
|
|
|
|
|
2014-08-03 07:16:30 +02:00
|
|
|
|
try
|
|
|
|
|
let &columns = 80
|
|
|
|
|
let result = eval(&tabline[2:])
|
|
|
|
|
catch
|
|
|
|
|
call writefile(['Exception while evaluating &tabline', v:exception], 'message.fail')
|
|
|
|
|
cquit
|
|
|
|
|
endtry
|
|
|
|
|
|
2014-09-05 17:36:31 +02:00
|
|
|
|
if result isnot# '%#Pl_247_10395294_236_3158064_NONE# 1 ./abc 2 ./def %#Pl_236_3158064_240_5789784_NONE# %#Pl_250_12369084_240_5789784_NONE#3 ./%#Pl_231_16777215_240_5789784_bold#ghi %#Pl_240_5789784_236_3158064_NONE# %#Pl_231_16777215_236_3158064_NONE# %#Pl_252_13684944_236_3158064_NONE# %#Pl_235_2500134_252_13684944_bold# Tabs '
|
2014-08-05 23:33:37 +02:00
|
|
|
|
call writefile(['Unexpected tabline', result], 'message.fail')
|
2014-08-03 07:16:30 +02:00
|
|
|
|
cquit
|
|
|
|
|
endif
|
2014-08-03 10:49:18 +02:00
|
|
|
|
|
|
|
|
|
tabonly!
|
|
|
|
|
|
|
|
|
|
try
|
|
|
|
|
let result = eval(&tabline[2:])
|
|
|
|
|
catch
|
2014-08-29 16:32:58 +02:00
|
|
|
|
call writefile(['Exception while evaluating &tabline (2)', v:exception], 'message.fail')
|
2014-08-03 10:49:18 +02:00
|
|
|
|
cquit
|
|
|
|
|
endtry
|
|
|
|
|
|
2014-09-05 17:36:31 +02:00
|
|
|
|
if result isnot# '%#Pl_247_10395294_236_3158064_NONE# 1 ./abc 2 ./def %#Pl_236_3158064_240_5789784_NONE# %#Pl_250_12369084_240_5789784_NONE#3 ./%#Pl_231_16777215_240_5789784_bold#ghi %#Pl_240_5789784_236_3158064_NONE# %#Pl_231_16777215_236_3158064_NONE# %#Pl_252_13684944_236_3158064_NONE# %#Pl_235_2500134_252_13684944_bold# Bufs '
|
2014-08-05 23:33:37 +02:00
|
|
|
|
call writefile(['Unexpected tabline (2)', result], 'message.fail')
|
2014-08-03 10:49:18 +02:00
|
|
|
|
cquit
|
|
|
|
|
endif
|
|
|
|
|
|
2014-08-29 16:32:58 +02:00
|
|
|
|
try
|
|
|
|
|
vsplit
|
|
|
|
|
let result = eval(&tabline[2:])
|
|
|
|
|
catch
|
|
|
|
|
call writefile(['Exception while evaluating &tabline (3)', v:exception], 'message.fail')
|
|
|
|
|
endtry
|
|
|
|
|
|
2014-09-05 17:36:31 +02:00
|
|
|
|
if result isnot# '%#Pl_247_10395294_236_3158064_NONE# 1 ./abc 2 ./def %#Pl_236_3158064_240_5789784_NONE# %#Pl_250_12369084_240_5789784_NONE#3 ./%#Pl_231_16777215_240_5789784_bold#ghi %#Pl_240_5789784_236_3158064_NONE# %#Pl_231_16777215_236_3158064_NONE# %#Pl_252_13684944_236_3158064_NONE# %#Pl_235_2500134_252_13684944_bold# Bufs '
|
2014-08-29 16:32:58 +02:00
|
|
|
|
call writefile(['Unexpected tabline (3)', result], 'message.fail')
|
|
|
|
|
cquit
|
|
|
|
|
endif
|
|
|
|
|
|
2014-09-04 06:32:36 +02:00
|
|
|
|
redir END
|
|
|
|
|
if g:messages =~ '\S'
|
|
|
|
|
call writefile(['Non-empty messages:', g:messages], 'message.fail')
|
|
|
|
|
cquit
|
|
|
|
|
endif
|
|
|
|
|
|
2014-08-03 07:16:30 +02:00
|
|
|
|
qall!
|