dgy
/
hexagons
Archived
1
0
Fork 0

i dyed my hair and got a haircut

This commit is contained in:
CadaverLab 2018-05-26 17:06:45 -03:00
parent d7cf976c85
commit 90bb74f768
40 changed files with 4594 additions and 2468 deletions

View File

@ -37,7 +37,7 @@
!SXIV COLORS
sxiv.font: ibmplexsans:size=9
sxiv.font: monaco:size=9
sxiv.win_bg_color: #080808
sxiv.win_fs_color: #050505
sxiv.sel_color: #2E2E2C

View File

@ -1,6 +1,6 @@
hsetroot -fill /home/deadguy/Pictures/wallpaper/doitlive.png &
hsetroot -fill /home/deadguy/Pictures/wallpaper/keepcalm.png &
xsetroot -cursor_name left_ptr &
compton -b &
#compton -b &
sleep 2s
redshift -c ~/.config/redshift/redshift.conf &
dunst -conf ~/.config/dunst/dunstrc &

View File

@ -1,4 +1,4 @@
#! /bin/sh
#!/bin/zsh
#bspc monitor LVDS1 -d 1 2 3 4 5 6 7 8 9 10
@ -35,11 +35,16 @@ bspc config pointer_action2 resize_corner
bspc config pointer_action3 move
bspc config split_ratio 0.45
# xrdb
function get_xrdb() {
xrdb -query | grep "$1" | awk '{print $2}' | tail -n1
}
xrdb -merge "${HOME}/.Xresources"
# Colors
bspc config normal_border_color "#121212"
bspc config focused_border_color "#FEFEFE"
bspc config active_border_color "#7cb342"
bspc config presel_feedback_color "#26c6da"
bspc config normal_border_color "$(get_xrdb color0)"
bspc config focused_border_color "$(get_xrdb color3)"
bspc config active_border_color "$(get_xrdb color10)"
bspc config border_width $b_width
# Attempt at managing multihead
@ -47,8 +52,8 @@ workspaces_multimonitor &
# Floaters
bspc rule -a Lxappearance state=floating
bspc rule -a Vlc state=floating
bspc rule -a REAPER state=floating
bspc rule -a vlc state=floating
bspc rule -a REAPER state=floating, layer=below
bspc rule -a Sol state=floating
bspc rule -a Pavucontrol state=floating
bspc rule -a qsynth state=floating
@ -64,10 +69,12 @@ bspc rule -a obs state=floating
bspc rule -a Pd-l2ork state=floating
bspc rule -a PdWindow state=floating
bspc rule -a PatchWindow state=floating
bspc rule -a Nm-connection-editor state=floating
bspc rule -a Godot state=floating
# Others
bspc rule -a Zathura state=tiled
bspc rule -a Oblogout state=fullscreen
bspc rule -a Oblogout manage=off
# Run in place
bspc rule -a Termite desktop=^1
@ -80,6 +87,6 @@ export _JAVA_OPTIONS='-Dsun.java2d.opengl=true'
# External rules
bspc config external_rules_command `$HOME/.config/bspwm/external_rules.sh`
2bspwm &
#2bspwm &
. $HOME/.config/bspwm/autostart

View File

@ -1,10 +1,10 @@
[global]
font = Ibm Plex Sans 9
font = IBM Plex Sans 9
markup = full
format = "%s\n%b"
format = "%s \n%b"
sort = yes # Sort messages by urgency.
indicate_hidden = no # Show how many messages are hidden.
#alignment = left # Message alignment: "left" "center" "right".
alignment = right # Message alignment: "left" "center" "right".
bounce_freq = 0 # Always set to 0
show_age_threshold = -1
word_wrap = yes # Split into multiple lines
@ -22,7 +22,7 @@
# the top and down respectively.
# The width can be negative. In this case the actual width is the
# screen width minus the width defined in within the geometry option.
geometry = "400x8+10+31"
geometry = "400x8-10+31"
title = Dunst # Define window title
class = Dunst # Define window class
@ -60,8 +60,8 @@
startup_notification = false
dmenu = /usr/bin/dmenu -p dunst:
browser = /usr/bin/firefox -new-tab
icon_position = left # Align icons left/right/off
max_icon_size = 0
icon_position = right # Align icons left/right/off
max_icon_size = 64
# Paths to default icons.
icon_path = /usr/share/icons/Papirus-Dark/16x16@2x/apps/:/usr/share/icons/Papirus-Dark/16x16@2x/categories/:/usr/share/icons/Papirus-Dark/16x16@2x/devices/:/usr/share/icons/Papirus-Dark/16x16@2x/emblems/:/usr/share/icons/Papirus-Dark/16x16@2x/mimetypes/:/usr/share/icons/Papirus-Dark/16x16@2x/places/:/usr/share/icons/Papirus-Dark/16x16@2x/status/
@ -85,14 +85,14 @@
[urgency_normal]
background = "#101010"
foreground = "#e8d0c0"
frame_color = "#215d9c"
foreground = "#e0d0c3"
frame_color = "#c4a000"
timeout = 10
[urgency_critical]
background = "#fb4245"
foreground = "#131313"
frame_color = "#ff6c5f"
frame_color = "#e53935"
timeout = 60
# vim: ft=cfg

View File

@ -1,8 +0,0 @@
<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
<fontconfig>
<!-- You are supposed to remove all the lines but the one(s) where the font is used in your terminal -->
<!-- Only monospaced fonts have been listed here -->
<!-- If your font isn't in the list, uncomment the next line and write its name -->
<alias><family>monaco</family><default><family>icons-in-terminal</family></default></alias>
</fontconfig>

View File

