Skip to content

Commit 98d0fa5

Browse files
committed
Remove airline dependency and create custom statusline
1 parent 5775ec4 commit 98d0fa5

14 files changed

+360
-32
lines changed

.Xresources

+79
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,79 @@
1+
Xft.dpi: 96
2+
Xft.antialias: true
3+
Xft.hinting: true
4+
Xft.rgba: rgb
5+
Xft.autohint: false
6+
Xft.hintstyle: hintslight
7+
Xft.lcdfilter: lcddefault
8+
9+
! URXVT Configuration
10+
11+
URxvt*scrollTtyOutput: false
12+
URxvt*scrollWithBuffer: true
13+
URxvt*scrollTtyKeypress: true
14+
15+
URxvt.secondaryScreen: 1
16+
URxvt.secondaryScroll: 0
17+
18+
URxvt.iso14755: false
19+
URxvt.iso14755_52: false
20+
21+
URxvt.scrollBar: false
22+
23+
URxvt.internalBorder: 8
24+
25+
! URXVT Font
26+
!URxvt*font: xft:Iosevka Anonymous Pro:size=12
27+
URxvt*font: xft:Roboto Mono:style=Medium:size=11, xft:RobotoMono Nerd Font Mono:size=11, xft:DejaVuSansMono Nerd Font Mono:size=11
28+
URxvt*boldFont: xft:Roboto Mono:style=Bold:size=11, xft:RobotoMono Nerd Font Mono:size=11, xft:DejaVuSansMono Nerd Font Mono:size=11
29+
URxvt*letterSpace: 0
30+
31+
! Perl Extensions
32+
URxvt.perl-ext-common: new-window
33+
34+
! Keybindings
35+
URxvt.keysym.Shift-Control-T: perl:new-window
36+
URxvt.keysym.Shift-Control-t: perl:new-window
37+
38+
URxvt.keysym.Shift-Control-C: eval:selection_to_clipboard
39+
URxvt.keyxym.Shift-Control-V: eval:paste_clipboard
40+
41+
! Colors
42+
43+
! special
44+
*.foreground: #e9efff
45+
*.background: #2f343f
46+
*.cursorColor: #e9efff
47+
URxvt.borderColor: #2f343f
48+
49+
! black
50+
*.color0: #404552
51+
*.color8: #4c5262
52+
53+
! red
54+
*.color1: #e18f93
55+
*.color9: #e18f93
56+
57+
! green
58+
*.color2: #addaaa
59+
*.color10: #addaaa
60+
61+
! yellow
62+
*.color3: #fdf0b8
63+
*.color11: #fdf0b8
64+
65+
! blue
66+
*.color4: #b7cdff
67+
*.color12: #b7cdff
68+
69+
! magenta
70+
*.color5: #e2abe2
71+
*.color13: #e2abe2
72+
73+
! cyan
74+
*.color6: #b8d0e4
75+
*.color14: #b8d0e4
76+
77+
! white
78+
*.color7: #fcfcfc
79+
*.color15: #fcfcfc

.config/polybar/config

+60
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
2+
[bar/top]
3+
width = 100%
4+
height = 30
5+
bottom = false
6+
fixed-center = true
7+
8+
; FONTS
9+
font-0 = Roboto:size=10;3
10+
;font-0 = t cherry:size=13;2
11+
12+
; COLORS
13+
background = #292c37
14+
15+
; BAR MODULES
16+
modules-left = i3
17+
modules-center = time
18+
modules-right =
19+
20+
; SYSTEM TRAY
21+
tray-position = right
22+
tray-padding = 4
23+
tray-maxsize = 18
24+
25+
26+
[module/i3]
27+
type = internal/i3
28+
29+
wrapping-scroll = false
30+
31+
label-focused = %name%
32+
label-focused-foreground = #F2F2F5
33+
label-focused-background = #69748D
34+
label-focused-padding = 6
35+
36+
label-visible = %name%
37+
label-visible-foreground = #F2F2F5
38+
label-visible-background =
39+
label-visible-padding = 6
40+
41+
label-unfocused = %name%
42+
label-unfocused-foreground = #5C627B
43+
label-unfocused-background =
44+
label-unfocused-padding = 6
45+
46+
label-urgent = %name%
47+
label-urgent-foreground = #5294E2
48+
label-urgent-background =
49+
label-urgent-padding = 6
50+
51+
52+
[module/time]
53+
type = custom/script
54+
55+
; Wed Apr 10, 10:43 AM
56+
exec = date '+%a %b %-d, %-I:%M %p'
57+
interval = 5
58+
label-padding = 4
59+
60+
; vim:ft=dosini

.config/polybar/launch.sh

+14
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
#!/bin/bash
2+
3+
# Terminate already running bar instances
4+
killall -q polybar
5+
6+
# Wait until the processes have been shut down
7+
while pgrep -u $UID -x polybar >/dev/null; do sleep 1; done
8+
9+
sleep 4;
10+
11+
# Launch Polybar, using default config location ~/.config/polybar/config
12+
polybar top &
13+
14+
echo "Polybar launched..."

.fehbg

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
#!/bin/sh
2+
feh --bg-fill '/home/vishnu/Pictures/Backgrounds/aD7PxAG.jpg'

.gvimrc

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
colorscheme slate
2+
set guifont=Iosevka\ Envy\ Code\ R\ 12

.ideavimrc

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
set visualbell
2+
set noerrorbells

.vimrc

+43-32
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,6 @@ endif
99

1010
" Load plugins
1111
call plug#begin('~/.vim/plugged')
12-
Plug 'vim-airline/vim-airline' " vim-airline
13-
Plug 'vim-airline/vim-airline-themes'
1412
call plug#end()
1513

1614
" }}}
@@ -30,45 +28,24 @@ set linebreak
3028
" Show line numbers
3129
set number
3230

33-
" Hide vim's insert/visual/normal hints
34-
set noshowmode
35-
3631
" Prevent delay for lightline when switching modes
3732
set ttimeoutlen=50
3833

3934
" Save files as sudo with :W
4035
cmap W w !sudo tee % > /dev/null
4136
42-
" Airline tabs
43-
let g:airline#extensions#tabline#enabled = 1
44-
45-
" Airline theme
46-
let g:airline_theme='deus'
47-
48-
" Airline font symbols
49-
let g:airline_powerline_fonts = 1
50-
51-
if !exists('g:airline_symbols')
52-
let g:airline_symbols = {}
53-
endif
54-
55-
" powerline symbols
56-
let g:airline_left_sep = ''
57-
let g:airline_left_alt_sep = ''
58-
let g:airline_right_sep = ''
59-
let g:airline_right_alt_sep = ''
60-
let g:airline_symbols.branch = 'br'
61-
let g:airline_symbols.readonly = 'ro'
62-
let g:airline_symbols.linenr = ''
63-
let g:airline_symbols.maxlinenr = ''
64-
6537
syntax on
6638

67-
set laststatus=2
68-
6939
set scrolljump=5
7040
set scrolloff=3
7141

42+
" vim command prompt
43+
nnoremap <Space> :
44+
vnoremap <Space> :
45+
46+
" Quickly Show/Switch Buffers
47+
nnoremap <F5> :buffers<CR>:buffer<Space>
48+
7249
set splitright
7350
set splitbelow
7451

@@ -83,11 +60,40 @@ set wildmode=longest:full,full
8360
set incsearch
8461
set hlsearch
8562

86-
" Change cursor in Insert mode
63+
" Change cursor in different modes
8764
let &t_SI = "\<Esc>[6 q"
8865
let &t_SR = "\<Esc>[4 q"
8966
let &t_EI = "\<Esc>[2 q"
9067

68+
function! CurrentGitBranch()
69+
return system("git rev-parse --abbrev-ref HEAD 2>/dev/null | tr -d '\n'")
70+
endfunction
71+
72+
function! StatusGitInfo()
73+
let l:branchname = CurrentGitBranch()
74+
return strlen(l:branchname) > 0?' '.l:branchname.' ':''
75+
endfunction
76+
77+
" Status Line
78+
set laststatus=2
79+
set statusline=
80+
set statusline+=%1*\ %n\ %* " Buffer number
81+
set statusline+=\ %f%h%w\ %m " File path
82+
set statusline+=%2*\ %R\ %* " Read-only
83+
set statusline+=%= " Spacer
84+
set statusline+=\ %{StatusGitInfo()} " Git branch
85+
set statusline+=%1*\ %-3c\ \ %4l/%-4L\ \ %3P\ %* " Line/Column Info
86+
87+
" Status line color
88+
hi StatusLine cterm=NONE ctermbg=0 ctermfg=white
89+
hi StatusLineNC cterm=NONE ctermbg=NONE ctermfg=8
90+
hi User1 cterm=NONE ctermbg=8 ctermfg=NONE
91+
hi User2 cterm=NONE ctermbg=0 ctermfg=red
92+
93+
" Split characters
94+
set fillchars+=vert:│
95+
hi VertSplit cterm=NONE ctermbg=NONE ctermfg=8
96+
9197
" Highlight cursorline
9298
set cursorline
9399
hi CursorLine cterm=NONE ctermbg=0 ctermfg=NONE
@@ -98,6 +104,9 @@ hi MatchParen cterm=NONE ctermbg=8 ctermfg=magenta
98104
" Folded section color
99105
hi Folded ctermbg=8
100106

107+
" Selection color
108+
hi Visual ctermbg=4 ctermfg=0
109+
101110
" }}}
102111

103112
" Spaces/Tabs {{{
@@ -120,6 +129,8 @@ vnoremap <C-d> "+d
120129

121130
" Auto Groups {{{
122131

132+
"autocmd FileType netrw nnoremap q :bd<CR>
133+
123134
augroup configgroup
124135
autocmd!
125136
autocmd VimEnter * highlight clear SignColumn
@@ -154,7 +165,7 @@ set foldenable
154165
set foldmethod=marker
155166
set foldlevel=0
156167
set modelines=1
157-
nnoremap <space> za
168+
nnoremap <Tab> za
158169
159170
" }}}
160171

.zkbd/alacritty-:0

+26
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
typeset -g -A key
2+
3+
key[F1]='^[OP'
4+
key[F2]='^[OQ'
5+
key[F3]='^[OR'
6+
key[F4]='^[OS'
7+
key[F5]='^[[15~'
8+
key[F6]='^[[17~'
9+
key[F7]='^[[18~'
10+
key[F8]='^[[19~'
11+
key[F9]='^[[20~'
12+
key[F10]='^[[21~'
13+
key[F11]='^[[23~'
14+
key[F12]='^[[24~'
15+
key[Backspace]='^?'
16+
key[Insert]='^[[2~'
17+
key[Home]='^[[H'
18+
key[PageUp]='^[[5~'
19+
key[Delete]='^[[3~'
20+
key[End]='^[[F'
21+
key[PageDown]='^[[6~'
22+
key[Up]='^[[A'
23+
key[Left]='^[[D'
24+
key[Down]='^[[B'
25+
key[Right]='^[[C'
26+
key[Menu]=''''

.zkbd/exit.tmp

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
typeset -g -A key
2+

.zkbd/linux-pc-linux-gnu

+26
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
typeset -g -A key
2+
3+
key[F1]='^[[[A'
4+
key[F2]='^[[[B'
5+
key[F3]='^[[[C'
6+
key[F4]='^[[[D'
7+
key[F5]='^[[[E'
8+
key[F6]='^[[17~'
9+
key[F7]='^[[18~'
10+
key[F8]='^[[19~'
11+
key[F9]='^[[20~'
12+
key[F10]='^[[21~'
13+
key[F11]='^[[23~'
14+
key[F12]='^[[24~'
15+
key[Backspace]='^?'
16+
key[Insert]='^[[2~'
17+
key[Home]='^[[1~'
18+
key[PageUp]='^[[5~'
19+
key[Delete]='^[[3~'
20+
key[End]='^[[4~'
21+
key[PageDown]='^[[6~'
22+
key[Up]='^[[A'
23+
key[Left]='^[[D'
24+
key[Down]='^[[B'
25+
key[Right]='^[[C'
26+
key[Menu]=''''

.zkbd/rxvt-unicode-256color-:0

+26
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
typeset -g -A key
2+
3+
key[F1]='^[[11~'
4+
key[F2]='^[[12~'
5+
key[F3]='^[[13~'
6+
key[F4]='^[[14~'
7+
key[F5]='^[[15~'
8+
key[F6]='^[[17~'
9+
key[F7]='^[[18~'
10+
key[F8]='^[[19~'
11+
key[F9]='^[[20~'
12+
key[F10]='^[[21~'
13+
key[F11]='^[[23~'
14+
key[F12]='^[[24~'
15+
key[Backspace]='^?'
16+
key[Insert]='^[[2~'
17+
key[Home]='^[[7~'
18+
key[PageUp]='^[[5~'
19+
key[Delete]='^[[3~'
20+
key[End]='^[[8~'
21+
key[PageDown]='^[[6~'
22+
key[Up]='^[[A'
23+
key[Left]='^[[D'
24+
key[Down]='^[[B'
25+
key[Right]='^[[C'
26+
key[Menu]=''''

0 commit comments

Comments
 (0)