dotfiles

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | Submodules | README

commit 83ae4071fd41c34b5f45d9f2dc9f45629016010a
parent 8265034a15a67e70b5bb9b53566441013ff05619
Author: Pablo CΓ‘rdenas <pablo-cardenas@outlook.com>
Date:   Sat, 29 Feb 2020 16:13:57 -0500

i3, rofi, polybar, etc

Diffstat:
Mhome/.bash/aliases.bash | 5++++-
Dhome/.bash/colors.bash | 20--------------------
Mhome/.bash/env.bash | 11+++--------
Dhome/.bash/functions.bash | 11-----------
Dhome/.bash/prompt.bash | 25-------------------------
Mhome/.bash_profile | 18+++++++++++++-----
Mhome/.bashrc | 26++++++++++----------------
Dhome/.config/nvim/.gitignore | 2--
Dhome/.config/nvim/colorscheme.vim | 1-
Dhome/.config/nvim/init.vim | 169-------------------------------------------------------------------------------
Dhome/.config/nvim/plugins.vim | 46----------------------------------------------
Mhome/.latexmkrc | 5+++--
Mhome/.octaverc | 4++--
Mhome/.tmux.conf | 4+---
Mlinux/.Xresources | 3+--
Mlinux/.Xresources.d/colors | 68++++++++++++++++++++++++--------------------------------------------
Dlinux/.Xresources.d/fonts | 6------
Mlinux/.Xresources.d/rxvt-unicode | 27++++++++-------------------
Dlinux/.compton.conf | 49-------------------------------------------------
Alinux/.config/dunst/dunstrc | 0
Mlinux/.config/i3/config | 86++++++++++++++++++++++++++++++++++++++-----------------------------------------
Alinux/.config/picom/picom.conf | 17+++++++++++++++++
Mlinux/.config/polybar/config | 231+++++++++++++++++++++++++++++++++++++++++++++++++------------------------------
Alinux/.config/rofi/config.rasi | 98+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Mlinux/.xinitrc | 7++++---
25 files changed, 372 insertions(+), 567 deletions(-)

diff --git a/home/.bash/aliases.bash b/home/.bash/aliases.bash @@ -1,4 +1,7 @@ # system alias ll='ls -alFh' alias la='ls -A' -alias vim='nvim' +alias ls='ls --color=auto' +alias grep='grep --color=auto' +alias fgrep='fgrep --color=auto' +alias egrep='egrep --color=auto' diff --git a/home/.bash/colors.bash b/home/.bash/colors.bash @@ -1,20 +0,0 @@ -# Note that BSD ls (Mac) and GNU ls (Linux) have different flags for -# toggling color on command output. Therefore we have to check which -# OS are we supporting. - -case `uname` in - Darwin*) - alias ls='ls -G' - alias grep='grep --color=auto' - alias fgrep='fgrep --color=auto' - alias egrep='egrep --color=auto' - ;; - Linux*) - if [ -x /usr/bin/dircolors ]; then - alias ls='ls --color=auto' - alias grep='grep --color=auto' - alias fgrep='fgrep --color=auto' - alias egrep='egrep --color=auto' - fi - ;; -esac diff --git a/home/.bash/env.bash b/home/.bash/env.bash @@ -1,9 +1,4 @@ -export EDITOR=nvim +export EDITOR=vim export PAGER=less -export LANG=es_ES.UTF-8 -export BROWSER=qutebrowser - -# /usr/bin/open will be present on macOS -if [ -x /usr/bin/open ]; then - export BROWSER=open -fi +export LANG=en_US.UTF-8 +export BROWSER=firefox diff --git a/home/.bash/functions.bash b/home/.bash/functions.bash @@ -1,11 +0,0 @@ -# Check if command exists. Actually just runs `command -v` silently. -exists() { command -v "$1" >/dev/null 2>&1 && return 0 || return 1; } - -# Echo to stderr. -echoerr() { echo $@ 1>&2; } - -# Colored messages: info, success, warning, error -cm_info() { tput setaf 6; echoerr "INFO: $@"; tput sgr0; } -cm_success() { tput setaf 2; echoerr "SUCCESS: $@"; tput sgr0; } -cm_warning() { tput setaf 3; echoerr "WARNING: $@"; tput sgr0; } -cm_error() { tput setaf 1; echoerr "ERROR: $@"; tput sgr0; } diff --git a/home/.bash/prompt.bash b/home/.bash/prompt.bash @@ -1,25 +0,0 @@ -__prompt() { - local EXIT_CODE="$?" - local base01='\[\e[1;31m\]' - local base02='\[\e[1;32m\]' - local base03='\[\e[1;33m\]' - local base04='\[\e[1;34m\]' - local base05='\[\e[1;35m\]' - local base06='\[\e[1;36m\]' - local base07='\[\e[1;37m\]' - local base08='\[\e[1;30m\]' - local reset='\[\e[0m\]' - - PS1="\n$base04\u$reset at $base06\h$reset in $base03\w" - - - if [ $EXIT_CODE != 0 ]; then - PS1="$PS1 $base01[$EXIT_CODE]\n$" - else - PS1="$PS1 $base05\n$" - fi - - PS1="$PS1$reset " -} - -export PROMPT_COMMAND=__prompt diff --git a/home/.bash_profile b/home/.bash_profile @@ -1,5 +1,13 @@ -# This file is sourced by bash for login shells. The following line -# runs your .bashrc and is recommended by the bash info pages. -if [[ -f ~/.bashrc ]] ; then - . ~/.bashrc -fi +source ~/.bash/env.bash + +# Add local bin directories to PATH. +[ -d $HOME/.bin ] && PATH="$PATH:$HOME/.bin" +[ -d $HOME/.local/bin ] && PATH="$PATH:$HOME/.local/bin" +[ -d $HOME/.node_modules/bin ] && PATH="$PATH:$HOME/.node_modules/bin" +export npm_config_prefix=~/.node_modules + +source ~/.bashrc + +export PATH + +unset try_source diff --git a/home/.bashrc b/home/.bashrc @@ -7,33 +7,27 @@ HISTCONTROL=ignoreboth HISTSIZE=10000 HISTFILESIZE=2000 - -# TODO: What's a portable way for doing this? -[ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh lesspipe)" - # Bash completions if ! shopt -oq posix; then [ -f /etc/bash_completion ] && source /etc/bash_completion [ -f /usr/local/etc/bash_completion ] && source /usr/local/etc/bash_completion fi -source ~/.bash/colors.bash source ~/.bash/aliases.bash -source ~/.bash/functions.bash -source ~/.bash/prompt.bash for f in ~/.bash/local.d/*.bash; do - if [ -x $f ]; then . $f; fi + if [ -x $f ]; then source $f; fi done -export EDITOR=nvim - # Para clases #export PS1='\[\033[01;31m\]\W $\[\033[00m\] ' -# Base16 Shell -BASE16_SHELL_SET_BACKGROUND=false -BASE16_SHELL="$HOME/.base16-manager/chriskempson/base16-shell/" -[ -n "$PS1" ] && \ - [ -s "$BASE16_SHELL/profile_helper.sh" ] && \ - eval "$("$BASE16_SHELL/profile_helper.sh")" + +export LESS=-R +export LESS_TERMCAP_mb=$'\E[1;31m' # begin blink +export LESS_TERMCAP_md=$'\E[1;36m' # begin bold +export LESS_TERMCAP_me=$'\E[0m' # reset bold/blink +export LESS_TERMCAP_so=$'\E[01;44;33m' # begin reverse video +export LESS_TERMCAP_se=$'\E[0m' # reset reverse video +export LESS_TERMCAP_us=$'\E[1;32m' # begin underline +export LESS_TERMCAP_ue=$'\E[0m' # reset underline diff --git a/home/.config/nvim/.gitignore b/home/.config/nvim/.gitignore @@ -1,2 +0,0 @@ -autoload/plug.vim -plugged diff --git a/home/.config/nvim/colorscheme.vim b/home/.config/nvim/colorscheme.vim @@ -1 +0,0 @@ -colorscheme base16-solarized-dark diff --git a/home/.config/nvim/init.vim b/home/.config/nvim/init.vim @@ -1,169 +0,0 @@ -" Installs vim-plug -if empty(glob("~/.config/nvim/autoload/plug.vim")) - silent !curl -fLso ~/.config/nvim/autoload/plug.vim --create-dirs https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim - autocmd VimEnter * PlugInstall -end - -" vim-plug plugins -call plug#begin("~/.config/nvim/plugged/") -source $HOME/.config/nvim/plugins.vim -call plug#end() - -" Disable aditional files. -set noswapfile " disable swapfiles (maybe a bad idea? πŸ€”) -set nobackup " disable backup files (use git) -set encoding=utf-8 " windows needs to be reminded about utf-8 -set backspace=indent,eol,start " backspace will always work on insert mode - -" Indent settings -set autoindent -set smarttab -set expandtab -set shiftwidth=4 -set softtabstop=4 - -" Buffer settings -set hidden -set nowrap -set showmatch -set noshowmode - -" Some programming languages work better when 2 spaces for tab is used... -autocmd FileType html,css,sass,scss,javascript setlocal sw=2 sts=2 -autocmd FileType json setlocal sw=2 sts=2 -autocmd FileType ruby,eruby setlocal sw=2 sts=2 -autocmd FileType yaml setlocal sw=2 sts=2 -autocmd FileType python setlocal tw=79 - -" Enable colorschemes, but only if terminal supports so. -if &t_Co > 2 || has("gui_running") - syntax on - set colorcolumn=80 - let base16colorspace=256 - silent! color base16-default-dark -endif - -" Line numberings and relative numberings -set number -set relativenumber -nmap <F5> :set invrelativenumber<CR> -imap <F5> <ESC>:set invrelativenumber<CR>i - -" Mark cursor lines and columns, but only if there are enough colors. -" (These settings don't look so pleasant when there are not enough colors). -if &t_Co >= 256 - set cursorline -endif - -" Mark trailing spaces. -if &t_Co >= 2 - " Fancy highlighting for space groups. - highlight ExtraWhitespace ctermbg=red guibg=red - match ExtraWhitespace /\s\+$/ -else - " Fallback trailing system. - set listchars=trail:~ - set list -endif - -" Make the vertical separator between panes a continuous vertical line. -" NOTE! The font must support this character to make it look continuous. -" Otherwise, the vertical bar will have little gaps in between lines. -set fillchars+=vert:\β”‚ -highlight VertSplit guibg=NONE cterm=NONE ctermbg=NONE - -" Leader. We're having fun. -let mapleader="," - -" Switch active buffers. - map <C-N> :bnext<CR> -imap <C-N> <Esc>:bnext<CR>i - map <C-P> :bprev<CR> -imap <C-P> <Esc>:bprev<CR>i - -" Folding settings: global and particular for specific plugins. -nmap <Space> za -let g:SimpylFold_docstring_preview = 1 - -" CtrlP -let g:ctrlp_map = '<Leader>,' -let g:ctrlp_user_command = ['.git', 'cd %s && git ls-files -co --exclude-standard'] - -" vim-gitgutter -nmap <Leader>hn <Plug>GitGutterNextHunk -nmap <Leader>hp <Plug>GitGutterPrevHunk -nmap <Leader>ha <Plug>GitGutterStageHunk -nmap <Leader>hr <Plug>GitGutterUndoHunk -nmap <Leader>hv <Plug>GitGutterPreviewHunk - -" undotree -nmap <Leader>u :UndotreeToggle<CR> -if has("persistent_undo") - set undodir=$HOME/.local/share/nvim/undo/ - set undofile -endif - -" Buffergator -nmap <Leader>b :BuffergatorToggle<CR> - -" NERDtree -map <Leader>nt :NERDTreeToggle<CR> -let NERDTreeQuitOnOpen=1 -let NERDTreeWinSize=20 - -" tagbar -nmap <F8> :TagbarOpen fj<CR> -let g:tagbar_indent = 1 -let g:tagbar_autoshowtag = 1 -function DaniComputeTagbarWidth() - if winwidth(0) > 180 - let g:tagbar_width = 40 - else - let g:tagbar_width = 25 - endif -endfunction -call DaniComputeTagbarWidth() -autocmd VimResized * exe "call DaniComputeTagbarWidth()" - -" ack -nnoremap <C-T> :Ack!<Space> -if executable('ag') - let g:ackprg = 'ag --vimgrep' -end - -" vimwiki -let g:vimwiki_list = [{'path': '~/.vimwiki'}] - -" deoplete -let g:deoplete#enable_at_startup = 1 -let g:deoplete#sources#jedi#show_docstring = 1 -let g:LanguageClient_serverCommands = { - \ 'javascript': ['javascript-typescript-stdio'], - \ 'css': ['css-languageserver', '--stdio'], - \ 'typescript': ['javascript-typescript-stdio'], - \ } -autocmd InsertLeave,CompleteDone * if pumvisible() == 0 | pclose | endif - -" deoplete-clang -" TODO: These routes are hardcoded to work with macOS. What about Linux / BSD? -let g:deoplete#sources#clang#clang_header = '/Library/Developer/CommandLineTools/usr/lib/clang/9.1.0/include' -let g:deoplete#sources#clang#libclang_path = '/Library/Developer/CommandLineTools/usr/lib/libclang.dylib' - -" syntastic -let g:syntastic_check_on_open = 1 -let g:syntastic_c_config_file = '.syntastic_c_config' - -" echodoc -let g:echodoc_enable_at_startup = 1 - -" indentline -let g:indentLine_concealcursor=0 - -" markdown + vim-markdown -let g:vim_markdown_frontmatter = 1 -autocmd FileType markdown set breakindent wrap linebreak - -source ~/.config/nvim/colorscheme.vim - -silent! hi Normal ctermbg=none -silent! hi NonText ctermbg=none diff --git a/home/.config/nvim/plugins.vim b/home/.config/nvim/plugins.vim @@ -1,46 +0,0 @@ -" Vim productivity -Plug 'ap/vim-buftabline' -Plug 'ctrlpvim/ctrlp.vim' -Plug 'jeetsukumaran/vim-buffergator' -Plug 'mbbill/undotree' -Plug 'mileszs/ack.vim' -Plug 'scrooloose/nerdtree' -Plug 'vimwiki/vimwiki' -Plug 'tpope/vim-obsession' -Plug 'jeffkreeftmeijer/vim-numbertoggle' -Plug 'Yggdroot/indentLine' -Plug 'godlygeek/tabular' -Plug 'junegunn/goyo.vim' - -" Language productivity -" Plug 'AndrewRadev/splitjoin.vim' -Plug 'airblade/vim-gitgutter' -" Plug 'alvan/vim-closetag' -Plug 'editorconfig/editorconfig-vim' -Plug 'mattn/emmet-vim' -" Plug 'tpope/vim-endwise' -Plug 'tpope/vim-fugitive' -Plug 'majutsushi/tagbar' -Plug 'Shougo/deoplete.nvim', { 'do': ':UpdateRemotePlugins' } -Plug 'Shougo/neoinclude.vim' -Plug 'Shougo/neco-syntax' -Plug 'autozimu/LanguageClient-neovim', { 'branch': 'next', 'do': 'bash install.sh' } -Plug 'leafgarland/typescript-vim' -Plug 'vim-syntastic/syntastic' -Plug 'ervandew/supertab' -Plug 'jiangmiao/auto-pairs' -Plug 'Shougo/echodoc.vim' - -" Python productivity pack -Plug 'tmhedberg/SimpylFold', { 'for': ['python'] } -Plug 'zchee/deoplete-jedi', { 'for': ['python'] } -Plug 'Vimjas/vim-python-pep8-indent', { 'for': ['python'] } - -" C productivity pack -Plug 'zchee/deoplete-clang', { 'for': ['c', 'c++'] } - -" Markdown productivity pack -Plug 'plasticboy/vim-markdown' - -" Colorschemes -Plug 'chriskempson/base16-vim' diff --git a/home/.latexmkrc b/home/.latexmkrc @@ -1,3 +1,4 @@ $pdf_previewer = 'start zathura'; -@generated_exts = (@generated_exts, 'synctex.gz'); -$pdflatex = 'pdflatex -synctex=1 -interaction=nonstopmode'; +#@generated_exts = (@generated_exts, 'synctex.gz'); +#$pdflatex = 'pdflatex -synctex=1 -interaction=nonstopmode'; +$pdflatex = 'pdflatex -synctex=0'; diff --git a/home/.octaverc b/home/.octaverc @@ -1,6 +1,6 @@ edit mode sync edit home . -EDITOR('vim > /dev/tty 2>&1 < /dev/tty %s') +EDITOR('nvim > /dev/tty 2>&1 < /dev/tty %s') % Para clases -PS1 ("octave> ") +% PS1 ("octave> ") diff --git a/home/.tmux.conf b/home/.tmux.conf @@ -1,5 +1,3 @@ -set -g default-terminal tmux-256color # Use 256 colors +#set -g default-terminal tmux-256color # Use 256 colors set -g history-limit 100000 # Scrollback buffer number of lines set -s escape-time 0 - -source-file "${HOME}/.base16-tmux/base16.tmuxtheme" diff --git a/linux/.Xresources b/linux/.Xresources @@ -1,3 +1,2 @@ -#include ".Xresources.d/themes/solarized.xresources" +#include ".Xresources.d/colors" #include ".Xresources.d/rxvt-unicode" -#include ".Xresources.d/fonts" diff --git a/linux/.Xresources.d/colors b/linux/.Xresources.d/colors @@ -1,45 +1,25 @@ -! Base16 Solarized Dark -! Scheme: Ethan Schoonover (http://ethanschoonover.com/solarized) +*.foreground: #e5e5e5 +*.background: #000000 +URxvt.foreground: #e5e5e5 +URxvt.background: #000000 +i3wm.fg0: #ffffff +i3wm.fg1: #e5e5e5 +i3wm.bg0: #000000 +i3wm.bg1: #4d4d4d -#define base00 #002b36 -#define base01 #073642 -#define base02 #586e75 -#define base03 #657b83 -#define base04 #839496 -#define base05 #93a1a1 -#define base06 #eee8d5 -#define base07 #fdf6e3 -#define base08 #dc322f -#define base09 #cb4b16 -#define base0A #b58900 -#define base0B #859900 -#define base0C #2aa198 -#define base0D #268bd2 -#define base0E #6c71c4 -#define base0F #d33682 - -*foreground: base05 -#ifdef background_opacity -*background: [background_opacity]base00 -#else -*background: base00 -#endif -*cursorColor: base05 - -*color0: base00 -*color1: base08 -*color2: base0B -*color3: base0A -*color4: base0D -*color5: base0E -*color6: base0C -*color7: base05 - -*color8: base03 -*color9: base09 -*color10: base01 -*color11: base02 -*color12: base04 -*color13: base06 -*color14: base0F -*color15: base07 +*.color0: #000000 +*.color1: #cd0000 +*.color2: #00cd00 +*.color3: #cdcd00 +*.color4: #0000cd +*.color5: #cd00cd +*.color6: #00cdcd +*.color7: #e5e5e5 +*.color8: #4d4d4d +*.color9: #ff0000 +*.color10: #00ff00 +*.color11: #ffff00 +*.color12: #0000ff +*.color13: #ff00ff +*.color14: #00ffff +*.color15: #ffffff diff --git a/linux/.Xresources.d/fonts b/linux/.Xresources.d/fonts @@ -1,6 +0,0 @@ -Xft.autohint: 1 -Xft.lcdfilter: lcddefault -Xft.hintstyle: hintfull -Xft.hinting: 1 -Xft.antialias: 1 -Xft.rgba: rgb diff --git a/linux/.Xresources.d/rxvt-unicode b/linux/.Xresources.d/rxvt-unicode @@ -1,29 +1,18 @@ URxvt*geometry: 80x25 -URxvt.font: xft:Fira Mono:book:pixelsize=12,\ - xft:Font Awesome 5 Brands:pixelsize=12,\ +URxvt.font: xft:Fira Mono:book:pixelsize=11,\ + xft:Font Awesome 5 Brands:pixelsize=11,\ xft:Font Awesome 5 Free -URxvt.boldFont: xft:Fira Mono:bold:pixelsize=12,\ - xft:Font Awesome 5 Brands:pixelsize=12,\ +URxvt.boldFont: xft:Fira Mono:bold:pixelsize=11,\ + xft:Font Awesome 5 Brands:pixelsize=11,\ xft:Font Awesome 5 Free -URxvt.intensityStyles: false +!URxvt.intensityStyles: false URxvt.scrollBar: false URxvt.internalBorder: 10 -URxvt.cursorBlink: true -! Transparency -URxvt.depth: 32 -#define background_opacity 80 +URxvt.cursorBlink: true -! Para clases 480p -!URxvt*font: xft:xos4 Terminus:pixelsize=16:bold -!URxvt*boldFont: xft:xos4 Terminus:pixelsize=16:bold -!URxvt.cursorBlink: true +URxvt.perl-ext-common: resize-font -! Para clases 720p -!URxvt*font: xft:Dejavu Sans Mono:size=13:style=Regular -!URxvt*boldFont: xft:Dejavu Sans Mono:size=13:style=Bold -!URxvt*italicFont: xft:Dejavu Sans Mono:size=13:style=Italic -!URxvt*boldItalicFont: xft:Dejavu Sans Mono:size=13:style=Bold Italic -!URxvt.cursorBlink: true +URxvt.depth: 32 diff --git a/linux/.compton.conf b/linux/.compton.conf @@ -1,49 +0,0 @@ -# Shadow -shadow = true; -no-dnd-shadow = true; -no-dock-shadow = true; -clear-shadow = true; -shadow-radius = 6; -shadow-offset-x = -8; -shadow-offset-y = -8; -shadow-exclude = [ "name = 'Notification'", "class_g = 'Conky'", "class_g ?= 'Notify-osd'", "class_g = 'Cairo-clock'", "x = 0 && y = 0 && override_redirect = true"]; -shadow-ignore-shaped = false; - -# Opacity - -# Fading has been disabled. - -# Other -backend = "xrender" -mark-wmwin-focused = true; -mark-ovredir-focused = true; -# use-ewmh-active-win = true; -detect-rounded-corners = true; -detect-client-opacity = true; -refresh-rate = 0; -vsync = "none"; -dbe = false; -paint-on-overlay = true; -# sw-opti = true; -# unredir-if-possible = true; -# unredir-if-possible-delay = 5000; -# unredir-if-possible-exclude = [ ]; -focus-exclude = [ "class_g = 'Cairo-clock'", "x = 0 && y = 0 && override_redirect = true" ]; -detect-transient = true; -detect-client-leader = true; -invert-color-include = [ ]; -# resize-damage = 1; - -# GLX backend -# glx-no-stencil = true; -glx-copy-from-front = false; -# glx-use-copysubbuffermesa = true; -# glx-no-rebind-pixmap = true; -glx-swap-method = "undefined"; -# glx-use-gpushader4 = true; - -# Window type settings -wintypes: -{ - tooltip = { fade = true; shadow = false; opacity = 0.75; focus = true; }; -}; diff --git a/linux/.config/dunst/dunstrc b/linux/.config/dunst/dunstrc diff --git a/linux/.config/i3/config b/linux/.config/i3/config @@ -1,19 +1,23 @@ -set_from_resource $base00 color0 #000000 -set_from_resource $base01 color10 #000000 -set_from_resource $base02 color11 #000000 -set_from_resource $base03 color8 #000000 -set_from_resource $base04 color12 #000000 -set_from_resource $base05 color7 #000000 -set_from_resource $base06 color13 #000000 -set_from_resource $base07 color15 #000000 -set_from_resource $base08 color1 #000000 -set_from_resource $base09 color9 #000000 -set_from_resource $base0A color3 #000000 -set_from_resource $base0B color2 #000000 -set_from_resource $base0C color6 #000000 -set_from_resource $base0D color4 #000000 -set_from_resource $base0E color5 #000000 -set_from_resource $base0F color14 #000000 +set_from_resource $black color0 #000000 +set_from_resource $red3 color1 #cd0000 +set_from_resource $green3 color2 #00cd00 +set_from_resource $yellow3 color3 #cdcd00 +set_from_resource $blue3 color4 #0000cd +set_from_resource $magenta3 color5 #cd00cd +set_from_resource $cyan3 color6 #00cdcd +set_from_resource $gray90 color7 #e5e5e5 +set_from_resource $gray30 color8 #4d4d4d +set_from_resource $red color9 #ff0000 +set_from_resource $green color10 #00ff00 +set_from_resource $yellow color11 #ffff00 +set_from_resource $blue color12 #0000ff +set_from_resource $magenta color13 #ff00ff +set_from_resource $cyan color14 #00ffff +set_from_resource $white color15 #ffffff +set_from_resource $fg0 i3wm.fg0 #000000 +set_from_resource $fg1 i3wm.fg1 #4d4d4d +set_from_resource $bg0 i3wm.bg0 #ffffff +set_from_resource $bg1 i3wm.bg1 #e5e5e5 set $mod Mod4 @@ -33,8 +37,11 @@ bindsym $mod+Return exec i3-sensible-terminal # kill focused window bindsym $mod+Shift+q kill -# start dmenu (a program launcher) -bindsym $mod+d exec dmenu_run -fn 'Fira Mono-9' -nb '$base01' -nf '$base03' -sb '$base02' -sf '$base01' -i -p ' RUN ' +# start rofi (a program launcher) +bindsym $mod+d exec --no-startup-id "rofi -show run" +bindsym $mod+Shift+d exec --no-startup-id "rofi -show drun" +bindsym $mod+n exec --no-startup-id "rofi -show window" +bindsym $mod+p exec --no-startup-id "rofi -show window" # change focus bindsym $mod+j focus left @@ -56,12 +63,6 @@ bindsym $mod+Shift+l move up bindsym $mod+Shift+semicolon move right bindsym $mod+Shift+ntilde move right -# alternatively, you can use the cursor keys: -bindsym $mod+Shift+Left move left -bindsym $mod+Shift+Down move down -bindsym $mod+Shift+Up move up -bindsym $mod+Shift+Right move right - # split in horizontal orientation bindsym $mod+h split h @@ -114,10 +115,13 @@ bindsym $mod+Shift+0 move container to workspace 10 # reload the configuration file bindsym $mod+Shift+c reload + # restart i3 inplace (preserves your layout/session, can be used to upgrade i3) 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'" + # resize window (you can also use the mouse for that) mode "resize" { # These bindings trigger as soon as you enter the resize mode @@ -132,12 +136,6 @@ mode "resize" { bindsym semicolon resize grow width 10 px or 10 ppt bindsym ntilde resize grow width 10 px or 10 ppt - # same bindings, but for the arrow keys - bindsym Left resize shrink width 10 px or 10 ppt - bindsym Down resize grow height 10 px or 10 ppt - bindsym Up resize shrink height 10 px or 10 ppt - bindsym Right resize grow width 10 px or 10 ppt - # back to normal: Enter or Escape bindsym Return mode "default" bindsym Escape mode "default" @@ -145,26 +143,23 @@ mode "resize" { bindsym $mod+r mode "resize" -# Property Name Border BG Text Indicator Child Border -client.focused $base05 $base0D $base00 $base0D $base0D -client.focused_inactive $base01 $base01 $base05 $base03 $base01 -client.unfocused $base01 $base00 $base05 $base01 $base01 -client.urgent $base08 $base08 $base00 $base08 $base08 -client.placeholder $base00 $base00 $base05 $base00 $base00 -client.background $base07 +# class border backgr. text indicator child_border +client.focused $fg0 $bg0 $fg0 $green $fg0 +client.focused_inactive $bg1 $bg0 $fg1 $green $bg1 +client.unfocused $bg1 $bg0 $bg1 $green $bg1 +client.urgent $red $bg0 $red $green $red +client.placeholder $000000 $blue $blue $000000 $blue +client.background $magenta # Pulse Audio controls -bindsym XF86AudioRaiseVolume exec --no-startup-id pactl set-sink-volume 0 +10% #increase sound volume -bindsym XF86AudioLowerVolume exec --no-startup-id pactl set-sink-volume 0 -10% #decrease sound volume -bindsym XF86AudioMute exec --no-startup-id pactl set-sink-mute 0 toggle # mute sound +bindsym XF86AudioRaiseVolume exec --no-startup-id pactl set-sink-volume 0 +5% +bindsym XF86AudioLowerVolume exec --no-startup-id pactl set-sink-volume 0 -5% +bindsym XF86AudioMute exec --no-startup-id pactl set-sink-mute 0 toggle -# Sreen brightness controls +# Screen brightness controls bindsym XF86MonBrightnessUp exec xbacklight -inc 5 # increase screen brightness bindsym XF86MonBrightnessDown exec xbacklight -dec 5 # decrease screen brightness -# Touchpad controls -bindsym XF86TouchpadToggle exec /some/path/toggletouchpad.sh # toggle touchpad - # Media player controls bindsym XF86AudioPlay exec playerctl play bindsym XF86AudioPause exec playerctl pause @@ -173,5 +168,6 @@ bindsym XF86AudioPrev exec playerctl previous new_window pixel 2 new_float pixel 2 +gaps vertical 6 +gaps horizontal 43 gaps inner 8 -gaps outer 8 diff --git a/linux/.config/picom/picom.conf b/linux/.config/picom/picom.conf @@ -0,0 +1,17 @@ +shadow = true; + +shadow-offset-x = -10; +shadow-offset-y = -10; +shadow-radius = 10; + +shadow-exclude = [ + "class_g = 'i3-frame'", + "class_g = 'zoom'", + "name = 'cpt_frame_window'" +] + +opacity-rule = [ + "95:class_g = 'URxvt' && focused", + "60:class_g = 'URxvt' && !focused", + "70:class_g = 'Zathura' && !focused", +]; diff --git a/linux/.config/polybar/config b/linux/.config/polybar/config @@ -1,20 +1,33 @@ [colors] -base00 = ${xrdb:color0:#000000} -base01 = ${xrdb:color10:#000000} -base02 = ${xrdb:color11:#000000} -base03 = ${xrdb:color8:#000000} -base04 = ${xrdb:color12:#000000} -base05 = ${xrdb:color7:#000000} -base06 = ${xrdb:color13:#000000} -base07 = ${xrdb:color15:#000000} -base08 = ${xrdb:color1:#000000} -base09 = ${xrdb:color9:#000000} -base0A = ${xrdb:color3:#000000} -base0B = ${xrdb:color2:#000000} -base0C = ${xrdb:color6:#000000} -base0D = ${xrdb:color4:#000000} -base0E = ${xrdb:color5:#000000} -base0F = ${xrdb:color14:#000000} +fg0 = ${xrdb:i3wm.fg0:#000000} +fg1 = ${xrdb:i3wm.fg1:#4d4d4d} +bg0 = ${xrdb:i3wm.bg0:#ffffff} +bg1 = ${xrdb:i3wm.bg1:#e5e5e5} + +black = ${xrdb:color0:#000000} +red3 = ${xrdb:color1:#cd0000} +green3 = ${xrdb:color2:#00cd00} +yellow3 = ${xrdb:color3:#cdcd00} +blue3 = ${xrdb:color4:#0000cd} +magenta3 = ${xrdb:color5:#cd00cd} +cyan3 = ${xrdb:color6:#00cdcd} +gray90 = ${xrdb:color7:#e5e5e5} +gray30 = ${xrdb:color8:#4d4d4d} +red = ${xrdb:color9:#ff0000} +green = ${xrdb:color10:#00ff00} +yellow = ${xrdb:color11:#ffff00} +blue = ${xrdb:color12:#0000ff} +magenta = ${xrdb:color13:#ff00ff} +cyan = ${xrdb:color14:#00ffff} +white = ${xrdb:color15:#ffffff} + +primary = ${xrdb:color1:#cd0000} +secondary = ${xrdb:color2:#00cd00} +alert = ${xrdb:color3:#cdcd00} + +[bar/bar] +background = ${colors.bg0} +foreground = ${colors.fg1} [bar/base] width = 100% @@ -32,9 +45,6 @@ font-1 = FontAwesome5Free:style=Solid:pixelsize=9;1 font-2 = FontAwesome5Brands:style=Solid:pixelsize=9;1 font-3 = Dejavu:pixelsize=13;3 -background = ${colors.base00} -foreground = ${colors.base05} - scroll-up = i3wm-wsnext scroll-down = i3wm-wsprev @@ -42,20 +52,20 @@ scroll-down = i3wm-wsprev inherit = bar/base padding-left = 0 modules-left = i3 xwindow -modules-right = backlight volume date +modules-right = xkeyboard battery backlight volume date [bar/bottom] inherit = bar/base bottom = true tray-position = right tray-margin-right = 5 -modules-left = cpu memory -modules-right = network +modules-left = cpu memory filesystem +modules-right = uptime network [module/xwindow] type = internal/xwindow label = %title% -label-maxlen = 120 +label-maxlen = 90 [module/i3] type = internal/i3 @@ -63,45 +73,34 @@ format = <label-state> <label-mode> index-sort = true wrapping-scroll = false -; Only show workspaces on the same output as the bar -;pin-workspaces = true - -ws-icon-0 = 1;ο„  -ws-icon-1 = 2; -ws-icon-2 = 3;ο„‘ -ws-icon-3 = 4; -ws-icon-4 = 5; -ws-icon-5 = 6;ο…Ύ - label-mode-padding = 1 -label-mode-foreground = ${colors.base05} -label-mode-background = ${colors.base01} -label-mode-underline = ${colors.base09} +label-mode-foreground = ${colors.fg0} +label-mode-background = ${colors.red3} ; focused = Active workspace on focused monitor -label-focused = %icon% %index% -label-focused-foreground = ${colors.base05} -label-focused-background = ${colors.base01} -label-focused-underline = ${colors.base0B} +label-focused = %index% +label-focused-foreground = ${colors.fg0} +label-focused-background = ${colors.bg1} +label-focused-underline = ${colors.yellow3} label-focused-padding = 1 ; unfocused = Inactive workspace on any monitor -label-unfocused = %icon% %index% +label-unfocused = %index% label-unfocused-padding = 1 -label-unfocused-foreground = ${colors.base03} -label-unfocused-background = ${colors.base00} +label-unfocused-foreground = ${colors.fg1} +label-unfocused-background = ${colors.bg0} ; visible = Active workspace on unfocused monitor label-visible = %index% -label-visible-foreground = ${colors.base05} -label-visible-background = ${colors.base00} +label-visible-foreground = ${colors.bg1} +label-visible-background = ${colors.bg0} label-visible-padding = ${self.label-focused-padding} ; urgent = Workspace with urgency hint set label-urgent = %index% -label-urgent-foreground = ${colors.base07} -label-urgent-background = ${colors.base03} -label-urgent-underline = ${colors.base0A} +label-urgent-foreground = ${colors.fg0} +label-urgent-background = ${colors.yellow3} +label-urgent-underline = ${colors.green3} label-urgent-padding = 1 [module/date] @@ -117,25 +116,27 @@ label = %date% %time% [module/volume] type = internal/pulseaudio +sink = alsa_output.pci-0000_00_1b.0.analog-stereo + format-volume = "<label-volume> <bar-volume>" label-volume =  %percentage:2%% format-muted-prefix = " " -format-muted-prefix-foreground = ${colors.base03} +format-muted-prefix-foreground = ${colors.fg1} label-muted = "AUDIO MUTE" -label-muted-foreground = ${colors.base03} +label-muted-foreground = ${colors.bg1} bar-volume-width = 11 -bar-volume-foreground-0 = ${colors.base0B} -bar-volume-foreground-1 = ${colors.base0B} -bar-volume-foreground-2 = ${colors.base0B} -bar-volume-foreground-3 = ${colors.base0B} -bar-volume-foreground-4 = ${colors.base0A} -bar-volume-foreground-5 = ${colors.base0A} -bar-volume-foreground-6 = ${colors.base09} -bar-volume-foreground-7 = ${colors.base09} -bar-volume-foreground-8 = ${colors.base08} -bar-volume-foreground-9 = ${colors.base08} +bar-volume-foreground-0 = ${colors.green3} +bar-volume-foreground-1 = ${colors.green3} +bar-volume-foreground-2 = ${colors.green3} +bar-volume-foreground-3 = ${colors.green3} +bar-volume-foreground-4 = ${colors.yellow3} +bar-volume-foreground-5 = ${colors.yellow3} +bar-volume-foreground-6 = ${colors.yellow3} +bar-volume-foreground-7 = ${colors.yellow3} +bar-volume-foreground-8 = ${colors.red3} +bar-volume-foreground-9 = ${colors.red3} bar-volume-gradient = true bar-volume-indicator = ● bar-volume-indicator-font = 2 @@ -143,30 +144,30 @@ bar-volume-fill = ─ bar-volume-fill-font = 2 bar-volume-empty = ─ bar-volume-empty-font = 2 -bar-volume-empty-foreground = ${colors.base03} +bar-volume-empty-foreground = ${colors.fg1} [module/network] type = internal/network interface = wlp9s0 - + format-connected = <label-connected> <ramp-signal> - + format-disconnected = offline ο–΄ -format-disconnected-foreground = ${colors.base03} +format-disconnected-foreground = ${colors.bg1} ramp-signal-0 = 😱 -ramp-signal-0-foreground = ${colors.base08} +ramp-signal-0-foreground = ${colors.red3} ramp-signal-1 = 😠 -ramp-signal-1-foreground = ${colors.base0A} +ramp-signal-1-foreground = ${colors.yellow3} ramp-signal-2 = πŸ˜’ -ramp-signal-2-foreground = ${colors.base0A} +ramp-signal-2-foreground = ${colors.yellow3} ramp-signal-3 = 😊 -ramp-signal-3-foreground = ${colors.base0B} +ramp-signal-3-foreground = ${colors.green3} ramp-signal-4 = πŸ˜ƒ -ramp-signal-4-foreground = ${colors.base0B} +ramp-signal-4-foreground = ${colors.green3} ramp-signal-5 = 😈 -ramp-signal-5-foreground = ${colors.base0B} - +ramp-signal-5-foreground = ${colors.green3} + label-connected = %local_ip%  %essid% %downspeed:8% ο€™ %upspeed:8% ο‚“ [module/cpu] @@ -174,51 +175,104 @@ type = internal/cpu interval = 0.5 format = <label> <ramp-coreload> label = CPU %percentage:2%% - + ramp-coreload-0 = ▁ -ramp-coreload-0-foreground = ${colors.base0B} +ramp-coreload-0-foreground = ${colors.green3} ramp-coreload-1 = β–‚ -ramp-coreload-1-foreground = ${colors.base0B} +ramp-coreload-1-foreground = ${colors.green3} ramp-coreload-2 = β–ƒ -ramp-coreload-2-foreground = ${colors.base0B} +ramp-coreload-2-foreground = ${colors.green3} ramp-coreload-3 = β–„ -ramp-coreload-3-foreground = ${colors.base0A} +ramp-coreload-3-foreground = ${colors.yellow3} ramp-coreload-4 = β–… -ramp-coreload-4-foreground = ${colors.base0A} +ramp-coreload-4-foreground = ${colors.yellow3} ramp-coreload-5 = β–† -ramp-coreload-5-foreground = ${colors.base09} +ramp-coreload-5-foreground = ${colors.red3} ramp-coreload-6 = β–‡ -ramp-coreload-6-foreground = ${colors.base09} +ramp-coreload-6-foreground = ${colors.red3} ramp-coreload-7 = β–ˆ -ramp-coreload-7-foreground = ${colors.base08} +ramp-coreload-7-foreground = ${colors.red3} [module/memory] type = internal/memory format = <label> <bar-used> interval = 3 label = RAM %gb_used%/%gb_free% - + bar-used-indicator = -bar-used-width = 25 -bar-used-foreground-0 = ${colors.base0B} -bar-used-foreground-1 = ${colors.base0B} -bar-used-foreground-2 = ${colors.base0A} -bar-used-foreground-3 = ${colors.base08} +bar-used-width = 15 +bar-used-foreground-0 = ${colors.green3} +bar-used-foreground-1 = ${colors.green3} +bar-used-foreground-2 = ${colors.yellow3} +bar-used-foreground-3 = ${colors.yellow3} +bar-used-foreground-4 = ${colors.red3} bar-used-fill = ▐ bar-used-empty = ▐ -bar-used-empty-foreground = ${colors.base02} +bar-used-empty-foreground = ${colors.fg1} [module/backlight] type = internal/xbacklight output = eDP1 format = <label> <ramp> - + ramp-0 = πŸŒ• ramp-1 = πŸŒ” ramp-2 = πŸŒ“ ramp-3 = πŸŒ’ ramp-4 = πŸŒ‘ +[module/battery] +type = internal/battery + +full-at = 97 + +battery = BAT1 +adapter = ACAD + +poll-interval = 10 + +time-format = %H:%M + +format-charging = <ramp-capacity> <label-charging> +format-discharging = <ramp-capacity> <label-discharging> +format-full = <ramp-capacity> <label-full> +label-charging = %percentage_raw%%/%time% +label-discharging = %percentage_raw%%/%time% +label-full = %percentage_raw%% + +; Only applies if <ramp-capacity> is used +ramp-capacity-0 =  +ramp-capacity-0-foreground = ${colors.red3} +ramp-capacity-1 =  +ramp-capacity-1-foreground = ${colors.yellow3} +ramp-capacity-2 =  +ramp-capacity-2-foreground = ${colors.yellow3} +ramp-capacity-3 =  +ramp-capacity-3-foreground = ${colors.yellow3} +ramp-capacity-4 =  +ramp-capacity-4-foreground = ${colors.green3} + + +[module/filesystem] +type = internal/fs + +mount-0 = / +mount-1 = /home + +interval = 10 +fixed-values = true +spacing = 2 +label-mounted = %mountpoint%(%used%/%free%) + +[module/xkeyboard] +type = internal/xkeyboard + +[module/uptime] +type = custom/script +exec = uptime | sed -r "s/^.*up (.*), [0-9]* user.*$/\1/" | sed -r "s/ / /" +interval = 100 +label = UP %output% + [settings] screenchange-reload = true @@ -226,4 +280,5 @@ screenchange-reload = true margin-top = 0 margin-bottom = 0 + ; vim:ft=dosini diff --git a/linux/.config/rofi/config.rasi b/linux/.config/rofi/config.rasi @@ -0,0 +1,98 @@ +configuration { + modi: "window,drun,ssh,combi"; + font: "Fira Mono 9"; + combi-modi: "window,drun,ssh"; + kb-row-down: "Super+n"; + kb-row-up: "Super+p"; +} + +* { + black: #000000; + red: #cd0000; + green: #00cd00; + yellow: #cdcd00; + blue: #0000cd; + mangenta: #cd00cd; + cyan: #00cdcd; + fg0: #ffffff; + fg1: #e5e5e5; + bg0: #000000; + bg1: #4d4d4d; + + spacing: 0; + + background-color: transparent; + text-color: @red; +} + +window { + background-color: #000000ee; + border: 1; + border-color: #ffffff; + padding: 5; +} + +mainbox { + border: 0; + padding: 0; +} + +inputbar { + margin: 0px 0px 5px 0px; + children: [prompt, textbox-prompt-colon, entry, case-indicator]; +} + +prompt { + text-color: @fg0; +} + +textbox-prompt-colon { + expand: false; + str: ":"; + text-color: @bg1; +} + +entry { + margin: 0px 5px; + text-color: #e5e5e5; +} + +listview { + spacing: 1px; + dynamic: true; + scrollbar: false; +} + +element { + padding: 1px; + text-color: @bg1; + highlight: bold #00cd00; + border-radius: 3px; +} + +element selected { + background-color: @bg1; + text-color: @fg0; +} + +element urgent, element selected urgent { + text-color: @red; +} + +element active, element selected active { + text-color: @magenta; +} + +message { + padding: 5px; + border-radius: 3px; + background-color: @bg1; + border: 1px; + border-color: @cyan; +} + +button selected { + padding: 5px; + border-radius: 3px; + background-color: @bg1; +} diff --git a/linux/.xinitrc b/linux/.xinitrc @@ -18,14 +18,15 @@ if [ -d /etc/X11/xinit/xinitrc.d ] ; then unset f fi -setxkbmap es +setxkbmap -model pc104 -layout us,es -option grp:ctrls_toggle [[ -d /usr/share/fonts/terminus ]] && xset +fp /usr/share/fonts/terminus -command -v compton >/dev/null 2>&1 && compton -b & -command -v feh >/dev/null 2>&1 && feh --bg-scale $HOME/.wallpaper +command -v picom >/dev/null 2>&1 && picom -bc & +#command -v feh >/dev/null 2>&1 && feh --bg-scale $HOME/.wallpaper udiskie & dunst & redshift & xset -b +hsetroot -solid gray95 session=${1:-i3}