As a Vim lover and user, I decided to clean my vimrc a bit this week creating my own statusline and dropping the excellent vim-airline. As I frequently commute by train and I normally use Vim in fullscreen mode, I decided to tweak my statusline to show both the clock and the battery level.
I manily got inspired by Build your own Vim statusline by George Ornbo, but I added a new feature by Vim 8: timer_start(), which allows to call a function after a specified time interval.
Here’s the code to throw into your .vimrc:
And here’s the result: