Skip to content

Commit

Permalink
Change space consuming headings in init.vim + small changes to i3.conf
Browse files Browse the repository at this point in the history
Also add optional git branch showing in .bashrc
  • Loading branch information
antoniotrkdz committed Aug 2, 2020
1 parent 4d06c4a commit 9cfc99d
Show file tree
Hide file tree
Showing 5 changed files with 86 additions and 118 deletions.
2 changes: 1 addition & 1 deletion .bash_aliases
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ alias gcm='git checkout master'
alias gs='git status'

# vim aliases
alias v='vim'
alias v='nvim'
alias vg='gvim'

# Get color support for 'less'
Expand Down
2 changes: 1 addition & 1 deletion .bashrc
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ function parse_git_dirty {
[[ $(git status 2> /dev/null | tail -n1) != "nothing to commit, working tree clean" ]] && echo "!"
}
function parse_git_branch {
git branch --no-color 2> /dev/null | sed -e '/^[^*]/d' -e "s/* \(.*\)/(\1$(parse_git_dirty))/"
[[ $(git status 2> /dev/null) ]] && git branch --no-color 2> /dev/null | sed -e '/^[^*]/d' -e "s/* \(.*\)/(\1$(parse_git_dirty))/" || echo " "
}

if [ "$color_prompt" = yes ]; then
Expand Down
2 changes: 1 addition & 1 deletion conky.conf
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ ${color0}${downspeedgraph eth0 40,135 6D7882 FFFFFF 0 -t}$alignr${color0}${upspe
${color0}Total: $color${totaldown eth0}$alignr${color0}Total: $color${totalup eth0}
${voffset -10}
# ${color0}Iliad remaining data: $alignr$color${execi 600 bash scripts/iliad_residuo.sh}GB
${color0}Vodafone remaining data: $alignr$color${execi 600 ~/scripts/vodafone_scrape.py &}MB
# ${color0}Vodafone remaining data: $alignr$color${execi 600 ~/scripts/vodafone_scrape.py &}MB
${color0}Ping time to Google:${alignr} ${color}${exec ping -c 1 -W 1 www.google.it | grep -Eo "time=.+" | cut -c6-14}
$color0${if_up eth0}ETH $color${addr eth0}${endif}${if_up wlan0}wifi ${addr wlan0}${endif}$alignr${color0}open ports: $color${tcp_portmon 1 65535 count}
${color0}IP Address${alignr}DPORT
Expand Down
156 changes: 55 additions & 101 deletions i3/config
Original file line number Diff line number Diff line change
Expand Up @@ -2,40 +2,29 @@
# vim:filetype=i3
# This file has been auto-generated by i3-config-wizard(1).
# It will not be overwritten, so edit it as you like.

# _| _| _|
# _|_|_|_| _| _|_| _| _| _|_|_| _|_|_|_|
# _| _|_| _|_| _| _| _|
# _| _| _| _| _| _| _|
# _|_| _| _| _| _|_|_| _|_|_|_|
#
# _| _|_|_| _|_| _|
# _| _|_|_| _|_| _|_|_| _| _|_|_|
# _| _|_| _| _| _| _| _| _|_|_|_| _| _| _|
# _| _| _| _| _| _| _| _| _| _| _|
# _| _|_|_| _|_|_| _|_| _| _| _| _| _|_|_|
# _|
# _|_|

#________________________________________________/\\\__________________________
#____________________________/\\\________________\/\\\_________________________
#____/\\\____________________\/\\\________________\/\\\________________________
#__/\\\\\\\\\\\__/\\/\\\\\\\__\/\\\\\\\\___________\/\\\___/\\\\\\\\\\\________
#__\////\\\////__\/\\\/////\\\_\/\\\////\\\____/\\\\\\\\\__\///////\\\/________
#______\/\\\______\/\\\___\///__\/\\\\\\\\/____/\\\////\\\_______/\\\/_________
#_______\/\\\_/\\__\/\\\_________\/\\\///\\\___\/\\\__\/\\\_____/\\\/__________
#________\//\\\\\___\/\\\_________\/\\\_\///\\\_\//\\\\\\\/\\__/\\\\\\\\\\\____
#__________\/////____\///__________\///____\///___\///////\//__\///////////____
#______________________________________________________________________________
#
# ╦ ╔═╗ ╔═╗ ╔═╗ ╔╗╔ ╔═╗ ╦ ╔═╗
# ║ ═╣ ║ ║ ║ ║║║ ╠╣ ║ ║ ╦
# ╩ ╚═╝ ╚═╝ ╚═╝ ╝╚╝ ╚ ╩ ╚═╩════════════════════════════════════════
# Please see https://i3wm.org/docs/userguide.html for a complete reference!
#
# ..%%%%...%%%%%%..%%%%%%..%%...%%...%%%%...%%%%%..
# .%%......%%........%%....%%%.%%%..%%..%%..%%..%%.
# ..%%%%...%%%%......%%....%%.%.%%..%%..%%..%%..%%.
# .....%%..%%........%%....%%...%%..%%..%%..%%..%%.
# ..%%%%...%%%%%%....%%....%%...%%...%%%%...%%%%%..
#
# Mod4 is Super_L, but search "Set Spacebar as modifier"
#-------------------------------------------------------------------------------
# Mod4 is Super_L, but search "Set Spacebar as modifier" on G
set $mod Mod4

# :::::::: :::::::::: ::::::::::: ::::::::::: ::::::::::: :::: ::: :::::::: ::::::::
# :+: :+: :+: :+: :+: :+: :+:+: :+: :+: :+: :+: :+:
# +:+ +:+ +:+ +:+ +:+ :+:+:+ +:+ +:+ +:+
# +#++:++#++ +#++:++# +#+ +#+ +#+ +#+ +:+ +#+ :#: +#++:++#++
# +#+ +#+ +#+ +#+ +#+ +#+ +#+#+# +#+ +#+# +#+
# #+# #+# #+# #+# #+# #+# #+# #+#+# #+# #+# #+# #+#
# ######## ########## ### ### ########### ### #### ######## ########

#-------------------------------------------------------------------------------
# ╔═╗ ╔═╗ ╔╦╗ ╔╦╗ ╦ ╔╗╔ ╔═╗ ╔═╗
# ╚═╗ ║╣ ║ ║ ║ ║║║ ║ ╦ ╚═╗
# ╚═╝ ╚═╝ ╩ ╩ ╩ ╝╚╝ ╚═╝ ╚═╝
#
# Set smart borders (no border when just one window):
#hide_edge_borders smart

Expand All @@ -51,24 +40,10 @@ focus_follows_mouse no
# Use Mouse+$mod to drag floating windows to their wanted position
floating_modifier $mod

# ##### ##
# ###### /### /
# /# / / ##/ #
# / / / # ##
# / / ##
# ## ## /### ### /### ########
# ## ## / ### / ###/ #### / ########
# ## ###### / ###/ ## ###/ ##
# ## ##### ## ## ## ## ##
# ## ## ## ## ## ## ##
# # ## ## ## ## ## ##
# # ## ## ## ## ##
# /#### ## ## ## ## ##
# / ##### ###### ### ### ##
# / ### #### ### ### ##
# #
# ##

# ╔═╗ ╔═╗ ╔╗╔ ╔╦╗
# ╠╣ ║ ║ ║║║ ║
# ╚ ╚═╝ ╝╚╝ ╩
#
# Font for window titles. Will also be used by the bar unless a different font
# is used in the bar {} block below.
# Before i3 v4.8, we used to recommend this one as the default:
Expand All @@ -78,15 +53,15 @@ floating_modifier $mod
# X core fonts rendering does not support right-to-left and this being a bitmap
# font, it doesn’t scale on retina/hidpi displays.

font pango:IBM 3270 Narrow bold 14
#font pango:anorexia 16
#font pango:Sans 14
#font pango:Droid Sans bold 14
font pango:IBM 3270 Narrow bold 14

# _______ _____ _____ ______ _______
# | | | | | | |_____/ |______
# |_____ |_____| |_____ |_____| | \_ ______|

# ╔═╗ ╔═╗ ╦ ╔═╗ ╦═╗ ╔═╗
# ║ ║ ║ ║ ║ ║ ╠╦╝ ╚═╗
# ╚═╝ ╚═╝ ╩═╝ ╚═╝ ╩╚═ ╚═╝
#
# Set background:
# Mate sets the background on its own.
#exec --no-startup-id nitrogen --restore
Expand Down Expand Up @@ -118,17 +93,10 @@ client.focused_inactive $inactive-bg-color $inactive-bg-color $inactive-text-co
client.unfocused $inactive-bg-color $inactive-bg-color $inactive-text-color $indicator-color $inactive-bg-color
client.urgent $urgent-bg-color $urgent-bg-color $text-color $indicator-color $urgent-bg-color

# ╔╗ ╦ ╔╗╔ ╔╦╗ ╦ ╔╗╔ ╔═╗ ╔═╗
# ╠╩╗ ║ ║║║ ║║ ║ ║║║ ║ ╦ ╚═╗
# ╚═╝ ╩ ╝╚╝ ═╩╝ ╩ ╝╚╝ ╚═╝ ╚═╝
#
# 88888888ba 88 88 88
# 88 "8b "" 88 ""
# 88 ,8P 88
# 88aaaaaa8P' 88 8b,dPPYba, ,adPPYb,88 88 8b,dPPYba, ,adPPYb,d8 ,adPPYba,
# 88""""""8b, 88 88P' `"8a a8" `Y88 88 88P' `"8a a8" `Y88 I8[ ""
# 88 `8b 88 88 88 8b 88 88 88 88 8b 88 `"Y8ba,
# 88 a8P 88 88 88 "8a, ,d88 88 88 88 "8a, ,d88 aa ]8I
# 88888888P" 88 88 88 `"8bbdP"Y8 88 88 88 `"YbbdP"Y8 `"YbbdP"'
# aa, ,88
# "Y8bbdP"
# Restore Space as modifier see .xsessionrc
bindsym $mod+F1 exec --no-startup-id "< .xsessionrc grep -e /bin/.*x[^s] | bash -; \
notify-send 'You Can use SPC as modifier' \
Expand Down Expand Up @@ -251,6 +219,10 @@ bindsym $mod+Shift+r restart
# Exit i3 (logs you out of your X session)
#bindsym $mod+Shift+e exec "i3-nagbar -t warning -m 'You pressed the exit shortcut. Do you really want to exit i3? This will end your X session.' -b 'Yes, exit i3' 'i3-msg exit'"

# GENERIC Put the display into standby
# bindsym $mod+Shift+z exec --no-startup-id "sleep 1 && xset dpms force off"
bindsym $mod+Shift+z exec --no-startup-id "~/scripts/standbydisplay.sh"

# XFCE4 logout
#bindsym $mod+Shift+e exec "xfce4-session-logout"

Expand All @@ -261,24 +233,17 @@ bindsym $mod+Shift+e exec --no-startup-id "mate-session-save --logout-dialog"
bindsym $mod+Shift+s exec --no-startup-id "mate-session-save --shutdown-dialog"

# MATE Turn the screensaver on (blank the screen)
bindsym $mod+Shift+b exec --no-startup-id "mate-screensaver-command -a"
# bindsym $mod+Shift+b exec --no-startup-id "mate-screensaver-command -a"

# Start xfce4-panel (with workspace plugin).
#exec_always --no-startup-id xfce4-panel --disable-wm-check

# Start mate-panel (with workspace plugin) -- to be studied...Not needed now
#exec_always --no-startup-id mate-panel --disable-wm-check

# _______ __
# / \ / |
# $$$$$$$ | ______ _______ $$/ ________ ______
# $$ |__$$ | / \ / |/ |/ | / \
# $$ $$< /$$$$$$ |/$$$$$$$/ $$ |$$$$$$$$/ /$$$$$$ |
# $$$$$$$ |$$ $$ |$$ \ $$ | / $$/ $$ $$ |
# $$ | $$ |$$$$$$$$/ $$$$$$ |$$ | /$$$$/__ $$$$$$$$/
# $$ | $$ |$$ |/ $$/ $$ |/$$ |$$ |
# $$/ $$/ $$$$$$$/ $$$$$$$/ $$/ $$$$$$$$/ $$$$$$$/

# +-+-+-+-+-+-+-+-+-+-+-+-+
# | R e s i z e m o d e |
# +-+-+-+-+-+-+-+-+-+-+-+-+
# Resize window (you can also use the mouse for that)
mode "resize" {
# These bindings trigger as soon as you enter the resize mode
Expand All @@ -305,9 +270,9 @@ mode "resize" {

bindsym $mod+r mode "resize"

# +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
# |T i l i n g / F l o a t i n g|
# +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
# +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
# | T i l i n g / F l o a t i n g |
# +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
# Toggle tiling / floating
# border and title only on floating windows
show_marks no
Expand All @@ -320,21 +285,11 @@ bindsym $mod+Shift+p "mark --add _; \
# Change focus between tiling / floating windows
bindsym $mod+p focus mode_toggle
#bindsym $mod+space focus mode_toggle
# +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
# +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

#
# 8 888888888o .8. 8 888888888o.
# 8 8888 `88. .888. 8 8888 `88.
# 8 8888 `88 :88888. 8 8888 `88
# 8 8888 ,88 . `88888. 8 8888 ,88
# 8 8888. ,88' .8. `88888. 8 8888. ,88'
# 8 8888888888 .8`8. `88888. 8 888888888P'
# 8 8888 `88. .8' `8. `88888. 8 8888`8b
# 8 8888 88 .8' `8. `88888. 8 8888 `8b.
# 8 8888 ,88' .888888888. `88888. 8 8888 `8b.
# 8 888888888P .8' `8. `88888. 8 8888 `88.

# ╔╗ ╔═╗ ╦═╗
# ╠╩╗ ╠═╣ ╠╦╝
# ╚═╝ ╩ ╩ ╩╚═
#
# Start i3bar to display a workspace bar (plus the system information i3status
# finds out, if available).
## With xfce4-panel and i3-plugin this section can be commented out entirely.
Expand Down Expand Up @@ -374,13 +329,10 @@ bar {
}
}

# d88888b .d88b. d8888b. db d8b db d888888b d8b db d8888b. .d88b. db d8b db
# 88' .8P Y8. 88 `8D 88 I8I 88 `88' 888o 88 88 `8D .8P Y8. 88 I8I 88
# 88ooo 88 88 88oobY' 88 I8I 88 88 88V8o 88 88 88 88 88 88 I8I 88
# 88~~~ 88 88 88`8b Y8 I8I 88 88 88 V8o88 88 88 88 88 Y8 I8I 88
# 88 `8b d8' 88 `88. `8b d8'8b d8' .88. 88 V888 88 .8D `8b d8' `8b d8'8b d8'
# YP `Y88P' 88 YD C88888D `8b8' `8d8' Y888888P VP V8P Y8888D' `Y88P' `8b8' `8d8'

# ╔═╗ ╔═╗ ╦═╗ ╦ ╦ ╦ ╔╗╔ ╔╦╗ ╔═╗ ╦ ╦
# ╠╣ ║ ║ ╠╦╝ ║║║ ║ ║║║ ║║ ║ ║ ║║║
# ╚ ╚═╝ ╩╚═ ════ ╚╩╝ ╩ ╝╚╝ ═╩╝ ╚═╝ ╚╩╝
#
## Select all windows in tiling layer.
for_window [tiling class="^.*"] border pixel 2
new_window pixel 2
Expand Down Expand Up @@ -409,7 +361,9 @@ for_window [title="(?i)Tabs Outliner$"] floating enable, border normal 1, resize
for_window [title="(?i)Tabs Outliner Options"] floating disable, border pixel 1
for_window [title="(?i)Extract files"] resize set 400 500
for_window [title="(?i)Select one or multiple files"] floating enable, border normal 1, resize set 700 900, move position center
for_window [title="(?i)Steam"] floating enable, border normal 1, resize set 1716 1400
for_window [title="(?i)^Steam$"] floating enable, border normal 1, resize set 1716 1400
for_window [title="(?i)Friends List"] floating enable, border normal 1, resize set 1000 1400
for_window [title="(?i)Mad Max Options"] floating enable, border pixel 1
for_window [title="(?i)^Mad Max$"] fullscreen
for_window [title="(?i)XCOM 2 Options"] floating enable, border normal 1, resize set 800 600
for_window [title="(?i)^XCOM 2$"] fullscreen
42 changes: 28 additions & 14 deletions init.vim
Original file line number Diff line number Diff line change
Expand Up @@ -11,18 +11,22 @@
"________\//\\\\\___\/\\\_________\/\\\_\///\\\_\//\\\\\\\/\\__/\\\\\\\\\\\____
"__________\/////____\///__________\///____\///___\///////\//__\///////////____
"______________________________________________________________________________

" ╦ ╔╗╔ ╦ ╔╦╗ ╦ ╦ ╦ ╔╦╗
" ║ ║║║ ║ ║ ╚╗╔╝ ║ ║║║
" ╩ ╝╚╝ ╩ ╩ o ╚╝ ╩ ╩ ╩ ────────────────────────────────────────────
set completeopt+=noinsert,menuone

" Turn off the preview (opening a scratch buffer) from the YouCompleteMe menu
set completeopt-=preview
"
" ╦ ╔╗╔ ╦ ╔╦╗ ╦ ╦ ╦ ╔╦╗
" ║ ║║║ ║ ║ ┌┐ ╚╗╔╝ ║ ║║║
" ╩ ╝╚╝ ╩ ╩ └┘ ╚╝ ╩ ╩ ╩═════════════════════════════════════════════

" Turn off the preview (opening a scratch buffer) from the completion menu.
"set completeopt-=preview
" First menu item selected (but not inserted): noinsert in combination with menu.
"set completeopt=menu,noinsert
" COC uses its own completeopt on completion and restores the settings when done,
" so add suggest.noselect: false to coc-settings.json.

" Highlight the current line and column only in the current window
autocmd WinLeave * set nocursorline nocursorcolumn
autocmd WinEnter * set cursorline cursorcolumn
autocmd vimEnter * set cursorline cursorcolumn

" Disable all error bells
set belloff=all
Expand Down Expand Up @@ -151,15 +155,18 @@ call plug#begin('~/.config/nvim/plugged')
Plug 'vim-scripts/dbext.vim'
"i3wm .config syntax
Plug 'PotatoesMaster/i3-vim-syntax'
"Vim-markbar
Plug 'Yilin-Yang/vim-markbar'
"Vim-markbar (activate with ' or `)
" Plug 'Yilin-Yang/vim-markbar'
"Alternative sudo.vim for Vim and Neovim
Plug 'lambdalisue/suda.vim'

"Unmanged plugin to show terminal colors, use :XtermColorTable
Plug '~/.vim/xterm-color-table.vim'
" Plugin to highlight matchit.
Plug '~/.vim/99-hl-matchlines.vim'
" Uncomplicated alternative to vim-signature (shows mark in gutter)
" Here in place of vim-markbar
Plug '~/.vim/marksigns.vim'

"Theme (CLI)
Plug 'neutaaaaan/iosvkem'
Expand Down Expand Up @@ -315,6 +322,12 @@ nnoremap <silent> <space>j :<C-u>CocNext<CR>
nnoremap <silent> <space>k :<C-u>CocPrev<CR>
" Resume latest coc list.
nnoremap <silent> <space>p :<C-u>CocListResume<CR>
" coc.nvim works best on neovim >= 0.4.3, consider upgrade your neovim.
" You can set this to make this error message go away:
let g:coc_disable_startup_warning = 1
" Note that some features may behave incorrectly.

"COC SETTINGS END -------------------------------------------------------------

" Vue files
Expand Down Expand Up @@ -389,6 +402,7 @@ let g:ale_fixers = {
\ 'html': [ 'tidy' ],
\ 'css': ['prettier', 'stylelint'],
\ 'scss': ['prettier', 'stylelint'],
\ 'vue': ['prettier']
\ }
let g:ale_linters = {
\ 'javascript': ['prettier', 'eslint'],
Expand All @@ -409,9 +423,9 @@ let g:ale_echo_msg_format = '%linter%: %s [%severity%]'
"let g:ale_sign_warning = '--' "Default
let g:ale_sign_info = '..'
"
" ╔╦╗╔═╗╔═╗╔═╗╔╗╔╔═╗╔═╗
" ║║║╠═╣╠═╝╠═╝║║║║ ╦╚═╗
" ╩ ╩╩ ╩╩ ╩ ╝╚╝╚═╝╚═╝
" ╔╦╗ ╔═╗ ╔═╗ ╔═╗╔╗╔ ╔═╗ ╔═╗
" ║║║ ╠═╣ ╠═╝ ╠═╝║║║ ║ ╦ ╚═╗
" ╩ ╩ ╩ ╩ ╝╚╝ ╚═╝ ╚═╝
" make sure there are no spaces at the end!
inoremap jk <esc>
inoremap kj <esc>
Expand Down Expand Up @@ -467,7 +481,7 @@ vmap u y
nnoremap <leader>[ :%s/<c-r><c-w>//gc<left><left><left>
" Open a terminal on the bottom
noremap <leader>b :botright 13sp term:https://$SHELL<CR>i
noremap <F12> :botright 13sp term:https://$SHELL<CR>i
" mappings to exit terminal-mode:
tnoremap <Esc> <C-\><C-n>
tnoremap jk <C-\><C-n>
Expand Down

0 comments on commit 9cfc99d

Please sign in to comment.