@ -17,6 +17,10 @@ VteTerminal, vte-terminal {
padding: 10px;
}
.termite {
padding: 0 8px;
}
headerbar.default-decoration {
padding-top: 0;
padding-bottom: 0;

View File

@ -5,23 +5,11 @@
# - Add ``needsterminal`` for commands that use the terminal
# - Add ``copiousoutput`` for commands that dump text to stdout
# Note that rtv returns a list of urls for imgur albums, so we don't put quotes
# around the `%s`
image/gif; mpv '%s' --autofit 640x480 --loop=inf; test=test -n "$DISPLAY"
image/*; %s | imv -; test=test -n "$DISPLAY"
# Youtube videos are assigned a custom mime-type, which can be streamed with
# vlc or youtube-dl.
video/x-youtube; mpv --ytdl-format=best '%s' --autofit 640x480; test=test -n "$DISPLAY"
# Mpv is a simple and effective video streamer
video/*; mpv '%s' --autofit 640x480 --loop=inf; test=test -n "$DISPLAY"
# Use zathura for pdfs
application/pdf; zathura '%s'; test=test -n "$DISPLAY"
# Abiword for MS Word docs
application/msword; abiword '%s'; test=test -n "$DISPLAY"
image/gif; sxiv-gif %s; test=test -n "$DISPLAY"
image/*; sxiv %s; test=test -n "$DISPLAY"
video/*; mpv %s; test=test -n "$DISPLAY"
application/pdf; zathura %s; test=test -n "$DISPLAY"
application/msword; abiword %s; test=test -n "$DISPLAY"
# Autoview html
text/html; "$BROWSER" %s; test=test -n "$DISPLAY"; needsterminal;

71
.config/mutt/etc/muttcol Normal file
View File

@ -0,0 +1,71 @@
# vim: filetype=neomuttrc
# Default index colors:
color index yellow default '.*'
color index_author red default '.*'
color index_number blue default
color index_subject cyan default '.*'
# For new mail:
color index brightyellow black "~N"
color index_author brightred black "~N"
color index_subject brightcyan black "~N"
# Header colors:
color header blue default ".*"
color header brightmagenta default "^(From)"
color header brightcyan default "^(Subject)"
color header brightwhite default "^(CC|BCC)"
mono bold bold
mono underline underline
mono indicator reverse
mono error bold
color normal default default
color indicator brightblack white
color sidebar_highlight red default
color sidebar_divider color8 black
color sidebar_flagged red black
color sidebar_new green black
color normal brightyellow default
color error red default
color tilde black default
color message cyan default
color markers red white
color attachment white default
color search brightmagenta default
color status brightyellow black
color hdrdefault brightgreen default
color quoted green default
color quoted1 blue default
color quoted2 cyan default
color quoted3 yellow default
color quoted4 red default
color quoted5 brightred default
color signature brightgreen default
color bold black default
color underline black default
color normal default default
color body brightred default "[\-\.+_a-zA-Z0-9]+@[\-\.a-zA-Z0-9]+" # Email addresses
color body brightblue default "(https?|ftp)://[\-\.,/%~_:?&=\#a-zA-Z0-9]+" # URL
color body green default "\`[^\`]*\`" # Green text between ` and `
color body brightblue default "^# \.*" # Headings as bold blue
color body brightcyan default "^## \.*" # Subheadings as bold cyan
color body brightgreen default "^### \.*" # Subsubheadings as bold green
color body yellow default "^(\t| )*(-|\\*) \.*" # List items as yellow
color body brightcyan default "[;:][-o][)/(|]" # emoticons
color body brightcyan default "[;:][)(|]" # emoticons
color body brightcyan default "[*]?((N)?ACK|CU|LOL|SCNR|BRB|BTW|CWYL|\
|FWIW|vbg|GD&R|HTH|HTHBE|IMHO|IMNSHO|\
|IRL|RTFM|ROTFL|ROFL|YMMV)[*]?"
color body brightcyan default "[ ][*][^*]*[*][ ]?" # more emoticon?
color body brightcyan default "[ ]?[*][^*]*[*][ ]" # more emoticon?
color body red default "(BAD signature)"
color body cyan default "(Good signature)"
color body brightblack default "^gpg: Good signature .*"
color body brightyellow default "^gpg: "
color body brightyellow red "^gpg: BAD signature from.*"
mono body bold "^gpg: Good signature"
mono body bold "^gpg: BAD signature from.*"
color body red default "([a-z][a-z0-9+-]*://(((([a-z0-9_.!~*'();:&=+$,-]|%[0-9a-f][0-9a-f])*@)?((([a-z0-9]([a-z0-9-]*[a-z0-9])?)\\.)*([a-z]([a-z0-9-]*[a-z0-9])?)\\.?|[0-9]+\\.[0-9]+\\.[0-9]+\\.[0-9]+)(:[0-9]+)?)|([a-z0-9_.!~*'()$,;:@&=+-]|%[0-9a-f][0-9a-f])+)(/([a-z0-9_.!~*'():@&=+$,-]|%[0-9a-f][0-9a-f])*(;([a-z0-9_.!~*'():@&=+$,-]|%[0-9a-f][0-9a-f])*)*(/([a-z0-9_.!~*'():@&=+$,-]|%[0-9a-f][0-9a-f])*(;([a-z0-9_.!~*'():@&=+$,-]|%[0-9a-f][0-9a-f])*)*)*)?(\\?([a-z0-9_.!~*'();/?:@&=+$,-]|%[0-9a-f][0-9a-f])*)?(#([a-z0-9_.!~*'();/?:@&=+$,-]|%[0-9a-f][0-9a-f])*)?|(www|ftp)\\.(([a-z0-9]([a-z0-9-]*[a-z0-9])?)\\.)*([a-z]([a-z0-9-]*[a-z0-9])?)\\.?(:[0-9]+)?(/([-a-z0-9_.!~*'():@&=+$,]|%[0-9a-f][0-9a-f])*(;([-a-z0-9_.!~*'():@&=+$,]|%[0-9a-f][0-9a-f])*)*(/([-a-z0-9_.!~*'():@&=+$,]|%[0-9a-f][0-9a-f])*(;([-a-z0-9_.!~*'():@&=+$,]|%[0-9a-f][0-9a-f])*)*)*)?(\\?([-a-z0-9_.!~*'();/?:@&=+$,]|%[0-9a-f][0-9a-f])*)?(#([-a-z0-9_.!~*'();/?:@&=+$,]|%[0-9a-f][0-9a-f])*)?)[^].,:;!)? \t\r\n<>\"]"

150
.config/mutt/muttrc Normal file
View File

@ -0,0 +1,150 @@
# vim: filetype=neomuttrc
# This is the general mutt config which has the settings that all accounts use.
bind index,pager i noop
bind index,pager g noop
bind index \Cf noop
source etc/muttcol
source etc/aliases
source ~/.config/mutt/gpg.rc
# Config -----------------------------------------
set sleep_time = 0
set editor = $EDITOR
set timeout = "5"
set mail_check = "7200"
set mailcap_path = ~/.config/mutt/etc/mailcap
set date_format ="%a %d %b"
set index_format ="%2C %Z %?X?A& ? %D %-45.45F %s (%-4.4c)"
set alias_format = " %4n %t %-20a %r "
set markers = no
set mark_old = no
set mime_forward = yes
set smtp_authenticators = 'gssapi:login'
auto_view text/html
auto_view application/pdf
alternative_order text/plain text/enriched text/html
set rfc2047_parameters = yes
set pipe_decode
set thorough_search
set send_charset="utf-8"
set check_new = yes
set smart_wrap = yes
set allow_ansi = yes
set quote_regexp = "^( {0,4}[>|:#%]| {0,4}[a-z0-9]+[>|]+)+"
# "from" field gets 30% of remaining space, "subject" gets 70%. Remaining space is the total width minus the other fields
set my_index_format_pre='set my_col_from = `echo $((30 * ($(tput cols)-50) / 100))`; set my_col_subject = `echo $((70 * ($(tput cols)-50) / 100))`; set index_format="%2C %Z %D %-$my_col_from.${my_col_from}'
set my_index_format_post=' %-4.4c %?M?<%M ?%-$my_col_subject.${my_col_subject}s"'
folder-hook .*[sS]ent.* "$my_index_format_pre"t"$my_index_format_post"
folder-hook ! .*[sS]ent.* "$my_index_format_pre"F"$my_index_format_post"
# Index Options -----------------------------------------
set sort = threads # like gmail
set sort_aux = reverse-last-date-received # like gmail
set uncollapse_jump # don't collapse on an unread message
set sort_re # thread based on regex
set reply_regexp = "^(([Rr][Ee]?(\[[0-9]+\])?: *)?(\[[^]]+\] *)?)*"
# Header Options -------------------------------------
set hdrs
ignore "Authentication-Results:"
ignore "DomainKey-Signature:"
ignore "DKIM-Signature:"
unignore from: to: cc: date: subject: # show only these
unhdr_order * # some distros order things by default
hdr_order date: from: to: date: subject: cc: # and in this order
unignore x-mailing-list: posted-to:
unignore x-mailer:
# Status Bar -----------------------------------------
set status_chars = " *%A"
set status_format = "──┄┄╼ %f: %m Messages ╾┄┄──────────┈%?n? %n New?%?d?, %d to Delete?%?t?, %t Tagged?%?p?, %p Postponed?%?l? %l Total ?┈───%>─┤ %P ├───"
color status magenta default
# Composing Mail -------------------------------------
set envelope_from # which from?
set fast_reply # skip to compose when replying
set sendmail_wait = 1 # wait for sending... to complete
#set askcc # ask for CC:
set attribution = "El %d, %n escribio:" # set the attribution
set reply_to # reply to Reply to: field
set skip_quoted_offset = 3
# General remappings
bind editor <space> noop
bind index G last-entry
bind index gg first-entry
bind pager gg top
bind pager <up> previous-line
bind pager <down> next-line
bind pager G bottom
bind pager <left> previous-undeleted
bind pager <right> next-undeleted
bind index D half-down
bind index U half-up
bind index d delete-message
bind index u undelete-message
bind index F search
bind index,pager R group-reply
bind index <left> previous-unread
bind index <right> next-unread
bind index,pager R group-reply
macro index,pager S '<sync-mailbox>
macro index,pager \Cu |urlview\n
# View attachments properly.
bind attach <return> view-mailcap
set fast_reply # skip to compose when replying
set fcc_attach # save attachments with the body
unset mime_forward # forward attachments as part of body
set forward_format = "Fwd: %s" # format of subject when forwarding
set forward_decode # decode when forwarding
set forward_quote # include message in forwards
set reverse_name # reply as whomever it was to
set include # include message in replies
#Ctrl-R to mark all as read
macro index \Cr "T~U<enter><tag-prefix><clear-flag>N<untag-pattern>.<enter>" "mark all messages as read"
#sync email
macro index O "<shell-escape>offlineimap<enter>" "run offlineimap to sync all mail"
macro index o "<shell-escape>offlineimap -qf INBOX<enter>" "run offlineimap to sync inbox"
#copy/move dialogs
macro index C "<copy-message>?<toggle-mailboxes>" "copy a message to a mailbox"
macro index M "<save-message>?<toggle-mailboxes>" "move a message to a mailbox"
# Notmuch searching
macro index \Cf "<enter-command>unset wait_key<enter><shell-escape>read -p 'notmuch query: ' x; echo \$x >~/.cache/mutt_terms<enter><limit>~i \"\`notmuch search --output=messages \$(cat ~/.cache/mutt_terms) | head -n 600 | perl -le '@a=<>;chomp@a;s/\^id:// for@a;$,=\"|\";print@a'\`\"<enter>" "show only messages matching a notmuch pattern"
macro index A "<limit>all\n" "show all messages (undo limit)"
# Sidebar mappings
set sidebar_visible = yes
set sidebar_width = 20
set sidebar_short_path = yes
set sidebar_next_new_wrap = yes
set mail_check_stats
set sidebar_format = '%B%?F? [%F]?%* %?N?%N/? %?S?%S?'
bind index,pager k sidebar-prev
bind index,pager j sidebar-next
bind index,pager l sidebar-open
bind index,pager \Cp sidebar-prev-new
bind index,pager \Cn sidebar-next-new
bind index,pager B sidebar-toggle-visible
macro index,pager \CL "<enter-command>$my_index_format_pre"F"$my_index_format_post<enter><redraw-screen>"
macro attach 'V' "<pipe-entry>cat >~/.cache/mutt/mail.html && $BROWSER ~/.cache/mutt/mail.html && rm ~/.cache/mutt/mail.html<enter>"
macro index,pager U "<enter-command>set pipe_decode = yes<enter><pipe-message>urlview<enter><enter-command>set pipe_decode = no<enter>""view URLs"
macro index,pager \cb "<enter-command> set my_pdsave=\$pipe_decode<enter>\
<enter-command> unset pipe_decode<enter>\
<pipe-message>extract_url<enter>\
<enter-command> set pipe_decode=\$my_pdsave<enter>" "get URLs"
source personal.muttrc

View File

@ -11,8 +11,8 @@ setl updatetime=2000
" Makes autocompletion for references nice
set iskeyword+=:
set iskeyword+=-:
set iskeyword+=_:
"set iskeyword+=-:
"set iskeyword+=_:
" .tex files always interpreted as latex and not plain tex
let g:tex_flavor='latex'
@ -40,7 +40,7 @@ augroup texsave
autocmd CursorHold,CursorHoldI * silent! wall
augroup END
command Compile normal! :52 split <cr><c-w>j:terminal latexmk %<CR>G
"command Compile normal! :52 split <cr><c-w>j:terminal latexmk %<CR>G
iab enum \begin{enumerate}<CR>\item{}<CR>\end{enumerate}<esc>k0f{a
iab itemz \begin{itemize}<CR>\item{}<CR>\end{itemize}<esc>k0f{a

View File

@ -21,7 +21,6 @@ Plug 'jiangmiao/auto-pairs'
Plug 'zchee/deoplete-jedi'
Plug 'w0rp/ale'
Plug 'sbdchd/neoformat'
Plug 'junegunn/goyo.vim', { 'on': 'Goyo'}
Plug 'scrooloose/nerdtree', { 'on': ['NERDTreeFind', 'NERDTreeToggle'] }
Plug 'christoomey/vim-tmux-navigator'
Plug 'zefei/vim-wintabs'
@ -113,7 +112,7 @@ set complete+=]
set completeopt-=preview
set completeopt+=noinsert,longest,noselect,menuone
set formatoptions+=n
let &formatlistpat='^\s*\(\d\+[\]:.)}\t ]\|[*-][\t ]\)\s*'
let formatlistpat='^\s*\(\d\+[\]:.)}\t ]\|[*-][\t ]\)\s*'
" Display all matching files when we tab complete
set wildmenu
@ -212,13 +211,6 @@ if !exists("autocommands_loaded") && has("autocmd")
au BufRead,BufNewFile *.conf set filetype=dosini
au BufRead,BufNewFile *.bash* set filetype=sh
aug END
aug mutt_settings
autocmd BufRead,BufNewFile /tmp/neomutt* let g:goyo_width=80
autocmd BufRead,BufNewFile /tmp/neomutt* :Goyo
autocmd BufEnter /tmp/neomutt* :exe "normal! 9j\<cr>o"
autocmd BufEnter /tmp/neomutt* setl spelllang=es
aug END
endif
"}}}
@ -362,35 +354,6 @@ let g:wintabs_ui_arrow_left='«'
let g:wintabs_ui_arrow_right='»'
" }}}
" Goyo {{{
let g:goyo_height = "90%"
function! s:goyo_enter()
set showmode
set noshowcmd
let b:quitting = 0
let b:quitting_bang = 0
autocmd QuitPre <buffer> let b:quitting = 1
cabbrev <buffer> q! let b:quitting_bang = 1 <bar> q!
endfunction
function! s:goyo_leave()
set noshowmode
set showcmd
" Quit Vim if this is the only remaining buffer
if b:quitting && len(filter(range(1, bufnr('$')), 'buflisted(v:val)')) == 1
if b:quitting_bang
qa!
else
qa
endif
endif
endfunction
autocmd! User GoyoEnter call <SID>goyo_enter()
autocmd! User GoyoLeave call <SID>goyo_leave()
"}}}
" NerdTree {{{
autocmd StdinReadPre * let s:std_in=1
let NERDTreeIgnore=['\.rbc$', '\~$', '\.pyc$', '\.pyo$', '\.db$', '\.sqlite$', '.o$', 'bower_components', 'node_modules', '__pycache__']
@ -422,8 +385,6 @@ nnoremap <silent> M-Tab :TmuxNavigatePrevious<cr>
map <F9> :!w<Enter>:!pdflatex <C-r>%<Enter>
map <F6> :setlocal spell! spelllang=es<CR>
map <F7> :setlocal spell! spelllang=en<CR>
map <F8> :Goyo<CR>
inoremap <M-g> <esc>:Goyo<CR>a
nmap <silent> <F10> <Plug>(ale_previous_wrap)
nmap <silent> <F11> <Plug>(ale_next_wrap)
@ -434,7 +395,7 @@ vnoremap <leader>f :Neoformat<CR>
" FZF really is a lifechanger
nnoremap <F4> :FZF<CR>
nnoremap <leader>b :Buffers<cr>
nnoremap <leader>p :History:<cr>
nnoremap <leader>h :History:<cr>
nnoremap <leader>t :Files<cr>
nnoremap <leader>gt :GFiles<cr>
nnoremap <leader>l :Lines<cr>
@ -454,10 +415,10 @@ imap <c-x><c-l> <plug>(fzf-complete-line)
nnoremap <silent> <F3> :NERDTreeFind<CR>
nnoremap <silent> <F2> :NERDTreeToggle<CR>
nnoremap <leader>Pi :PlugInstall<CR>
nnoremap <leader>Pu :PlugUpdate<CR>
nnoremap <leader>PU :PlugUpgrade<CR>
nnoremap <leader>Pc :PlugClean<CR>
nnoremap <leader>pi :PlugInstall<CR>
nnoremap <leader>pu :PlugUpdate<CR>
nnoremap <leader>pU :PlugUpgrade<CR>
nnoremap <leader>pc :PlugClean<CR>
" super quick search and replace
nnoremap <Space>' :'{,'}s/\<<C-r>=expand("<cword>")<CR>\>/

View File

@ -1,57 +0,0 @@
# DO NOT edit this file by hand, qutebrowser will overwrite it.
# Instead, create a config.py - see :help for details.
config_version: 1
global:
aliases:
q: quit
w: session-save
wq: quit --save
auto_save.session: true
completion.height: 25%
completion.timestamp_format: '%F'
completion.web_history_max_items: 1000
confirm_quit:
- downloads
content.geolocation: false
content.headers.user_agent: Mozilla/5.0 (iPad; CPU OS 8_1 like Mac OS X) AppleWebKit/534.46
(KHTML, like Gecko) Version/5.1 Mobile/9B176 Safari/7534.48.3
downloads.position: bottom
downloads.remove_finished: 5000
editor.command:
- nvim
- -f
- '{file}'
fonts.monospace: '"IBM Plex Mono", Inconsolata, "Iosevka Term", Dina, CtrlD, "Fantasque
Sans Mono", "xos4 Terminus", Terminus, Monospace, "DejaVu Sans Mono", Monaco,
"Bitstream Vera Sans Mono", "Andale Mono", "Courier New", Courier, "Liberation
Mono", monospace, Fixed, Consolas, Terminal'
hints.chars: '1234567890'
hints.mode: number
history_gap_interval: 10
new_instance_open_target: tab-bg-silent
scrolling.smooth: true
session.lazy_restore: true
statusbar.padding:
bottom: 1
left: 2
right: 2
top: 1
tabs.background: true
tabs.last_close: startpage
tabs.mousewheel_switching: false
tabs.show: multiple
url.default_page: file:///home/deadguy/.config/qutebrowser/start.html
url.searchengines:
DEFAULT: https://www.startpage.com/do/mypage.pl?prf=7ad5a95b02fe36acca68c977d39fe6d1/?q={}
aur: https://aur.archlinux.org/packages/?O=0&K={}
aw: https://wiki.archlinux.org/index.php?title=Special%3ASearch&search={}
g: https://encrypted.google.com/search?q={}
gh: https://github.com/search?utf8=✓&q={}
pkg: https://www.archlinux.org/packages/?sort=&q={}&maintainer=&flagged=
sk: https://www.skytorrents.in/search/all/ed/1/?l=en-us&q={}
tpb: http://thepiratebay.org/search/{}
w: https://en.wikipedia.org/?search={}
yt: https://youtube.com/results?search_query={}
url.start_pages: file:///home/deadguy/.config/qutebrowser/start.html
window.hide_wayland_decoration: true

File diff suppressed because it is too large Load Diff

View File

@ -1,6 +1,7 @@
from __future__ import (absolute_import, division, print_function)
# You can import any python module as needed.
from collections import deque
import os
import re

View File

@ -1,232 +0,0 @@
#!/usr/bin/python
# coding=UTF-8
# These glyphs, and the mapping of file extensions to glyphs
# has been copied from the vimscript code that is present in
# https://github.com/ryanoasis/vim-devicons
import re;
import os;
# all those glyphs will show as weird squares if you don't have the correct patched font
# My advice is to use NerdFonts which can be found here:
# https://github.com/ryanoasis/nerd-fonts
file_node_extensions = {
'styl' : '\ue73b',
'scss' : '\uee19',
'htm' : '\uede1',
'html' : '\uede0',
'slim' : '\ueddf',
'ejs' : '\ue8ae',
'css' : '\uedbc',
'less' : '\uea5f',
'md' : '\ue08c',
'markdown' : '\ue08c',
'json' : '\ue7bb',
'js' : '\uea55',
'js.map' : '\uea55',
'jsx' : '\ue849',
'rb' : '\ue03d',
'php' : '\ue8eb',
'py' : '\uee10',
'pyc' : '\uee10',
'pyo' : '\uee10',
'pyd' : '\uee10',
'coffee' : '\ue1ba',
'mustache' : '\ue757',
'hbs' : '\ue757',
'conf' : '\ue8df',
'cfg' : '\ue8df',
'ini' : '\ue6aa',
'yml' : '\ue00f',
'bat' : '\ue238',
'jpg' : '\ue11c',
'tif' : '\ue11c',
'tiff' : '\ue11c',
'jpeg' : '\ue11c',
'bmp' : '\ue11c',
'png' : '\ue11c',
'gif' : '\ue11c',
'ico' : '\ue493',
'twig' : '\ue753',
'cpp' : '\uedb8',
'h' : '\uedb8',
'c++' : '\uedb8',
'cxx' : '\uedb8',
'cc' : '\uedb8',
'cp' : '\ue7a5',
'c' : '\uedb1',
'hs' : '\ueddd',
'lhs' : '\ueddd',
'lua' : '\ue77e',
'java' : '\uede4',
'sh' : '\uee1f',
'fish' : '\uee1f',
'ml' : '\ue77d',
'mli' : '\ue77d',
'diff' : '\ue7c3',
'db' : '\ue074',
'sql' : '\uedf9',
'dump' : '\ue279',
'clj' : '\uedb4',
'cljc' : '\uedb4',
'cljs' : '\ue8e8',
'edn' : '\uedb4',
'scala' : '\uee1b',
'go' : '\ue75b',
'gd' : '\ue7d7',
'godot' : '\ue7d7',
'dart' : '\uea9f',
'xul' : '\uea8d',
'sln' : '\uea13',
'suo' : '\uea13',
'pl' : '\uee05',
'pm' : '\uee05',
't' : '\ue8c6',
'rss' : '\ue40d',
'f#' : '\ueaae',
'fsscript' : '\ueaae',
'fsx' : '\ueaae',
'fs' : '\ueaae',
'fsi' : '\ueaae',
'rs' : '\uee18',
'rlib' : '\uee18',
'd' : '\ueab6',
'erl' : '\uedc6',
'hrl' : '\uedc6',
'vim' : '\ueacc',
'vimrc' : '\ueacc',
'ai' : '\ueabb',
'eps' : '\ueabb',
'psd' : '\ue761',
'psb' : '\ue761',
'ts' : '\ue73f',
'jl' : '\ue74d',
'rc' : '\ue8df',
'xml' : '\ue00f',
'log' : '\ue439',
'avi' : '\ue8de',
'mpeg' : '\ue8de',
'mpg' : '\ue8de',
'mkv' : '\ue8de',
'flv' : '\ue8de',
'webm' : '\ue8de',
'mp4' : '\ue8de',
'mp3' : '\ue0e2',
'm3u' : '\ue39d',
'pls' : '\ue39d',
'flac' : '\ue0e2',
'wav' : '\ue0e2',
'ogg' : '\ue0e2',
'epub' : '\ue10b',
'pdf' : '\ue013',
'7z' : '\ue27f',
'apk' : '\uea15',
'bz2' : '\ue27f',
'cab' : '\ue27f',
'cpio' : '\ue27f',
'deb' : '\ue9db',
'gem' : '\uee15',
'gz' : '\ue27f',
'gzip' : '\ue27f',
'lha' : '\ue27f',
'lzh' : '\ue27f',
'lzma' : '\ue27f',
'rar' : '\ue27f',
'rpm' : '\ue9e2',
'tar' : '\ue27f',
'tgz' : '\ue27f',
'xz' : '\ue27f',
'zip' : '\ue27f',
'aup' : '\ue85c',
'blend' : '\ue85d',
'blend1' : '\ue85d',
'fbx' : '\ue85f',
'dae' : '\ue26c',
'3ds' : '\ue26c',
'obj' : '\ue26c',
'tex' : '\ue755',
'ttf' : '\ue772',
'otf' : '\ue772',
'bdf' : '\ue772',
'fzb' : '\ue095',
'fzz' : '\ue095',
'svg' : '\uee25',
'doc' : '\ue27b',
'docx' : '\ue27b',
'xls' : '\ue27c',
'xlsx' : '\ue27c',
'exe' : '\uea16',
'ino' : '\ue793',
'pde' : '\ue803',
'img' : '\ue38c',
'iso' : '\ue38c',
'cue' : '\ue38c',
'gpg' : '\ue611',
'mk' : '\ue7a2',
'patch' : '\ue764',
}
dir_node_exact_matches = {
# English
'.git' : '\uedce',
'Desktop' : '\ue0e0',
'Documents' : '\ue0f6',
'Downloads' : '\ue0f9',
'Dropbox' : '\ue22a',
'Music' : '\ue106',
'Pictures' : '\ue048',
'Public' : '\ue632',
'Templates' : '\ue1b8',
'Videos' : '\ue11b',
'home' : '\ue0f5',
'root' : '\ue33e',
}
file_node_exact_matches = {
'exact-match-case-sensitive-1.txt' : '\ue10f',
'exact-match-case-sensitive-2' : '\ue430',
'gruntfile.coffee' : '\ue759',
'gruntfile.js' : '\ue759',
'gruntfile.ls' : '\ue759',
'gulpfile.coffee' : '\ue758',
'gulpfile.js' : '\ue758',
'gulpfile.ls' : '\ue758',
'dropbox' : '\uea0e',
'Makefile' : '\ue7a2',
'.ds_store' : '\uea18',
'.gitconfig' : '\uedce',
'.gitignore' : '\uedce',
'.bashrc' : '\ue799',
'.zshrc' : '\ue799',
'.zprofile' : '\ue799',
'.bashprofile' : '\ue799',
'favicon.ico' : '\ue493',
'license' : '\ue36b',
'LICENSE' : '\ue36b',
'node_modules' : '\uedfe',
'react.jsx' : '\uee12',
'procfile' : '\uedde',
'.Xdefaults' : '\uee2c',
'.Xresources' : '\uee2c',
'.Xauthority' : '\uee2c',
'.dmrc' : '\uee2c',
'.jack-settings' : '\ue4ec',
'.mime.types' : '\ue8e2',
'.nvidia-settings-rc' : '\ue7c0',
'.pam_environment' : '\ue799',
'.profile' : '\ue799',
'.recently-used' : '\ue56c',
'.selected_editor' : '\ue04a',
'.vimrc' : '\ueacc',
'.xinputrc' : '\uee2c',
'.xinitrc' : '\uee2c',
'.xserverrc' : '\uee2c',
'.Xclients' : '\uee2c',
'mimeapps.list' : '\ue8e2',
'user-dirs.dirs' : '\ue016',
'ini' : '\ue6aa',
'config' : '\ue8df'
}
def devicon(file):
if file.is_directory: return dir_node_exact_matches.get(file.relative_path, '\ue1d8')
return file_node_exact_matches.get(file.relative_path, file_node_extensions.get(file.extension, '\ue010'))

View File

@ -1,5 +1,4 @@
# == Options
default_linemode devicons
# Which viewmode should be used? Possible values are:
# miller: Use miller columns which show multiple levels of the hierarchy
@ -47,7 +46,7 @@ set vcs_backend_hg disabled
set vcs_backend_bzr disabled
# Use one of the supported image preview protocols
set preview_images true
set preview_images false
# Set the preview image method
set preview_images_method w3m
@ -98,14 +97,14 @@ set display_tags_in_all_columns true
set update_title false
# Set the title to "ranger" in the tmux program?
set update_tmux_title true
set update_tmux_title false
# Shorten the title if it gets long? The number defines how many
# directories are displayed at once, 0 turns off this feature.
set shorten_title 3
# Show hostname in titlebar?
set hostname_in_titlebar true
set hostname_in_titlebar false
# Abbreviate $HOME with ~ in the titlebar (first line) of ranger?
set tilde_in_titlebar true
@ -316,6 +315,7 @@ map gd cd ~/Downloads
map g. cd ~/.config
map gT cd ~/.local/share/Trash/files/
map gm cd ~/Music/Albums
map gb cd ~/bin
map gM cd /media
map gR cd /
map gr eval fm.cd(ranger.RANGERDIR)

View File

@ -186,7 +186,7 @@ mime ^image, has eom, X, flag f = eom -- "$@"
mime ^image, has nomacs, X, flag f = nomacs -- "$@"
mime ^image, has gimp, X, flag f = gimp -- "$@"
ext xcf, X, flag f = gimp -- "$@"
ext gif, has sxiv, X, flag f = sxiv -a -- "$@"
ext gif, has sxiv, X, flag f = sxiv-gif -- "$@"
ext gif, has mpv, X, flag f = mpv --loop=0 -- "$@"
ext blend, has blender, X, flag f = blender -- "$@"

View File

@ -31,7 +31,7 @@ IMAGE_CACHE_PATH="${4}" # Full path that should be used to cache image preview
PV_IMAGE_ENABLED="${5}" # 'True' if image previews are enabled, 'False' otherwise.
FILE_EXTENSION="${FILE_PATH##*.}"
FILE_EXTENSION_LOWER="${FILE_EXTENSION,,}"
FILE_EXTENSION_LOWER=$(echo "${FILE_EXTENSION}" | tr '[:upper:]' '[:lower:]')
# Settings
HIGHLIGHT_SIZE_MAX=262143 # 256KiB

View File

@ -1,160 +0,0 @@
; Reddit Terminal Viewer Configuration File
; https://github.com/michael-lazar/rtv
;
; This file should be placed in $XDG_CONFIG/rtv/rtv.cfg
; If $XDG_CONFIG is not set, use ~/.config/rtv/rtv.cfg
[rtv]
##################
# General Settings
##################
RTV_BROWSER = 'firefox'
RTV_EDITOR= 'nano'
; Turn on ascii-only mode to disable all unicode characters.
; This may be necessary for compatibility with some terminal browsers.
ascii = False
; Turn on monochrome mode to disable color.
monochrome = False
; Enable debugging by logging all HTTP requests and errors to the given file.
;log = /tmp/rtv.log
; Default subreddit that will be opened when the program launches.
subreddit = front
;subreddit = python
;subreddit = python+linux+programming
;subreddit = all
; Allow rtv to store reddit authentication credentials between sessions.
persistent = True
; Clear any stored credentials when the program starts.
clear_auth = False
; Maximum number of opened links that will be saved in the history file.
history_size = 200
; Open external links using programs defined in the mailcap config.
enable_media = True
; Maximum number of columns for a comment
max_comment_cols = 120
; Hide username if logged in, display "Logged in" instead
hide_username = True
; Color theme, use "rtv --list-themes" to view a list of valid options.
; This can be an absolute filepath, or the name of a theme file that has
; been installed into either the custom of default theme paths.
theme = solarized-dark
################
# OAuth Settings
################
; This sections defines the paramaters that will be used during the OAuth
; authentication process. rtv is registered as an "installed app",
; see https://github.com/reddit/reddit/wiki/OAuth2 for more information.
; These settings are defined at https://www.reddit.com/prefs/apps and should
; not be altered unless you are defining your own developer application.
oauth_client_id = E2oEtRQfdfAfNQ
oauth_client_secret = praw_gapfill
oauth_redirect_uri = http://127.0.0.1:65000/
; Port that the rtv webserver will listen on. This should match the redirect
; uri defined above.
oauth_redirect_port = 65000
; Access permissions that will be requested.
oauth_scope = edit,history,identity,mysubreddits,privatemessages,read,report,save,submit,subscribe,vote
; This is a separate token for the imgur api. It's used to extract images
; from imgur links and albums so they can be opened with mailcap.
; See https://imgur.com/account/settings/apps to generate your own key.
imgur_client_id = 93396265f59dec9
[bindings]
##############
# Key Bindings
##############
; If you would like to define custom bindings, copy this section into your
; config file with the [bindings] heading. All commands must be bound to at
; least one key for the config to be valid.
;
; 1.) Plain keys can be represented by either uppercase/lowercase characters
; or the hexadecimal numbers referring their ascii codes. For reference, see
; https://en.wikipedia.org/wiki/ASCII#ASCII_printable_code_chart
; e.g. Q, q, 1, ?
; e.g. 0x20 (space), 0x3c (less-than sign)
;
; 2.) Special ascii control codes should be surrounded with <>. For reference,
; see https://en.wikipedia.org/wiki/ASCII#ASCII_control_code_chart
; e.g. <LF> (enter), <ESC> (escape)
;
; 3.) Other special keys are defined by curses, they should be surrounded by <>
; and prefixed with KEY_. For reference, see
; https://docs.python.org/2/library/curses.html#constants
; e.g. <KEY_LEFT> (left arrow), <KEY_F5>, <KEY_NPAGE> (page down)
;
; Notes:
; - Curses <KEY_ENTER> is unreliable and should always be used in conjunction
; with <LF>.
; - Use 0x20 for the space key.
; - A subset of Ctrl modifiers are available through the ascii control codes.
; For example, Ctrl-D will trigger an <EOT> signal. See the table above for
; a complete reference.
; Base page
EXIT = q
FORCE_EXIT = Q
HELP = ?
SORT_HOT = 1
SORT_TOP = 2
SORT_RISING = 3
SORT_NEW = 4
SORT_CONTROVERSIAL = 5
MOVE_UP = k, <KEY_UP>
MOVE_DOWN = j, <KEY_DOWN>
PREVIOUS_THEME = <KEY_F2>
NEXT_THEME = <KEY_F3>
PAGE_UP = m, <KEY_PPAGE>, <NAK>
PAGE_DOWN = n, <KEY_NPAGE>, <EOT>
PAGE_TOP = gg
PAGE_BOTTOM = G
UPVOTE = a
DOWNVOTE = z
LOGIN = u
DELETE = d
EDIT = e
INBOX = i
REFRESH = r, <KEY_F5>
PROMPT = /
SAVE = w
COPY_PERMALINK = y
COPY_URL = Y
; Submission page
SUBMISSION_TOGGLE_COMMENT = 0x20
SUBMISSION_OPEN_IN_BROWSER = o, <LF>, <KEY_ENTER>
SUBMISSION_POST = c
SUBMISSION_EXIT = h, <KEY_LEFT>
SUBMISSION_OPEN_IN_PAGER = l, <KEY_RIGHT>
SUBMISSION_OPEN_IN_URLVIEWER = b
SUBMISSION_GOTO_PARENT = K
SUBMISSION_GOTO_SIBLING = J
; Subreddit page
SUBREDDIT_SEARCH = f
SUBREDDIT_POST = c
SUBREDDIT_OPEN = l, <KEY_RIGHT>
SUBREDDIT_OPEN_IN_BROWSER = o, <LF>, <KEY_ENTER>
SUBREDDIT_OPEN_SUBSCRIPTIONS = s
SUBREDDIT_OPEN_MULTIREDDITS = S
SUBREDDIT_FRONTPAGE = p
; Subscription page
SUBSCRIPTION_SELECT = l, <LF>, <KEY_ENTER>, <KEY_RIGHT>
SUBSCRIPTION_EXIT = h, s, S, <ESC>, <KEY_LEFT>

View File

@ -21,18 +21,34 @@ alt + {_,shift} + Tab
bspc node -f {next,prev}.local.normal
super + {comma,period}
bspc node $(bspc query -N -n -n .!leaf || echo @/) -R {90,-90}
#bspc node $(bspc query -N -n -n .!leaf || echo @/) -R {90,-B}
bspc node @/ -F {horizontal,vertical}
super + shift + {comma,period}
bspc node @/ -R {90,270}
super + {_,shift} + ntilde
bspc node $(bspc query -N -n .hidden | tail -n1) {-g hidden,-g hidden=off -f}
#whid {hide,dmenu}
#bspc node $(bspc query -N -n .hidden | tail -n1) {-g hidden,-g hidden=off -f}
whid {hide,dmenu}
super + {Up,Down,Left,Right}
bspc node -f @{parent,brother,first,second}
super + ctrl + {Up,Down,Right}
bspc node -l {above,below,normal}
super + {_,shift,ctrl} + u
bspc node {@/ -B,@brother -B,@/ -E}
super + alt + u
euclid_balancer
super + {_,shift} + i
{bspc node -i,for win in `bspc query -N -d -n .leaf.!window`; do bspc node $win -k; done}
# Run Applications
super + {m,b,v,q,z,e,x,c}
{gedit,firefox,pavucontrol,oblogout,termite,thunar,st,kal}
super + {n,m,b,v,q,z,e,x,c}
{subl,featherpad,firefox,pavucontrol,oblogout,termite,thunar,st,kal}
super + {space,r,s}
rofi -show {drun,run,window}

View File

@ -9,11 +9,10 @@ urgent_on_bell = true
clickable_url = true
scrollback_lines = 10000
search_wrap = true
#font = IBM Plex Mono Regular 10
font = Sarasa Term J 10
#font = xos4 terminus 10
font = Monaco Regular 9
#font = Monaco Regular 9
#font = t cherry Regular 9
geometry = 1280x720
# "system", "on" or "off"
cursor_blink = off
@ -25,7 +24,7 @@ cursor_shape = underline
browser = firefox
# set size hints for the window
#size_hints = false
size_hints = false
# Hide links that are no longer valid in url select overlay mode
filter_unmatched_urls = true
@ -38,7 +37,6 @@ filter_unmatched_urls = true
foreground = #d3d7cf
foreground_bold = #d3d7cf
cursor = #d3d7cf
#background = rgba(8, 8, 8, 0.8)
background = #080808
# black

View File

@ -4,7 +4,7 @@
include "/home/deadguy/.gtkrc-2.0.mine"
gtk-theme-name="Minwaita-Dark"
gtk-icon-theme-name="Papirus-Dark"
gtk-font-name="IBM Plex Sans 9"
gtk-font-name="IBM Plex Sans weight=453 10"
gtk-cursor-theme-name="Alkano"
gtk-cursor-theme-size=0
gtk-toolbar-style=GTK_TOOLBAR_BOTH_HORIZ

View File

@ -2,7 +2,7 @@
* User: deadguy
* Copyright: deadguy
*/
configuration {
display-drun: "Activate";
display-run: "Execute";
@ -50,7 +50,7 @@ window {
location: east;
anchor: east;
height: 100%;
width: 22%;
width: 18%;
orientation: horizontal;
children: [mainbox];
border: 0 0 0 1px solid;

View File

@ -1,57 +0,0 @@
# Mailcap 101
# - The first entry with a matching MIME type will be executed, * is a wildcard
# - %s will be replaced with the image or video url
# - Add ``test=test -n "$DISPLAY"`` if your command opens a new window
# - Add ``needsterminal`` for commands that use the terminal
# - Add ``copiousoutput`` for commands that dump text to stdout
###############################################################################
# Commands below this point will open media in a separate window without
# pausing execution of RTV.
###############################################################################
# Note that rtv returns a list of urls for imgur albums, so we don't put quotes
# around the `%s`
image/x-imgur-album; curl -s %s | imv -; test=test -n "$DISPLAY"
image/gif; mpv '%s' --autofit 640x480 --loop=inf; test=test -n "$DISPLAY"
image/*; curl -s '%s' | imv -; test=test -n "$DISPLAY"
# Youtube videos are assigned a custom mime-type, which can be streamed with
# vlc or youtube-dl.
video/x-youtube; mpv --ytdl-format=best '%s' --autofit 640x480; test=test -n "$DISPLAY"
# Mpv is a simple and effective video streamer
video/*; mpv '%s' --autofit 640x480 --loop=inf; test=test -n "$DISPLAY"
# Use zathura for pdfs
application/pdf; zathura '%s'; test=test -n "$DISPLAY"
# Abiword for MS Word docs
application/msword; abiword '%s'; test=test -n "$DISPLAY"
# Autoview html
text/html; "$BROWSER" %s; test=test -n "$DISPLAY"; needsterminal;
text/html; w3m -I %{charset} -T text/html; copiousoutput;
#text/html; lynx -assume_charset=%{charset} -display_charset=utf-8 -dump %s; nametemplate=%s.html; copiousoutput
text/plain; cat %s; copiousoutput
###############################################################################
# Commands below this point will attempt to display media directly in the
# terminal when X is not available.
###############################################################################
# 256 color images using half-width unicode characters
# Much higher quality that img2txt, but must be built from source
# https://github.com/rossy/img2xterm
image/*; curl -s '%s' | convert -resize 80x80 - jpg:/tmp/rtv.jpg && img2xterm /tmp/rtv.jpg; needsterminal; copiousoutput
# Display images in classic ascii using img2txt and lib-caca
image/*; curl -s '%s' | convert - jpg:/tmp/rtv.jpg && img2txt -f utf8 /tmp/rtv.jpg; needsterminal; copiousoutput
# Full motion videos - requires a framebuffer to view
video/x-youtube; mpv -vo drm -quiet '%s'; needsterminal
video/*; mpv -vo drm -quiet '%s'; needsterminal
# Ascii videos
# video/x-youtube; youtube-dl -q -o - '%s' | mplayer -cache 8192 -vo caca -quiet -; needsterminal
# video/*; wget '%s' -O - | mplayer -cache 8192 -vo caca -quiet -; needsterminal

File diff suppressed because one or more lines are too long

View File

@ -1,96 +0,0 @@
# vim: filetype=muttrc
# basic colors ---------------------------------------------------------
color normal white default
color error red default
color tilde black default
color message cyan default
color markers red white
color attachment white default
color search brightmagenta default
color status brightyellow black
color indicator black white
color tree yellow default # arrow in threads
# basic monocolor screen
mono bold bold
mono underline underline
mono indicator reverse
mono error bold
# index ----------------------------------------------------------------
color index brightred default ~= # duplicate messages
color index white default "~A" # all messages
color index red default "~E" # expired messages
color index brightblue default "~N" # new messages
color index blue default "~O" # old messages
color index brightmagenta default "~Q" # messages that have been replied to
color index brightgreen default "~R" # read messages
color index brightblue default "~U" # unread messages
color index brightblue default "~U~$" # unread, unreferenced messages
color index brightyellow default "~v" # messages part of a collapsed thread
color index yellow default "~P" # messages from me
color index cyan default "~p!~F" # messages to me
color index cyan default "~N~p!~F" # new messages to me
color index cyan default "~U~p!~F" # unread messages to me
color index brightgreen default "~R~p!~F" # messages to me
color index red default "~F" # flagged messages
color index red default "~F~p" # flagged messages to me
color index red default "~N~F" # new flagged messages
color index red default "~N~F~p" # new flagged messages to me
color index red default "~U~F~p" # new flagged messages to me
color index black red "~D" # deleted messages
color index brightcyan default "~v~(!~N)" # collapsed thread with no unread
color index yellow default "~v~(~N)" # collapsed thread with some unread
color index green default "~N~v~(~N)" # collapsed thread with unread parent
color index red black "~v~(~F)!~N" # collapsed thread with flagged, no unread
color index yellow black "~v~(~F~N)" # collapsed thread with some unread & flagged
color index green black "~N~v~(~F~N)" # collapsed thread with unread parent & flagged
color index green black "~N~v~(~F)" # collapsed thread with unread parent, no unread inside, but some flagged
color index cyan black "~v~(~p)" # collapsed thread with unread parent, no unread inside, some to me directly
color index yellow red "~v~(~D)" # thread with deleted (doesn't differentiate between all or partial)
color index yellow default "~(~N)" # messages in threads with some unread
color index green default "~S" # superseded messages
color index red default "~T" # tagged messages
# message headers ------------------------------------------------------
color hdrdefault brightgreen default
color header brightyellow default "^(From)"
color header blue default "^(Subject)"
color header brightgreen default "^(Date)"
# body -----------------------------------------------------------------
color quoted blue default
color quoted1 cyan default
color quoted2 yellow default
color quoted3 red default
color quoted4 brightred default
color signature brightgreen default
color bold black default
color underline black default
color normal default default
color body brightcyan default "[;:][-o][)/(|]" # emoticons
color body brightcyan default "[;:][)(|]" # emoticons
color body brightcyan default "[ ][*][^*]*[*][ ]?" # more emoticon?
color body brightcyan default "[ ]?[*][^*]*[*][ ]" # more emoticon?
color body brightcyan default "[*]?((N)?ACK|CU|LOL|SCNR|BRB|BTW|CWYL|\
|FWIW|vbg|GD&R|HTH|HTHBE|IMHO|IMNSHO|\
|IRL|RTFM|ROTFL|ROFL|YMMV)[*]?"
# pgp
color body red default "(BAD signature)"
color body cyan default "(Good signature)"
color body brightblack default "^gpg: Good signature .*"
color body brightyellow default "^gpg: "
color body brightyellow red "^gpg: BAD signature from.*"
mono body bold "^gpg: Good signature"
mono body bold "^gpg: BAD signature from.*"
# yes, an insance URL regex
color body red default "([a-z][a-z0-9+-]*://(((([a-z0-9_.!~*'();:&=+$,-]|%[0-9a-f][0-9a-f])*@)?((([a-z0-9]([a-z0-9-]*[a-z0-9])?)\\.)*([a-z]([a-z0-9-]*[a-z0-9])?)\\.?|[0-9]+\\.[0-9]+\\.[0-9]+\\.[0-9]+)(:[0-9]+)?)|([a-z0-9_.!~*'()$,;:@&=+-]|%[0-9a-f][0-9a-f])+)(/([a-z0-9_.!~*'():@&=+$,-]|%[0-9a-f][0-9a-f])*(;([a-z0-9_.!~*'():@&=+$,-]|%[0-9a-f][0-9a-f])*)*(/([a-z0-9_.!~*'():@&=+$,-]|%[0-9a-f][0-9a-f])*(;([a-z0-9_.!~*'():@&=+$,-]|%[0-9a-f][0-9a-f])*)*)*)?(\\?([a-z0-9_.!~*'();/?:@&=+$,-]|%[0-9a-f][0-9a-f])*)?(#([a-z0-9_.!~*'();/?:@&=+$,-]|%[0-9a-f][0-9a-f])*)?|(www|ftp)\\.(([a-z0-9]([a-z0-9-]*[a-z0-9])?)\\.)*([a-z]([a-z0-9-]*[a-z0-9])?)\\.?(:[0-9]+)?(/([-a-z0-9_.!~*'():@&=+$,]|%[0-9a-f][0-9a-f])*(;([-a-z0-9_.!~*'():@&=+$,]|%[0-9a-f][0-9a-f])*)*(/([-a-z0-9_.!~*'():@&=+$,]|%[0-9a-f][0-9a-f])*(;([-a-z0-9_.!~*'():@&=+$,]|%[0-9a-f][0-9a-f])*)*)*)?(\\?([-a-z0-9_.!~*'();/?:@&=+$,]|%[0-9a-f][0-9a-f])*)?(#([-a-z0-9_.!~*'();/?:@&=+$,]|%[0-9a-f][0-9a-f])*)?)[^].,:;!)? \t\r\n<>\"]"
# Border lines.
color body blue default "( *[-+=#*~_]){6,}"

View File

@ -1,173 +0,0 @@
source ~/.mutt/colors
bind index g noop # this is
bind pager g noop # some bullshit
# Stuff --------------------------------------------
# "from" field gets 30% of remaining space, "subject" gets 70%. Remaining space is the total width minus the other fields
set my_index_format_pre='set my_col_from = `echo $((30 * ($(tput cols)-50) / 100))`; set my_col_subject = `echo $((70 * ($(tput cols)-50) / 100))`; set index_format="%2C %Z %D %-$my_col_from.${my_col_from}'
set my_index_format_post=' %-4.4c %?M?<%M ?%-$my_col_subject.${my_col_subject}s"'
folder-hook .*[sS]ent.* "$my_index_format_pre"t"$my_index_format_post"
folder-hook ! .*[sS]ent.* "$my_index_format_pre"F"$my_index_format_post"
mono bold bold
mono underline underline
mono indicator reverse
color index yellow default '.*'
color index_author red default '.*'
color index_number blue default
color index_subject cyan default '.s'
color index_size green default
color normal default default
color body brightred default [\-\.+_a-zA-Z0-9]+@[\-\.a-zA-Z0-9]+
color body brightblue default (https?|ftp)://[\-\.,/%~_:?&=\#a-zA-Z0-9]+
# Folder hooks ------------------------------------
folder-hook 'account.gvidaar' 'source ~/.mutt/account.gvidaar'
folder-hook 'account.galejo' 'source ~/.mutt/account.galejo'
# Default account ---------------------------------
source ~/.mutt/account.gvidaar
set mailcap_path = ~/.mutt/mailcap
set new_mail_command="notify-send -t 10000 'New Email in %f' '%n new messages, %u unread.' &"
# Sidebar -----------------------------------------
#set sidebar_format = "%B %?N?[%N]?%* %S"
set sidebar_format = "%B%?F? [%F]?%* %?N?%N/?%S"
color sidebar_new yellow default
set sidebar_width = 30
set sidebar_divider_char = ' '
set sidebar_short_path = yes
set sidebar_next_new_wrap = yes
# Config -----------------------------------------
set editor = "nvim"
unset move # gmail does that
set quit # don't ask, just do!!
unset mark_old # read/new is good enough for me
set beep_new = yes # bell on new mails
set pipe_decode # strip headers and eval mimes when piping
set thorough_search # strip headers and eval mimes before searching
set send_charset="utf-8"
set check_new = yes
set smart_wrap = yes
set allow_ansi = yes
set mail_check_stats = yes
set sleep_time = 0
set ssl_starttls = yes
set ssl_force_tls = yes
set imap_check_subscribed
set mail_check = 7200
set imap_keepalive = 1200
# Header Options -------------------------------------
set hdrs
ignore "Authentication-Results:"
ignore "DomainKey-Signature:"
ignore "DKIM-Signature:"
unignore from: to: cc: date: subject: # show only these
unhdr_order * # some distros order things by default
hdr_order date: from: to: date: subject: cc: # and in this order
unignore x-mailing-list: posted-to:
unignore x-mailer:
# Status Bar -----------------------------------------
set status_chars = " *%A"
set status_format = "──┄┄╼ %f (%m) ╾┄┄──────┼%?n? %n new?%?d?, %d to delete?%?t?, %t tagged?%?p?, %p postponed ? ┼───%>─┤ %P ├───"
color status blue default
# Index Options -----------------------------------------
set sort = threads # like gmail
set sort_aux = reverse-last-date-received # like gmail
set uncollapse_jump # don't collapse on an unread message
set sort_re # thread based on regex
set reply_regexp = "^(([Rr][Ee]?(\[[0-9]+\])?: *)?(\[[^]]+\] *)?)*"
# Pager Options -----------------------------------------
set pager_context = 3
set pager_index_lines = 0 # number of index lines to show
set pager_context = 5 # number of context lines to show
set pager_stop = yes # don't go to next message automatically
set menu_scroll # scroll in menus
set smart_wrap # don't split words
set tilde # show tildes like in vim
unset markers # no ugly plus signs
auto_view application/pdf
auto_view text/html # view html automatically
alternative_order text/plain text/enriched text/html
set quote_regexp = "^( {0,4}[>|:#%]| {0,4}[a-z0-9]+[>|]+)+"
# Formats --------------------------------------------
set date_format = " %a %d %b"
set index_format = " %Z %D %-45.45F %s (%-4.4c) "
set alias_format = " %4n %t %-20a %r "
# Composing Mail -------------------------------------
set envelope_from # which from?
set edit_headers # show headers when composing
set fast_reply # skip to compose when replying
set sendmail_wait = 1 # wait for sending... to complete
#set askcc # ask for CC:
set fcc_attach # save attachments with the body
set mime_forward = yes # forward attachments as part of body
set forward_format = "Fwd: %s" # format for subject when forwarding
set forward_decode # decode when forwarding
set attribution = "El %d, %n escribio:" # set the attribution
set reply_to # reply to Reply to: field
set reverse_name # reply as whomever it was to
set include # include message in replies
set forward_quote # include message in forwards
set beep_new
set skip_quoted_offset = 3
# Bindings ------------------------------------------
bind index <tab> sync-mailbox
bind index <space> collapse-thread
bind index D half-down
bind index U half-up
bind index d delete-message
bind index u undelete-message
bind index gg first-entry
bind index G last-entry
bind index <left> previous-unread
bind index <right> next-unread
bind index,pager R group-reply
bind index,pager <f9> sidebar-toggle-visible
bind index,pager k sidebar-prev # previous Mailbox
bind index,pager j sidebar-next # next Mailbox
bind index,pager l sidebar-open # open Highlighted Mailbox
bind pager q exit
bind pager / search
bind pager <up> previous-line
bind pager <down> next-line
bind pager k previous-line
bind pager j next-line
bind pager gg top
bind pager G bottom
bind pager <left> previous-undeleted
bind pager <right> next-undeleted
bind editor ^T complete
bind attach <return> view-mailcap # view attachments properly
# Macros --------------------------------------------
# ctrl-r to mark all as read
macro index \Cr "T~U<enter><tag-prefix><clear-flag>N<untag-pattern>.<enter>" "mark all messages as read"
# saner copy/move dialogs
macro index C "<copy-message>?<toggle-mailboxes>" "copy a message to a mailbox"
macro index M "<save-message>?<toggle-mailboxes>" "move a message to a mailbox"
macro index <F1> '<sync-mailbox><enter-command>source ~/.mutt/account.gvidaar<enter><change-folder>!<enter>'
macro index <F2> '<sync-mailbox><enter-command>source ~/.mutt/account.galejo<enter><change-folder>!<enter>'
macro index,pager \CL "<enter-command>$my_index_format_pre"F"$my_index_format_post<enter><redraw-screen>"
macro attach 'V' "<pipe-entry>cat >~/.cache/mutt/mail.html && $BROWSER ~/.cache/mutt/mail.html && rm ~/.cache/mutt/mail.html<enter>"
macro index,pager U "<enter-command>set pipe_decode = yes<enter><pipe-message>urlview<enter><enter-command>set pipe_decode = no<enter>""view URLs"
macro index,pager \cb "<enter-command> set my_pdsave=\$pipe_decode<enter>\
<enter-command> unset pipe_decode<enter>\
<pipe-message>extract_url<enter>\
<enter-command> set pipe_decode=\$my_pdsave<enter>" "get URLs"

View File

@ -1,27 +1,7 @@
#is_vim="ps -o state= -o comm= -t '#{pane_tty}' \
# | grep -iqE '^[^TXZ ]+ +(\\S+\\/)?g?(view|n?vim?x?)(diff)?$'"
#bind-key -n C-h if-shell "$is_vim" "send-keys C-h" "select-pane -L"
#bind-key -n C-j if-shell "$is_vim" "send-keys C-j" "select-pane -D"
#bind-key -n C-k if-shell "$is_vim" "send-keys C-k" "select-pane -U"
#bind-key -n C-l if-shell "$is_vim" "send-keys C-l" "select-pane -R"
#bind-key -n C-\ if-shell "$is_vim" "send-keys C-\\" "select-pane -l"
# Set the default TERM
set -g default-terminal tmux-256color
# Update the TERM variable of terminal emulator when creating a new session or attaching a existing session
set -g update-environment 'DISPLAY SSH_ASKPASS SSH_AGENT_PID SSH_CONNECTION WINDOWID XAUTHORITY TERM'
set -ga terminal-overrides ',xterm-256color:Tc'
# Something about the cursor shape?
set -ga terminal-overrides ',*:Ss=\E[%p1%d q:Se=\E[2 q'
# Set Zsh as default Tmux shell
set -g default-command "${SHELL}"
#set-option -g default-shell /bin/zsh
unbind C-b
unbind space
unbind '"'
@ -33,7 +13,6 @@ bind-key C-a send-prefix
set -sg escape-time 0
setw -g mouse on
setw -g mode-keys vi
set -g status-keys emacs
# urlview
bind-key u capture-pane \; save-buffer /tmp/tmux-buffer \; new-window -n "urlview" '$SHELL -c "urlview < /tmp/tmux-buffer"'
@ -97,15 +76,15 @@ bind-key x kill-pane
bind-key / set-option -g status
set -g status-interval 1
set -g status-interval 2
setw -g aggressive-resize on
set-option -g base-index 1
setw -g pane-base-index 1
set -g renumber-windows on
set -g set-titles off
set -g set-titles-string "#W"
#set -g set-titles off
#set -g set-titles-string "#W"
set-window-option -g automatic-rename on
set -g automatic-rename-format "#{s/zsh//:pane_current_command}"
set -wg automatic-rename-format "#{s/zsh//:pane_current_command}"
setw -g clock-mode-style 24
## Status bar design
@ -130,8 +109,10 @@ set-window-option -g monitor-activity off
set-option -g visual-activity off
# Window status
bind-key t command-prompt "select-pane -T '%%'"
bind-key , command-prompt "rename-window '%%'"
set -g window-status-format "#{=-15:?window_name,#{window_name},#{s/deadguy/home/:?pane_current_path,#{b:pane_current_path},}}"
set -g window-status-current-format "#[fg=yellow]#{=-15:?window_name,#{window_name},#{s/deadguy/home/:?pane_current_path,#{b:pane_current_path},}}"
set -g window-status-current-format "#{=-15:?window_name,#{window_name},#{s/deadguy/home/:?pane_current_path,#{b:pane_current_path},}}"
set-window-option -g window-status-separator ' '
# List windows on left side of status bar

View File

@ -1,3 +1,5 @@
if [ -z "$DISPLAY" ] && [ -n "$XDG_VTNR" ] && [ "$XDG_VTNR" -eq 1 ]; then
exec startx
fi
eval `dircolors -b ~/.config/zsh/LS_COLORS`

7
.zshrc
View File

@ -3,7 +3,7 @@
# Exports {{{
export EDITOR="nvim"
export VISUAL="mousepad"
export VISUAL="subl"
export BROWSER="firefox"
export CLIBROWSER="links"
export GREP_COLOR="0;32"
@ -11,7 +11,7 @@ export PULSEMIXER_BAR_STYLE="┌╶┐╴└┘▮ ◆┆"
export RANGER_LOAD_DEFAULT_RC="FALSE"
source ~/.config/zsh/rc/transmission.zsh
source ~/.local/share/icons-in-terminal/icons_bash.sh
source /etc/icons-in-terminal/icons_bash.sh
# }}}
# Completion styles {{{
@ -265,6 +265,7 @@ bindkey '^[[6~' history-beginning-search-forward # Page down key
# }}}
# Assorted Alias {{{
unalias run-help
# Programs
alias gdl='gallery-dl'
alias mutt='neomutt'
@ -287,7 +288,7 @@ alias help='run-help'
alias p='pacui'
alias sr='sr -browser=$CLIBROWSER' # open in cli browser
alias surfraw='surfraw -browser=$BROWSER' # open in gui browser
alias foxdot='python -m FoxDot'
alias foxdot='python -m FoxDot & disown'
# MAXIMUM VERBOSITY YIELDS MAXIMUM RESULTS
alias chmod='chmod -v'

View File

@ -1,7 +1,7 @@
#!/bin/bash
if [ -d /sys/class/power_supply/BAT0 ]; then
bat_lvl=`head -n 1 /sys/class/power_supply/BAT0/capacity`
bat=" $bat_lvl%"
bat=" $bat_lvl%"
fi
notify-send -t 5000 "${bat}"

View File

@ -6,7 +6,7 @@ case $1 in
start) $EDITOR ~/.config/bspwm/autostart ;;
wm) $EDITOR ~/.config/bspwm/bspwmrc ;;
keys) $EDITOR ~/.config/sxhkd/sxhkdrc ;;
mutt) $EDITOR ~/.mutt/muttrc ;;
mutt) $EDITOR ~/.config/mutt/muttrc ;;
zsh) $EDITOR ~/.zshrc ;;
bar) $EDITOR ~/.config/polybar/config ;;
dunst) $EDITOR ~/.config/dunst/dunstrc ;;

View File

@ -26,9 +26,11 @@ dir="$music_dir/$artist/$album/"
temp_path="/tmp/current_cover.png"
message="$(mpc current -f "$form" | sed "s:&:&amp;:g" )"
[[ -z $song ]] && exit 1 # Is there music on
# Is there music on
[[ -z $song ]] && exit 1
if [[ -d "$dir" ]] ; then # Where to look for album covers
# Where to look for album covers
if [[ -d "$dir" ]] ; then
album_dir="$dir"
elif [[ -z "$album_dir" ]] ; then
album_dir="$music_dir/$album/"
@ -36,12 +38,14 @@ if [[ -d "$dir" ]] ; then # Where to look for album covers
album_dir="$music_dir/$albart/$album/"
fi
[[ -z "$album_dir" ]] && exit 1 # No cover if the folder isn't found
# No cover if the folder isn't found
[[ -z "$album_dir" ]] && exit 1
# But if it is found, look for only one of the specified files
cover="$(find "$album_dir" -maxdepth 1 -type f -regextype egrep -regex "$img_reg" 2>/dev/null)"
if [[ -n $cover ]]; then # Resize the cover
# Resize the cover
if [[ -n $cover ]]; then
ffmpeg -hide_banner -loglevel panic -nostats -y -i "$cover" -vf scale="$cover_resize":-2 "$temp_path"
cover="$temp_path"
fi

View File

@ -3,5 +3,5 @@
# Showing off during live shows
echo " "
toilet -t -f 3d " $@ " | lolcat
toilet -t -f rustofat " $@ " | lolcat
echo " "

View File

@ -24,10 +24,10 @@ i3lock \
--radius=98 --ring-width=3.8 --indpos="684:353" \
--image=/home/deadguy/Pictures/maralock.png --color=000000 \
--insidevercolor=007c0000 --insidewrongcolor=af000000 --insidecolor=00000000 \
--ringvercolor=00d70000 --ringwrongcolor=9c060600 --ringcolor=ffffff00 \
--verifcolor=ffffffff --wrongcolor=af0000ff --linecolor=ffffff00 \
--separatorcolor=12121200 --keyhlcolor=ffffffff --bshlcolor=c4a000ff \
--ignore-empty-password --nofork &
--ringvercolor=00d70000 --ringwrongcolor=9c060600 --ringcolor=eeeeec00 \
--verifcolor=eeeeecff --wrongcolor=af0000ff --linecolor=eeeeec00 \
--separatorcolor=12121200 --keyhlcolor=eeeeecff --bshlcolor=c4a000ff \
--veriftext="0x0D.7" --wrongtext="005917" --ignore-empty-password --nofork &
pid="$!"
while 2>/dev/null kill -0 "$pid"; do

View File

@ -1,36 +1,85 @@
#!/usr/bin/env dash
# Shamelessly stolen from https://github.com/neeasade/dotfiles/tree/master/wm/.wm/scripts/interact
#!/bin/bash
# Originally by https://github.com/windelicato/
size=${2:-'20'}
dir=$1
node=$(bspc query -N -n)
mon=$(bspc query -M -m)
# are we floating? move a percentage of the monitor resolution.
if bspc query -N -n $node.floating > /dev/null; then
percent=5
case $dir in
west) targetProp=width; sign=-;;
east) targetProp=width;;
north) targetProp=height; sign=-;;
south) targetProp=height;;
esac
transplanter() {
bspc node ${dir} -p south && bspc node -n ${dir}
}
moveArgs="$sign$(echo "$percent/100*$(bspc query -T -m | jq .rectangle.$targetProp)" | bc -l)"
[ $targetProp = "height" ] && moveArgs="0 $moveArgs" || moveArgs="$moveArgs 0"
bspc node -v $moveArgs
northplanter() {
bspc node north -p north && bspc node -n north
}
rootplanter() {
bspc node @/ -p ${dir} && bspc node -n @/ || bspc node -s next.local && bspc node -n @/
bspc node @/ -p cancel
}
bspc config pointer_follows_focus true
# Find current window mode
is_floating() {
bspc query -T -n | grep -q '"state":"floating"'
}
# If the window is floating, move it
if is_floating; then
#only parse input if window is floating,tiled windows accept input as is
case "$dir" in
west) switch="-x"
sign="-"
;;
east) switch="-x"
sign="+"
;;
north) switch="-y"
sign="-"
;;
*) switch="-y"
sign="+"
;;
esac
xdo move ${switch} ${sign}${size}
# Otherwise, window is tiled: switch with window in given direction
else
# we're tiled. TODO: re-evaluate this
if ! bspc node -f $dir.local; then
bspc node $node -m $dir
bspc monitor -f $dir
else
bspc config focus_follows_pointer false
new_mon=$(bspc query -M -m)
[ "$new_mon" = "$mon" ] &&
bspc node -s $node ||
bspc node $node -m $new_mon
bspc config focus_follows_pointer true
fi
bspc node -f $node
fi
if [[ $(bspc query -N -n .local.\!floating | wc -l) != 2 ]]; then
case "$dir" in
north) northplanter || rootplanter
;;
*) transplanter || rootplanter
;;
esac
else
case "$dir" in
east) bspc node -s east || bspc query -N -n west.local || \
if bspc query -N -n south.local ; then
bspc node @/ -R 90
else
bspc node @/ -R 270
fi
;;
west) bspc node -s west || bspc query -N -n east.local || \
if bspc query -N -n north.local ; then
bspc node @/ -R 90
else
bspc node @/ -R 270
fi
;;
south) bspc node -s south || bspc query -N -n north.local || \
if bspc query -N -n west.local ; then
bspc node @/ -R 90
else
bspc node @/ -R 270
fi
;;
*) bspc node -s north || bspc query -N -n south.local || \
if bspc query -N -n west.local ; then
bspc node @/ -R 270
else
bspc node @/ -R 90
fi
;;
esac
fi
fi

View File

@ -1,56 +1,41 @@
#!/usr/bin/env dash
# depends on: jq, bc, bspc
# resize windows or groups of windows in bspwm.
#!/bin/bash
# Shamelessly stolen from https://github.com/neeasade/dotfiles/tree/master/wm/.wm/scripts/interact
# (percent of current monitor resolution to resize)
percent=5
size=${2:-'10'}
dir=$1
# get rectangle property of origin node, floating or tiling (x,y,width,height)
originalNode=$(bspc query -N -n)
dim() {
bspc query -T -n $originalNode | jq ".rectangle.$1"
# Find current window mode
is_tiled() {
bspc query -T -n | grep -q '"state":"tiled"'
}
# If the window is floating, move it
if ! is_tiled; then
#only parse input if window is floating,tiled windows accept input as is
case "$dir" in
west) switch="-w"
sign="-"
;;
east) switch="-w"
sign="+"
;;
north) switch="-h"
sign="-"
;;
south) switch="-h"
sign="+"
;;
esac
xdo resize ${switch} ${sign}${size}
# set fall back, and target window property.
case $dir in
west) dir=left; fallDir=right; targetProp=width; queryDir=x; op="min"; sign=-;;
east) dir=right; fallDir=left; targetProp=width; queryDir=x; op="max"; sign=+;;
north) dir=top; fallDir=bottom; targetProp=height; queryDir=y; op="min"; sign=-;;
south) dir=bottom; fallDir=top; targetProp=height; queryDir=y; op="max"; sign=+;;
*) exit 1;;
esac
# if we're focused on a group of nodes, select a window within, leaning towards our desired direction.
bspc query -N -n focused.\!window > /dev/null && targetNode=$(bspc query -T -n | jq "[recurse(.[]?) | objects | select(has(\"id\") and .client!=null)] | ${op}_by(.rectangle.$queryDir).id")
targetNode=${targetNode:-focused}
# set move args
moveArgs="$sign$(echo "$percent/100*$(bspc query -T -m | jq .rectangle.$targetProp)" | bc -l)"
[ $targetProp = "height" ] && moveArgs="0 $moveArgs" || moveArgs="$moveArgs 0"
# note current state, initial move attempt.
beforeVal=$(dim $targetProp)
bspc node $targetNode -z $dir $moveArgs
# if we're floating, this is all that is needed.
bspc query -N -n focused.floating && exit 0
# if we weren't successful, try resizing the other way
[ "$beforeVal" = "$(dim $targetProp)" ] && bspc node $targetNode -z $fallDir $moveArgs
if [ "$beforeVal" = "$(dim $targetProp)" ]; then
# undo our wrong resize
bspc node $targetNode -z $fallDir $(echo $moveArgs | tr +- -+) &
# attempt to jump the other direction and push into the node
case $dir in
left) targetNode=east;;
right) targetNode=west;;
top) targetNode=south;;
bottom) targetNode=north;;
esac
bspc node $targetNode -z $dir $moveArgs &
# Otherwise, window is tiled: switch with window in given direction
else
case "$dir" in
west) bspc node @west -r -$size || bspc node @east -r -${size}
;;
east) bspc node @west -r +$size || bspc node @east -r +${size}
;;
north) bspc node @south -r -$size || bspc node @north -r -${size}
;;
south) bspc node @south -r +$size || bspc node @north -r +${size}
;;
esac
fi

View File

@ -5,12 +5,10 @@ c() {
param "$1"
}
jack() {
ffmpeg -y \
-thread_queue_size 4096 \
-f pulse -i 1 \
-ac 2 -channel_layout stereo -async 1 \
-f jack -i ffmpeg \
-f x11grab \
-framerate 60 \
-s "$(xdpyinfo | grep dimensions | awk '{print $2;}')" \
@ -30,7 +28,6 @@ mute() {
-c:v libx264 -qp 0 -r 30 "$filename"
}
pulse() {
ffmpeg -y \
-thread_queue_size 4096 \
@ -55,4 +52,4 @@ c "$1"
#-f alsa -ac 2 -i pulse \
#-f pulse -i default \
#-ac 2 -channel_layout stereo -async 1 \
# -f jack -i ffmpeg
# -f jack -i ffmpeg

View File

@ -4,8 +4,8 @@ HEART='\ue001'
WIFI='\ue610'
if [ -d /sys/class/power_supply/BAT0 ]; then
battery_info="`head -n 1 /sys/class/power_supply/BAT0/capacity`%"
current_charge=$(echo $battery_info | grep -o '[0-9]\+%' | awk '{sub (/%/, "", $1); print $1}')
battery_info="$(head -n 1 /sys/class/power_supply/BAT0/capacity)%"
current_charge=$(echo "$battery_info" | grep -o '[0-9]\+%' | awk '{sub (/%/, "", $1); print $1}')
if [[ $current_charge -lt 11 ]]; then
echo -n '#[fg=colour9]'
@ -24,8 +24,8 @@ if [ -d /sys/class/power_supply/BAT0 ]; then
fi
if cat /sys/class/net/wlo1/operstate | grep -q 'up'; then
net="`awk 'NR == 3 { print substr($3, 1, length($3) - 1) }' /proc/net/wireless`"
echo -ne "#[fg=cyan]$WIFI ${net} "
net="$(awk 'NR == 3 { print substr($3, 1, length($3) - 1) }' /proc/net/wireless)"
echo -ne "#[fg=cyan]$WIFI ${net} "
fi