"first" commit, preparing for LARBS 2.0
This commit is contained in:
parent
68bd2acdc8
commit
50adee4e79
76 changed files with 9372 additions and 2 deletions
2
.Renviron
Normal file
2
.Renviron
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
|
||||||
|
R_LIBS_USER = ~/.R/library
|
1
.Rprofile
Normal file
1
.Rprofile
Normal file
|
@ -0,0 +1 @@
|
||||||
|
options(repos=structure(c(CRAN="http://cran.revolutionanalytics.com/")))
|
66
.Xdefaults
Normal file
66
.Xdefaults
Normal file
|
@ -0,0 +1,66 @@
|
||||||
|
*foreground: #00cc00
|
||||||
|
*foreground_bold: #a8a19f
|
||||||
|
*cursor: #a8a19f
|
||||||
|
*background: #1b1918
|
||||||
|
!!*background: rgba(0, 0, 0, .7)
|
||||||
|
|
||||||
|
!! black
|
||||||
|
*color0: #1b1918
|
||||||
|
*color8: #766e6b
|
||||||
|
!! red
|
||||||
|
*color1: #f22c40
|
||||||
|
*color9: #f22c40
|
||||||
|
!! green
|
||||||
|
*color2: #5ab738
|
||||||
|
*color10: #5ab738
|
||||||
|
!! yellow
|
||||||
|
*color3: #d5911a
|
||||||
|
*color11: #d5911a
|
||||||
|
!! blue
|
||||||
|
*color4: #407ee7
|
||||||
|
*color12: #407ee7
|
||||||
|
!! magenta
|
||||||
|
*color5: #6666ea
|
||||||
|
*color13: #6666ea
|
||||||
|
!! cyan
|
||||||
|
*color6: #00ad9c
|
||||||
|
*color14: #00ad9c
|
||||||
|
!! white
|
||||||
|
*color7: #a8a19f
|
||||||
|
*color15: #f1efee
|
||||||
|
|
||||||
|
URxvt.intensityStyles: false
|
||||||
|
URxvt.background: [70]#000000
|
||||||
|
URxvt.depth: 32
|
||||||
|
URxvt.font: xft:monospace:size=11
|
||||||
|
URxvt.scrollBar: false
|
||||||
|
URxvt.cursorColor: white
|
||||||
|
|
||||||
|
!! Extensions
|
||||||
|
URxvt.perl-ext-common: default,matcher,resize-font,url-select,keyboard-select
|
||||||
|
URxvt.colorUL: #4682B4
|
||||||
|
!! url-select
|
||||||
|
URxvt.keysym.M-u: perl:url-select:select_next
|
||||||
|
URxvt.url-select.launcher: webview
|
||||||
|
URxvt.url-select.underline: true
|
||||||
|
!! keyboard-select:
|
||||||
|
URxvt.keysym.M-Escape: perl:keyboard-select:activate
|
||||||
|
!! resize-font
|
||||||
|
URxvt.resize-font.smaller: C-Down
|
||||||
|
URxvt.resize-font.bigger: C-Up
|
||||||
|
!! Matcher
|
||||||
|
URxvt.url-launcher: webview
|
||||||
|
URxvt.matcher.button: 1
|
||||||
|
|
||||||
|
rofi.color-enabled: true
|
||||||
|
rofi.color-window: #000, #000, #000
|
||||||
|
rofi.color-normal: #111, #819396, #222, #008ed4, #ffffff
|
||||||
|
rofi.color-active: #002b37, #008ed4, #003643, #008ed4, #66c6ff
|
||||||
|
rofi.color-urgent: #002b37, #da4281, #003643, #008ed4, #890661
|
||||||
|
|
||||||
|
rofi.fake-transparency: true
|
||||||
|
rofi.lines: 3
|
||||||
|
rofi.bw: 0
|
||||||
|
rofi.opacity: "10"
|
||||||
|
rofi.hide-scrollbar: true
|
||||||
|
rofi.width: 30
|
10
.bash_profile
Normal file
10
.bash_profile
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
#
|
||||||
|
# ~/.bash_profile
|
||||||
|
#
|
||||||
|
|
||||||
|
[[ -f ~/.bashrc ]] && . ~/.bashrc
|
||||||
|
|
||||||
|
export PATH=$PATH:$HOME/.config/Scripts
|
||||||
|
export EDITOR="vim"
|
||||||
|
export TERMINAL="st"
|
||||||
|
export BROWSER="qutebrowser"
|
100
.bashrc
Normal file
100
.bashrc
Normal file
|
@ -0,0 +1,100 @@
|
||||||
|
stty -ixon
|
||||||
|
shopt -s autocd #Allows you to cd into directory merely by typing the directory name.
|
||||||
|
|
||||||
|
# For directory and config shortcuts:
|
||||||
|
source ~/.bash_shortcuts
|
||||||
|
|
||||||
|
# Setting Bash prompt. Capitalizes username and host if root user (my root user uses this same config file).
|
||||||
|
if [ "$EUID" -ne 0 ]
|
||||||
|
then export PS1="\[$(tput bold)\]\[$(tput setaf 1)\][\[$(tput setaf 3)\]\u\[$(tput setaf 2)\]@\[$(tput setaf 4)\]\h \[$(tput setaf 5)\]\W\[$(tput setaf 1)\]]\[$(tput setaf 7)\]\\$ \[$(tput sgr0)\]"
|
||||||
|
else export PS1="\[$(tput bold)\]\[$(tput setaf 1)\][\[$(tput setaf 3)\]ROOT\[$(tput setaf 2)\]@\[$(tput setaf 4)\]$(hostname | awk '{print toupper($0)}') \[$(tput setaf 5)\]\W\[$(tput setaf 1)\]]\[$(tput setaf 7)\]\\$ \[$(tput sgr0)\]"
|
||||||
|
fi
|
||||||
|
|
||||||
|
#Generic shortcuts:
|
||||||
|
alias music="ncmpcpp"
|
||||||
|
alias clock="ncmpcpp -s clock"
|
||||||
|
alias visualizer="ncmpcpp -s visualizer"
|
||||||
|
alias news="newsbeuter"
|
||||||
|
alias email="neomutt"
|
||||||
|
alias files="ranger"
|
||||||
|
alias chat="weechat"
|
||||||
|
alias audio="ncpamixer"
|
||||||
|
alias calender="calcurse"
|
||||||
|
alias getmail="offlineimap && notmuch new"
|
||||||
|
alias gm="offlineimap && notmuch new"
|
||||||
|
|
||||||
|
o() { xdg-open $@ & }
|
||||||
|
|
||||||
|
# System Maintainence
|
||||||
|
alias progs="pacman -Qet" # List programs I've installed
|
||||||
|
alias orphans="pacman -Qdt" # List orphan programs
|
||||||
|
alias upgr="neofetch && sudo pacman -Syyu --noconfirm && echo Update complete. | figlet"
|
||||||
|
alias atltime="sudo timedatectl set-timezone America/New_York && i3 restart" # Eastcoast time
|
||||||
|
alias tuctime="sudo timedatectl set-timezone America/Phoenix && i3 restart" # Arizona time
|
||||||
|
alias sdn="sudo shutdown now"
|
||||||
|
alias newnet="sudo systemctl restart NetworkManager" # Refresh wifi
|
||||||
|
alias nf="clear && neofetch" # Le Redditfetch
|
||||||
|
#Install an AUR package manually (for Parabola to get AUR access):
|
||||||
|
aurinstall() { curl -O https://aur.archlinux.org/cgit/aur.git/snapshot/$1.tar.gz && tar -xvf $1.tar.gz && cd $1 && makepkg --noconfirm -si && cd .. && rm -rf $1 $1.tar.gz ;}
|
||||||
|
alias psref="gpg-connect-agent RELOADAGENT /bye" # Refresh gpg
|
||||||
|
|
||||||
|
# Some aliases
|
||||||
|
alias p="sudo pacman"
|
||||||
|
alias v="vim"
|
||||||
|
alias sv="sudo vim"
|
||||||
|
alias r="ranger"
|
||||||
|
alias sr="sudo ranger"
|
||||||
|
alias ka="killall"
|
||||||
|
alias g="git"
|
||||||
|
alias gitup="git push origin master"
|
||||||
|
alias gitpass="git config --global credential.helper cache"
|
||||||
|
alias tr="transmission-remote"
|
||||||
|
alias mkdir="mkdir -pv"
|
||||||
|
alias rf="source ~/.bashrc"
|
||||||
|
alias ref="~/.config/Scripts/shortcuts.sh && source ~/.bashrc" # Refresh shortcuts manually and reload bashrc
|
||||||
|
alias bars="bash ~/.config/polybar/launch.sh" # Run Polybar relaunch script
|
||||||
|
alias bw="wal -i ~/.config/wall.png" # Rerun pywal
|
||||||
|
weath() { curl wttr.in/$1 ;} # Check the weather (give city or leave blank).
|
||||||
|
|
||||||
|
# Adding color
|
||||||
|
alias ls='ls -hN --color=auto --group-directories-first'
|
||||||
|
alias crep="grep --color=always" # Color grep - highlight desired sequence.
|
||||||
|
alias ccat="highlight --out-format=xterm256" #Color cat - print file with syntax highlighting.
|
||||||
|
|
||||||
|
# Laptop management
|
||||||
|
alias lsc="screen.sh l" # Use laptop screen only
|
||||||
|
alias vsc="screen.sh v" # Use VGA only
|
||||||
|
alias dsc="screen.sh d" # Use both laptop and VGA screen
|
||||||
|
alias debase="sudo umount /home/Shared/Videos & screen.sh l && i3 restart" # Prep for taking my ThinkPad off Ultrabase
|
||||||
|
|
||||||
|
# Internet
|
||||||
|
alias yt="youtube-dl --add-metadata -ic" # Download video link
|
||||||
|
alias yta="youtube-dl --add-metadata -xic" # Download only audio
|
||||||
|
alias YT="youtube-viewer"
|
||||||
|
alias ethspeed="speedometer -r enp0s25"
|
||||||
|
alias wifispeed="speedometer -r wlp3s0"
|
||||||
|
alias starwars="telnet towel.blinkenlights.nl"
|
||||||
|
alias tpbs="clear && figlet -c TPB Search && ~/.config/Scripts/tpb.sh" # Pirate Bay search
|
||||||
|
|
||||||
|
# TeX
|
||||||
|
alias Txa="cp ~/Documents/LaTeX/article.tex"
|
||||||
|
alias Txs="cp ~/Documents/LaTeX/beamer.tex"
|
||||||
|
alias Txh="cp ~/Documents/LaTeX/handout.tex"
|
||||||
|
alias TC='texclear'
|
||||||
|
|
||||||
|
# Audio and Music
|
||||||
|
alias mute="pamixer -m"
|
||||||
|
alias unmute="pamixer -u"
|
||||||
|
alias vu="pamixer --allow-boost -i 5"
|
||||||
|
alias vd="pamixer --allow-boost -d 5"
|
||||||
|
alias pause="mpc toggle"
|
||||||
|
alias next="mpc next"
|
||||||
|
alias prev="mpc prev"
|
||||||
|
alias trupause="mpc pause"
|
||||||
|
alias beg="mpc seek 0%"
|
||||||
|
alias lilbak="mpc seek -10"
|
||||||
|
alias lilfor="mpc seek +10"
|
||||||
|
alias bigbak="mpc seek -120"
|
||||||
|
alias bigfor="mpc seek +120"
|
||||||
|
|
||||||
|
hello-larbs() { sed -i -e '/LARBS/,$d' ~/.config/i3/config ;}
|
25
.calcurse/conf
Normal file
25
.calcurse/conf
Normal file
|
@ -0,0 +1,25 @@
|
||||||
|
appearance.calendarview=monthly
|
||||||
|
appearance.compactpanels=no
|
||||||
|
appearance.defaultpanel=calendar
|
||||||
|
appearance.layout=1
|
||||||
|
appearance.notifybar=yes
|
||||||
|
appearance.sidebarwidth=1
|
||||||
|
appearance.theme=red on default
|
||||||
|
appearance.todoview=show-completed
|
||||||
|
daemon.enable=no
|
||||||
|
daemon.log=no
|
||||||
|
format.inputdate=1
|
||||||
|
format.notifydate=%a %F
|
||||||
|
format.notifytime=%T
|
||||||
|
format.outputdate=%D
|
||||||
|
general.autogc=no
|
||||||
|
general.autosave=yes
|
||||||
|
general.confirmdelete=yes
|
||||||
|
general.confirmquit=no
|
||||||
|
general.firstdayofweek=sunday
|
||||||
|
general.periodicsave=0
|
||||||
|
general.progressbar=yes
|
||||||
|
general.systemdialogs=no
|
||||||
|
notification.command=printf '\a'
|
||||||
|
notification.notifyall=flagged-only
|
||||||
|
notification.warning=300
|
70
.calcurse/keys
Normal file
70
.calcurse/keys
Normal file
|
@ -0,0 +1,70 @@
|
||||||
|
#
|
||||||
|
# Calcurse keys configuration file
|
||||||
|
#
|
||||||
|
# This file sets the keybindings used by Calcurse.
|
||||||
|
# Lines beginning with "#" are comments, and ignored by Calcurse.
|
||||||
|
# To assign a keybinding to an action, this file must contain a line
|
||||||
|
# with the following syntax:
|
||||||
|
#
|
||||||
|
# ACTION KEY1 KEY2 ... KEYn
|
||||||
|
#
|
||||||
|
# Where ACTION is what will be performed when KEY1, KEY2, ..., or KEYn
|
||||||
|
# will be pressed.
|
||||||
|
#
|
||||||
|
# To define bindings which use the CONTROL key, prefix the key with 'C-'.
|
||||||
|
# The escape, space bar and horizontal Tab key can be specified using
|
||||||
|
# the 'ESC', 'SPC' and 'TAB' keyword, respectively.
|
||||||
|
# Arrow keys can also be specified with the UP, DWN, LFT, RGT keywords.
|
||||||
|
# Last, Home and End keys can be assigned using 'KEY_HOME' and 'KEY_END'
|
||||||
|
# keywords.
|
||||||
|
#
|
||||||
|
# A description of what each ACTION keyword is used for is available
|
||||||
|
# from calcurse online configuration menu.
|
||||||
|
|
||||||
|
generic-cancel ESC
|
||||||
|
generic-select SPC
|
||||||
|
generic-credits @
|
||||||
|
generic-help ?
|
||||||
|
generic-quit q Q
|
||||||
|
generic-save s S ^S
|
||||||
|
generic-reload R
|
||||||
|
generic-copy c
|
||||||
|
generic-paste p ^V
|
||||||
|
generic-change-view TAB
|
||||||
|
generic-import i I
|
||||||
|
generic-export x X
|
||||||
|
generic-goto g G
|
||||||
|
generic-other-cmd o O
|
||||||
|
generic-config-menu C
|
||||||
|
generic-redraw ^R
|
||||||
|
generic-add-appt ^A
|
||||||
|
generic-add-todo ^T
|
||||||
|
generic-prev-day T ^H
|
||||||
|
generic-next-day t ^L
|
||||||
|
generic-prev-week W ^K
|
||||||
|
generic-next-week w ^J
|
||||||
|
generic-prev-month M
|
||||||
|
generic-next-month m
|
||||||
|
generic-prev-year Y
|
||||||
|
generic-next-year y
|
||||||
|
generic-scroll-down ^N
|
||||||
|
generic-scroll-up ^P
|
||||||
|
generic-goto-today ^G
|
||||||
|
generic-command :
|
||||||
|
move-right l L RGT
|
||||||
|
move-left h H LFT
|
||||||
|
move-down j J DWN
|
||||||
|
move-up k K UP
|
||||||
|
start-of-week 0
|
||||||
|
end-of-week $
|
||||||
|
add-item a A
|
||||||
|
del-item d D
|
||||||
|
edit-item e E
|
||||||
|
view-item v V
|
||||||
|
pipe-item |
|
||||||
|
flag-item !
|
||||||
|
repeat r
|
||||||
|
edit-note n N
|
||||||
|
view-note >
|
||||||
|
raise-priority +
|
||||||
|
lower-priority -
|
18
.config/Scripts/audio_alsa.sh
Executable file
18
.config/Scripts/audio_alsa.sh
Executable file
|
@ -0,0 +1,18 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
#This is the ffmpeg command that the screencast shortcut in i3 will run.
|
||||||
|
|
||||||
|
#Picks a file name for the output file based on availability:
|
||||||
|
|
||||||
|
while [[ -f $HOME/audio$n.flac ]]
|
||||||
|
do
|
||||||
|
n=$((n+1))
|
||||||
|
done
|
||||||
|
filename="$HOME/audio$n.flac"
|
||||||
|
|
||||||
|
#The actual ffmpeg command:
|
||||||
|
|
||||||
|
ffmpeg -y \
|
||||||
|
-f alsa -ar 44100 -i hw:1 \
|
||||||
|
$filename
|
||||||
|
|
18
.config/Scripts/audio_pulse.sh
Executable file
18
.config/Scripts/audio_pulse.sh
Executable file
|
@ -0,0 +1,18 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
#This is the ffmpeg command that the audio shortcut in i3 will run.
|
||||||
|
|
||||||
|
#Picks a file name for the output file based on availability:
|
||||||
|
|
||||||
|
while [[ -f $HOME/audio$n.flac ]]
|
||||||
|
do
|
||||||
|
n=$((n+1))
|
||||||
|
done
|
||||||
|
filename="$HOME/audio$n.flac"
|
||||||
|
|
||||||
|
#The actual ffmpeg command:
|
||||||
|
|
||||||
|
ffmpeg \
|
||||||
|
-f alsa -i default \
|
||||||
|
-c:a flac \
|
||||||
|
$filename
|
1
.config/Scripts/clear.sh
Executable file
1
.config/Scripts/clear.sh
Executable file
|
@ -0,0 +1 @@
|
||||||
|
find . -maxdepth 1 -regextype gnu-awk -regex "^.*\.(pyc|p yo|bak|swp|aux|log|lof|nav|out|snm|toc|bcf|run\.xml|synctex\.gz|blg|bbl)" -delete
|
17
.config/Scripts/configs
Normal file
17
.config/Scripts/configs
Normal file
|
@ -0,0 +1,17 @@
|
||||||
|
cfb ~/.bashrc
|
||||||
|
cfz ~/.zshrc
|
||||||
|
cfv ~/.vimrc
|
||||||
|
cfr ~/.config/ranger/rc.conf
|
||||||
|
cfi ~/.config/i3/config
|
||||||
|
cfq ~/.config/qutebrowser/config.py
|
||||||
|
cfm ~/.config/mutt/muttrc
|
||||||
|
cfM ~/.config/moc/keymap
|
||||||
|
cff ~/.config/Scripts/folders
|
||||||
|
cfc ~/.config/Scripts/configs
|
||||||
|
cft ~/.config/termite/config
|
||||||
|
cfT ~/.tmux.conf
|
||||||
|
eb ~/Documents/LaTeX/uni.bib
|
||||||
|
cv ~/Documents/LaTeX/cv.tex
|
||||||
|
cfa ~/.config/mutt/aliases
|
||||||
|
cfp ~/.config/polybar/config
|
||||||
|
cfd ~/.Xdefaults
|
30
.config/Scripts/extract
Executable file
30
.config/Scripts/extract
Executable file
|
@ -0,0 +1,30 @@
|
||||||
|
#!/bin/bash
|
||||||
|
# there are two different ways this script can work.
|
||||||
|
# for the first way, uncomment the two lines after the if and place two '.' in front of the /$1
|
||||||
|
# this creates a new directory in the directory where the compressed file is and dumps the content in it
|
||||||
|
# for the second way, comment the two lines under the if and place just one '.' in front of the /$1
|
||||||
|
# this just dumps the content of the compressed file in the same directory of the compressed file
|
||||||
|
if [ -f $1 ] ; then
|
||||||
|
NAME=${1%.*}
|
||||||
|
mkdir $NAME && cd $NAME
|
||||||
|
case $1 in
|
||||||
|
*.tar.bz2) tar xvjf ../$1 ;;
|
||||||
|
*.tar.gz) tar xvzf ../$1 ;;
|
||||||
|
*.tar.xz) tar xvJf ../$1 ;;
|
||||||
|
*.lzma) unlzma ../$1 ;;
|
||||||
|
*.bz2) bunzip2 ../$1 ;;
|
||||||
|
*.rar) unrar x -ad ../$1 ;;
|
||||||
|
*.gz) gunzip ../$1 ;;
|
||||||
|
*.tar) tar xvf ../$1 ;;
|
||||||
|
*.tbz2) tar xvjf ../$1 ;;
|
||||||
|
*.tgz) tar xvzf ../$1 ;;
|
||||||
|
*.zip) unzip ../$1 ;;
|
||||||
|
*.Z) uncompress ../$1 ;;
|
||||||
|
*.7z) 7z x ../$1 ;;
|
||||||
|
*.xz) unxz ../$1 ;;
|
||||||
|
*.exe) cabextract ../$1 ;;
|
||||||
|
*) echo "extract: '$1' - unknown archive method" ;;
|
||||||
|
esac
|
||||||
|
else
|
||||||
|
echo "$1 - file does not exist"
|
||||||
|
fi
|
13
.config/Scripts/flash_win.sh
Normal file
13
.config/Scripts/flash_win.sh
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
#Flashes the active window.
|
||||||
|
|
||||||
|
#Requires transset-df and a composite manager, like xcompmgr.
|
||||||
|
|
||||||
|
transset -a -m 0
|
||||||
|
sleep .1
|
||||||
|
transset -a -x 1
|
||||||
|
sleep .1
|
||||||
|
transset -a -m 0
|
||||||
|
sleep .1
|
||||||
|
transset -a -x 1
|
10
.config/Scripts/folders
Normal file
10
.config/Scripts/folders
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
h ~
|
||||||
|
d ~/Documents
|
||||||
|
D ~/Downloads
|
||||||
|
pp ~/Pictures
|
||||||
|
vv ~/Videos
|
||||||
|
m ~/Music
|
||||||
|
b ~/Books
|
||||||
|
s ~/.config/Scripts
|
||||||
|
r /
|
||||||
|
cf ~/.config
|
93
.config/Scripts/offlineimap-daemon.py
Executable file
93
.config/Scripts/offlineimap-daemon.py
Executable file
|
@ -0,0 +1,93 @@
|
||||||
|
#!/usr/bin/env python3
|
||||||
|
|
||||||
|
import subprocess
|
||||||
|
import signal
|
||||||
|
import threading
|
||||||
|
import sys
|
||||||
|
|
||||||
|
import dbus
|
||||||
|
from dbus.mainloop.glib import DBusGMainLoop
|
||||||
|
from gi.repository import GLib
|
||||||
|
|
||||||
|
|
||||||
|
class OfflineimapCtl(object):
|
||||||
|
def __init__(self):
|
||||||
|
self.daemon_proc = None
|
||||||
|
self.run_ev = threading.Event()
|
||||||
|
self.run_daemon = False
|
||||||
|
|
||||||
|
def run(self):
|
||||||
|
t = threading.Thread(target=self._watch_daemon, daemon=True)
|
||||||
|
t.start()
|
||||||
|
|
||||||
|
def _watch_daemon(self):
|
||||||
|
while True:
|
||||||
|
self.run_ev.wait()
|
||||||
|
self.run_ev.clear()
|
||||||
|
if self.run_daemon:
|
||||||
|
self.is_running = True
|
||||||
|
print('offlineimap is being started')
|
||||||
|
self._spawn_daemon()
|
||||||
|
print('offlineimap has stopped')
|
||||||
|
self.run_ev.set() # check state and restart if needed
|
||||||
|
|
||||||
|
def _spawn_daemon(self):
|
||||||
|
self.daemon_proc = subprocess.Popen(['offlineimap', '-u', 'basic'], shell=False)
|
||||||
|
self.daemon_proc.wait()
|
||||||
|
self.daemon_proc = None
|
||||||
|
|
||||||
|
def start(self):
|
||||||
|
print('starting offlineimap')
|
||||||
|
self.run_daemon = True
|
||||||
|
self.run_ev.set()
|
||||||
|
|
||||||
|
def stop(self):
|
||||||
|
print('stopping offlineimap')
|
||||||
|
self.run_daemon = False
|
||||||
|
if self.daemon_proc:
|
||||||
|
try:
|
||||||
|
self.daemon_proc.send_signal(signal.SIGUSR2)
|
||||||
|
except OSError:
|
||||||
|
print('Unable to stop offlineimap')
|
||||||
|
|
||||||
|
def restart(self):
|
||||||
|
print('restarting offlineimap')
|
||||||
|
if self.run_daemon:
|
||||||
|
self.stop()
|
||||||
|
self.start()
|
||||||
|
|
||||||
|
def onConnectivityChanged(self, state):
|
||||||
|
# 70 means fully connected
|
||||||
|
if state == 70:
|
||||||
|
self.start()
|
||||||
|
else:
|
||||||
|
self.stop()
|
||||||
|
|
||||||
|
def main():
|
||||||
|
oi_ctl = OfflineimapCtl()
|
||||||
|
oi_ctl.run()
|
||||||
|
|
||||||
|
try:
|
||||||
|
bus = dbus.SystemBus(mainloop=DBusGMainLoop())
|
||||||
|
network_manager = bus.get_object(
|
||||||
|
'org.freedesktop.NetworkManager',
|
||||||
|
'/org/freedesktop/NetworkManager')
|
||||||
|
network = dbus.Interface(network_manager,
|
||||||
|
dbus_interface='org.freedesktop.NetworkManager')
|
||||||
|
|
||||||
|
network.connect_to_signal('StateChanged', oi_ctl.onConnectivityChanged)
|
||||||
|
|
||||||
|
# send current state as first event
|
||||||
|
state = network.state()
|
||||||
|
oi_ctl.onConnectivityChanged(state)
|
||||||
|
|
||||||
|
except dbus.exceptions.DBusException:
|
||||||
|
print('Unable to connect to dbus')
|
||||||
|
sys.exit(3)
|
||||||
|
|
||||||
|
# start receiving events from dbus
|
||||||
|
loop = GLib.MainLoop()
|
||||||
|
loop.run()
|
||||||
|
|
||||||
|
if __name__ == '__main__':
|
||||||
|
main()
|
40
.config/Scripts/offlineimap-daemonctl.sh
Executable file
40
.config/Scripts/offlineimap-daemonctl.sh
Executable file
|
@ -0,0 +1,40 @@
|
||||||
|
#!/bin/sh
|
||||||
|
# this script runs offline imap as daemon (configured to check periodically)
|
||||||
|
|
||||||
|
LOG=~/.offlineimap/sync.log
|
||||||
|
PIDFILE=~/.offlineimap/pid
|
||||||
|
|
||||||
|
# if not present on PATH, those vars must point to proper locations
|
||||||
|
THIS_SCRIPT=offlineimap-daemonctl.sh
|
||||||
|
PYTHON_DAEMON=offlineimap-daemon.py
|
||||||
|
|
||||||
|
daemon(){
|
||||||
|
$PYTHON_DAEMON 2>&1 |
|
||||||
|
# add timestamps to logs
|
||||||
|
(while read line; do
|
||||||
|
echo `date` "$line" >> $LOG
|
||||||
|
done)
|
||||||
|
}
|
||||||
|
|
||||||
|
stop(){
|
||||||
|
kill -USR2 `cat $PIDFILE`
|
||||||
|
}
|
||||||
|
|
||||||
|
refresh(){
|
||||||
|
kill -USR1 `cat $PIDFILE`
|
||||||
|
}
|
||||||
|
|
||||||
|
case "$1" in
|
||||||
|
'--daemon' | '-d' )
|
||||||
|
nohup $THIS_SCRIPT < /dev/null > /dev/null 2>&1 &
|
||||||
|
;;
|
||||||
|
'--kill' | '-k' )
|
||||||
|
stop
|
||||||
|
;;
|
||||||
|
'--refresh' | '-r' )
|
||||||
|
refresh
|
||||||
|
;;
|
||||||
|
* )
|
||||||
|
daemon
|
||||||
|
;;
|
||||||
|
esac
|
1
.config/Scripts/remaps
Normal file
1
.config/Scripts/remaps
Normal file
|
@ -0,0 +1 @@
|
||||||
|
keycode 135 = Super_R NoSymbol Super_R
|
169
.config/Scripts/resize-font
Normal file
169
.config/Scripts/resize-font
Normal file
|
@ -0,0 +1,169 @@
|
||||||
|
# vim:ft=perl:fenc=utf-8
|
||||||
|
# Copyright (c) 2009-, Simon Lundström <simmel@soy.se>
|
||||||
|
# Copyright (c) 2014 Maarten de Vries <maarten@de-vri.es>
|
||||||
|
#
|
||||||
|
# Permission to use, copy, modify, and/or distribute this software for any
|
||||||
|
# purpose with or without fee is hereby granted, provided that the above
|
||||||
|
# copyright notice and this permission notice appear in all copies.
|
||||||
|
#
|
||||||
|
# THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||||
|
# WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||||
|
# MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||||
|
# ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||||
|
# WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||||
|
# ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||||
|
# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||||
|
|
||||||
|
# Usage:
|
||||||
|
# Set your font in ~/.Xresources:
|
||||||
|
# urxvt.font: xft:Inconsolata:pixelsize=12
|
||||||
|
# to set it with pixels or
|
||||||
|
# urxvt.font: xft:Inconsolata:size=12
|
||||||
|
# to set it with points.
|
||||||
|
|
||||||
|
# And re-bind some keymappings (if you want, below are the defaults):
|
||||||
|
# URxvt.keysym.C-minus: resize-font:smaller
|
||||||
|
# URxvt.keysym.C-plus: resize-font:bigger
|
||||||
|
# URxvt.keysym.C-equal: resize-font:reset
|
||||||
|
# URxvt.keysym.C-question: resize-font:show
|
||||||
|
#
|
||||||
|
|
||||||
|
my @fonts = (
|
||||||
|
{'name' => 'font', 'code' => 710},
|
||||||
|
{'name' => 'boldFont', 'code' => 711},
|
||||||
|
{'name' => 'italicFont', 'code' => 712},
|
||||||
|
{'name' => 'boldItalicFont', 'code' => 713},
|
||||||
|
);
|
||||||
|
|
||||||
|
my @fixed = qw(4x6 5x7 5x8 6x9 6x10 6x12 6x13 7x13 7x14 8x13 8x16 9x15 9x18 10x20 12x24);
|
||||||
|
|
||||||
|
sub on_start {
|
||||||
|
my ($self) = @_;
|
||||||
|
|
||||||
|
foreach (@fonts) {
|
||||||
|
$_->{'default'} = $self->resource($_->{'name'});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
sub on_init {
|
||||||
|
my ($self) = @_;
|
||||||
|
my $commands = {
|
||||||
|
"smaller" => "C-minus",
|
||||||
|
"bigger" => "C-plus",
|
||||||
|
"reset" => "C-equal",
|
||||||
|
"show" => "C-question",
|
||||||
|
};
|
||||||
|
bind_hotkeys($self, $commands);
|
||||||
|
|
||||||
|
()
|
||||||
|
}
|
||||||
|
|
||||||
|
sub bind_hotkeys {
|
||||||
|
my ($self, $commands) = @_;
|
||||||
|
|
||||||
|
for (keys %$commands) {
|
||||||
|
my $hotkey = $$commands{$_};
|
||||||
|
my $hotkey_bound = $self->{'term'}->x_resource("keysym.$hotkey");
|
||||||
|
if (!defined($hotkey_bound) ) {
|
||||||
|
# Support old-style key bindings
|
||||||
|
if ($self->x_resource("%.$_")) {
|
||||||
|
$hotkey = $self->x_resource("%.$_");
|
||||||
|
}
|
||||||
|
|
||||||
|
# FIXME If we're bound to a keysym, don't bind the default.
|
||||||
|
$self->bind_action($hotkey, "%:$_") or
|
||||||
|
warn "unable to register '$hotkey' as hotkey for $_";
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
if ($hotkey_bound !~ /^resize-font:/) {
|
||||||
|
warn "Hotkey $$commands{$_} already bound to $hotkey_bound, not binding to resize-font:$_ by default.";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
sub on_action {
|
||||||
|
my ($self, $string) = @_;
|
||||||
|
my $regex = qr"(?!pixelsize=)(\d+)";
|
||||||
|
|
||||||
|
if ($string eq "bigger") {
|
||||||
|
foreach (@fonts) {
|
||||||
|
next if not defined($_->{'default'});
|
||||||
|
update_font_size($self, $_, +2);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
elsif ($string eq "smaller") {
|
||||||
|
foreach (@fonts) {
|
||||||
|
next if not defined($_->{'default'});
|
||||||
|
update_font_size($self, $_, -2);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
elsif ($string eq "reset") {
|
||||||
|
foreach (@fonts) {
|
||||||
|
next if not defined($_->{'default'});
|
||||||
|
set_font($self, $_, $_->{'default'});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
elsif ($string eq "show") {
|
||||||
|
|
||||||
|
my $term = $self->{'term'};
|
||||||
|
$term->{'resize-font'}{'overlay'} = {
|
||||||
|
ov => $term->overlay_simple(0, -1, format_font_info($self)),
|
||||||
|
to => urxvt::timer
|
||||||
|
->new
|
||||||
|
->start(urxvt::NOW + 1)
|
||||||
|
->cb(sub {
|
||||||
|
delete $term->{'resize-font'}{'overlay'};
|
||||||
|
}),
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
()
|
||||||
|
}
|
||||||
|
|
||||||
|
sub get_font {
|
||||||
|
my ($self, $name) = @_;
|
||||||
|
return $self->resource($name);
|
||||||
|
}
|
||||||
|
|
||||||
|
sub set_font {
|
||||||
|
my ($self, $font, $new) = @_;
|
||||||
|
$self->cmd_parse(sprintf("\33]%d;%s\007", $font->{'code'}, $new));
|
||||||
|
}
|
||||||
|
|
||||||
|
sub update_font_size {
|
||||||
|
my ($self, $font, $delta) = @_;
|
||||||
|
my $regex = qr"(?<=size=)(\d+)";
|
||||||
|
my $current = get_font($self, $font->{'name'});
|
||||||
|
|
||||||
|
my ($index) = grep { $fixed[$_] eq $current } 0..$#fixed;
|
||||||
|
if ($index or $index eq 0) {
|
||||||
|
my $inc = $delta / abs($delta);
|
||||||
|
$index += $inc;
|
||||||
|
if ($index < 0) { $index = 0; }
|
||||||
|
if ($index > $#fixed) { $index = $#fixed; }
|
||||||
|
$current = $fixed[$index];
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$current =~ s/$regex/$1+$delta/ge;
|
||||||
|
}
|
||||||
|
set_font($self, $font, $current);
|
||||||
|
}
|
||||||
|
|
||||||
|
sub format_font_info {
|
||||||
|
my ($self) = @_;
|
||||||
|
|
||||||
|
my $width = 0;
|
||||||
|
foreach (@fonts) {
|
||||||
|
my $length = length($_->{'name'});
|
||||||
|
$width = $length > $width ? $length : $width;
|
||||||
|
}
|
||||||
|
++$width;
|
||||||
|
|
||||||
|
my $info = '';
|
||||||
|
foreach (@fonts) {
|
||||||
|
$info .= sprintf("%-${width}s %s\n", $_->{'name'} . ':', get_font($self, $_->{'name'}));
|
||||||
|
}
|
||||||
|
|
||||||
|
return $info;
|
||||||
|
}
|
24
.config/Scripts/screen.sh
Executable file
24
.config/Scripts/screen.sh
Executable file
|
@ -0,0 +1,24 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
#Feed this script either:
|
||||||
|
# "l" for laptop screen only,
|
||||||
|
# "v" for vga screen only,
|
||||||
|
# or "d" for dual vga/laptop.
|
||||||
|
|
||||||
|
d() { if [[ $(xrandr -q | grep VGA1\ con) ]]
|
||||||
|
then param $1
|
||||||
|
else echo "No VGA input detected."
|
||||||
|
fi ;}
|
||||||
|
dual() { xrandr --output LVDS1 --auto --output VGA1 --auto --right-of LVDS1 ;}
|
||||||
|
laptop() { xrandr --output LVDS1 --auto --output VGA1 --off ;}
|
||||||
|
vga() { xrandr --output VGA1 --auto --output LVDS1 --off ;}
|
||||||
|
#mirror() { xrandr --addmode VGA1 $lapres && xrandr --output LVDS1 --mode $lapres --output VGA1 --mode $lapres ;}
|
||||||
|
|
||||||
|
param() {
|
||||||
|
case $1 in
|
||||||
|
d) dual ;;
|
||||||
|
v) vga ;;
|
||||||
|
l) laptop ;;
|
||||||
|
*) echo -e "Invalid parameter. Add one of the following:\n\"d\" for dualscreen laptop and VGA.\n\"l\" for laptop only\n\"v\" for VGA only." ;;
|
||||||
|
esac ;}
|
||||||
|
d $1
|
22
.config/Scripts/screencast_alsa.sh
Executable file
22
.config/Scripts/screencast_alsa.sh
Executable file
|
@ -0,0 +1,22 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
#This is the ffmpeg command that the screencast shortcut in i3 will run.
|
||||||
|
|
||||||
|
#Picks a file name for the output file based on availability:
|
||||||
|
|
||||||
|
while [[ -f $HOME/screencast$n.mkv ]]
|
||||||
|
do
|
||||||
|
n=$((n+1))
|
||||||
|
done
|
||||||
|
filename="$HOME/screencast$n.mkv"
|
||||||
|
|
||||||
|
#The actual ffmpeg command:
|
||||||
|
|
||||||
|
ffmpeg -y \
|
||||||
|
-f x11grab \
|
||||||
|
-s $(xdpyinfo | grep dimensions | awk '{print $2;}') \
|
||||||
|
-i :0.0 \
|
||||||
|
-thread_queue_size 1024 \
|
||||||
|
-f alsa -ar 44100 -i hw:1 \
|
||||||
|
-c:v libx264 -r 30 -c:a flac $filename
|
||||||
|
#-c:v ffvhuff -r 30 -c:a flac $filename
|
22
.config/Scripts/screencast_pulse.sh
Executable file
22
.config/Scripts/screencast_pulse.sh
Executable file
|
@ -0,0 +1,22 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
#This is the ffmpeg command that the screencast shortcut in i3 will run.
|
||||||
|
|
||||||
|
#Picks a file name for the output file based on availability:
|
||||||
|
|
||||||
|
while [[ -f $HOME/screencast$n.mkv ]]
|
||||||
|
do
|
||||||
|
n=$((n+1))
|
||||||
|
done
|
||||||
|
filename="$HOME/screencast$n.mkv"
|
||||||
|
|
||||||
|
#The actual ffmpeg command:
|
||||||
|
|
||||||
|
ffmpeg -y \
|
||||||
|
-f x11grab \
|
||||||
|
-s $(xdpyinfo | grep dimensions | awk '{print $2;}') \
|
||||||
|
-i :0.0 \
|
||||||
|
-f alsa -i default \
|
||||||
|
-c:v libx264 -r 30 -c:a flac $filename
|
||||||
|
#-c:v ffvhuff -r 30 -c:a flac $filename
|
||||||
|
#-f pulse -ac 1 -ar 44100 -i default \
|
62
.config/Scripts/shortcuts.sh
Executable file
62
.config/Scripts/shortcuts.sh
Executable file
|
@ -0,0 +1,62 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# Config locations
|
||||||
|
folders="$HOME/.config/Scripts/folders"
|
||||||
|
configs="$HOME/.config/Scripts/configs"
|
||||||
|
|
||||||
|
# Output locations
|
||||||
|
bash_shortcuts="$HOME/.bash_shortcuts"
|
||||||
|
ranger_shortcuts="$HOME/.config/ranger/shortcuts.conf"
|
||||||
|
qute_shortcuts="$HOME/.config/qutebrowser/shortcuts.py"
|
||||||
|
|
||||||
|
# Ensuring that output locations are properly sourced
|
||||||
|
cat ~/.bashrc | grep "source ~/.bash_shortcuts" >/dev/null &&
|
||||||
|
echo Bashrc already ready. ||
|
||||||
|
(echo "source ~/.bash_shortcuts" >> ~/.bashrc &&
|
||||||
|
echo Bashrc now prepared for shortcuts.)
|
||||||
|
|
||||||
|
cat ~/.config/ranger/rc.conf | grep "source ~/.config/ranger/shortcuts.conf" >/dev/null &&
|
||||||
|
echo Rc.conf already ready. ||
|
||||||
|
(echo "source ~/.config/ranger/shortcuts.conf" >> ~/.config/ranger/rc.conf &&
|
||||||
|
echo rc.conf now prepared for shortcuts.)
|
||||||
|
|
||||||
|
cat ~/.config/qutebrowser/config.py | grep shortcuts.py >/dev/null &&
|
||||||
|
echo "Qutebrowser's config.py already ready." ||
|
||||||
|
(echo "config.source('shortcuts.py')" >> ~/.config/qutebrowser/config.py &&
|
||||||
|
echo "qutebrowser's config.py now prepared for shortcuts.")
|
||||||
|
|
||||||
|
#Delete old shortcuts
|
||||||
|
echo "# vim: filetype=sh" > $bash_shortcuts
|
||||||
|
echo "# ranger shortcuts" > $ranger_shortcuts
|
||||||
|
echo "# qutebrowser shortcuts" > $qute_shortcuts
|
||||||
|
|
||||||
|
writeDirs() { echo "alias $1='cd $2 && ls -a'" >> $bash_shortcuts
|
||||||
|
echo "map g$1 cd $2" >> $ranger_shortcuts
|
||||||
|
echo "map t$1 tab_new $2" >> $ranger_shortcuts
|
||||||
|
echo "map m$1 shell mv %s $2" >> $ranger_shortcuts
|
||||||
|
echo "map Y$1 shell cp -r %s $2" >> $ranger_shortcuts
|
||||||
|
echo "config.bind(';$1', 'set downloads.location.directory $2 ;; hint links download')" >> $qute_shortcuts ;}
|
||||||
|
|
||||||
|
writeConfs() {
|
||||||
|
echo "alias $1='vim $2'" >> $bash_shortcuts
|
||||||
|
echo "map $1 shell vim $2" >> $ranger_shortcuts ;}
|
||||||
|
|
||||||
|
IFS=$'\n'
|
||||||
|
set -f
|
||||||
|
for line in $(cat "$folders"); do
|
||||||
|
line=$(echo $line | sed 's/#.*//')
|
||||||
|
key=$(echo $line | awk '{print $1}')
|
||||||
|
dir=$(echo $line | awk '{print $2}')
|
||||||
|
[ "$dir" == "" ] || writeDirs $key $dir
|
||||||
|
done && echo "Directory shortcuts done."
|
||||||
|
|
||||||
|
set -f
|
||||||
|
for line in $(cat "$configs");
|
||||||
|
do
|
||||||
|
line=$(echo $line | sed 's/#.*//')
|
||||||
|
short=$(echo $line | awk '{print $1}')
|
||||||
|
conf=$(echo $line | awk '{print $2}')
|
||||||
|
[ "$conf" == "" ] || writeConfs $short $conf
|
||||||
|
done && echo "Config file shortcuts done."
|
||||||
|
|
||||||
|
echo "All done!"
|
7
.config/Scripts/speedvid.sh
Executable file
7
.config/Scripts/speedvid.sh
Executable file
|
@ -0,0 +1,7 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
base=$(basename $1)
|
||||||
|
ext="${base##*.}"
|
||||||
|
base="${base%.*}"
|
||||||
|
|
||||||
|
ffmpeg -i $1 -vf "setpts=$2*PTS" -an $base'_sped.'$ext
|
7
.config/Scripts/transmission.sh
Executable file
7
.config/Scripts/transmission.sh
Executable file
|
@ -0,0 +1,7 @@
|
||||||
|
#!/bin/bash
|
||||||
|
if [ -f $(pgrep transmission) ];
|
||||||
|
then
|
||||||
|
urxvt -e transmission-remote-cli
|
||||||
|
else
|
||||||
|
transmission-daemon && urxvt -e transmission-remote-cli
|
||||||
|
fi
|
21
.config/Scripts/video.sh
Executable file
21
.config/Scripts/video.sh
Executable file
|
@ -0,0 +1,21 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
#This is the ffmpeg command that the screencast shortcut in i3 will run.
|
||||||
|
|
||||||
|
#Picks a file name for the output file based on availability:
|
||||||
|
|
||||||
|
while [[ -f $HOME/video$n.mkv ]]
|
||||||
|
do
|
||||||
|
n=$((n+1))
|
||||||
|
done
|
||||||
|
filename="$HOME/video$n.mkv"
|
||||||
|
|
||||||
|
|
||||||
|
#The actual ffmpeg command:
|
||||||
|
|
||||||
|
ffmpeg \
|
||||||
|
-f x11grab \
|
||||||
|
-s $(xdpyinfo | grep dimensions | awk '{print $2;}') \
|
||||||
|
-i :0.0 \
|
||||||
|
-c:v libx264 -qp 0 -r 30 $filename
|
||||||
|
#-c:v ffvhuff -r 30 -c:a flac $filename
|
23
.config/Scripts/webview
Executable file
23
.config/Scripts/webview
Executable file
|
@ -0,0 +1,23 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# Feed script a url.
|
||||||
|
# Opens the url with xdg-open unless it is an image,
|
||||||
|
# in which case it downloads in feh.
|
||||||
|
|
||||||
|
ext="${1##*.}"
|
||||||
|
mpvFiles="mkv mp4 gif"
|
||||||
|
fehFiles="png jpg jpeg jpe"
|
||||||
|
wgetFiles="mp3 flac opus mp3?source=feed pdf"
|
||||||
|
|
||||||
|
pgrep i3 ifi3="i3 exec"
|
||||||
|
|
||||||
|
if echo $fehFiles | grep -w $ext > /dev/null; then
|
||||||
|
nohup feh "$1" >/dev/null &
|
||||||
|
#elif [[ "$ext" == "gif" ]]; then
|
||||||
|
elif echo $mpvFiles | grep -w $ext > /dev/null; then
|
||||||
|
nohup mpv --loop --quiet "$1" > /dev/null &
|
||||||
|
elif echo $wgetFiles | grep -w $ext > /dev/null; then
|
||||||
|
nohup wget "$1" >/dev/null &
|
||||||
|
else
|
||||||
|
nohup $BROWSER "$1" >/dev/null &
|
||||||
|
fi
|
4
.config/Scripts/welcome
Executable file
4
.config/Scripts/welcome
Executable file
|
@ -0,0 +1,4 @@
|
||||||
|
#!/bin/bash
|
||||||
|
dialog --title "Welcome to LARBS!" --msgbox "If you're new to the system, hold down the Windows key and press F1 for a full tutorial!
|
||||||
|
|
||||||
|
(This infobox will greet you at each login until you run the command \"hello-larbs\" in the terminal.)" 10 60
|
56
.config/compton.conf
Normal file
56
.config/compton.conf
Normal file
|
@ -0,0 +1,56 @@
|
||||||
|
# vim: filetype=conf
|
||||||
|
backend = "glx";
|
||||||
|
paint-on-overlay = true;
|
||||||
|
glx-no-stencil = true;
|
||||||
|
glx-no-rebind-pixmap = true;
|
||||||
|
vsync = "opengl-swc";
|
||||||
|
|
||||||
|
# These are important. The first one enables the opengl backend. The last one is the vsync method. Depending on the driver you might need to use a different method.
|
||||||
|
# The other options are smaller performance tweaks that work well in most cases.
|
||||||
|
# You can find the rest of the options here: https://github.com/chjj/compton/wiki/perf-guide, and here: https://github.com/chjj/compton/wiki/vsync-guide
|
||||||
|
|
||||||
|
|
||||||
|
# Shadow
|
||||||
|
shadow = true; # Enabled client-side shadows on windows.
|
||||||
|
no-dock-shadow = true; # Avoid drawing shadows on dock/panel windows.
|
||||||
|
no-dnd-shadow = true; # Don't draw shadows on DND windows.
|
||||||
|
clear-shadow = true; # Zero the part of the shadow's mask behind the window (experimental).
|
||||||
|
shadow-radius = 7; # The blur radius for shadows. (default 12)
|
||||||
|
shadow-offset-x = -7; # The left offset for shadows. (default -15)
|
||||||
|
shadow-offset-y = -7; # The top offset for shadows. (default -15)
|
||||||
|
shadow-exclude = [
|
||||||
|
"! name~=''",
|
||||||
|
"n:e:Notification",
|
||||||
|
"n:e:Plank",
|
||||||
|
"n:e:Docky",
|
||||||
|
"g:e:Synapse",
|
||||||
|
"g:e:Kupfer",
|
||||||
|
"g:e:WC_Cronograph",
|
||||||
|
"g:e:Conky",
|
||||||
|
"n:w:*Firefox*",
|
||||||
|
"n:w:*Chrome*",
|
||||||
|
"n:w:*Chromium*",
|
||||||
|
"class_g ?= 'Notify-osd'",
|
||||||
|
"class_g ?= 'Cairo-dock'",
|
||||||
|
"class_g ?= 'Xfce4-notifyd'",
|
||||||
|
"class_g ?= 'Xfce4-power-manager'"
|
||||||
|
];
|
||||||
|
|
||||||
|
# The shadow exclude options are helpful if you have shadows enabled. Due to the way compton draws its shadows, certain applications will have visual glitches
|
||||||
|
# (most applications are fine, only apps that do weird things with xshapes or argb are affected).
|
||||||
|
# This list includes all the affected apps I found in my testing. The "! name~=''" part excludes shadows on any "Unknown" windows, this prevents a visual glitch with the XFWM alt tab switcher.
|
||||||
|
|
||||||
|
# Fading
|
||||||
|
fading = false; # Fade windows during opacity changes.
|
||||||
|
fade-delta = 4; # The time between steps in a fade in milliseconds. (default 10).
|
||||||
|
fade-in-step = 0.03; # Opacity change between steps while fading in. (default 0.028).
|
||||||
|
fade-out-step = 0.03; # Opacity change between steps while fading out. (default 0.03).
|
||||||
|
#no-fading-openclose = true; # Fade windows in/out when opening/closing
|
||||||
|
|
||||||
|
detect-client-opacity = true; # This prevents opacity being ignored for some apps. For example without this enabled my xfce4-notifyd is 100% opacity no matter what.
|
||||||
|
|
||||||
|
# Window type settings
|
||||||
|
wintypes:
|
||||||
|
{
|
||||||
|
tooltip = { fade = true; shadow = false; };
|
||||||
|
};
|
12
.config/feh/keys
Executable file
12
.config/feh/keys
Executable file
|
@ -0,0 +1,12 @@
|
||||||
|
zoom_in K XF86Forward
|
||||||
|
zoom_out J XF86Back
|
||||||
|
next_img L space
|
||||||
|
prev_img BackSpace H
|
||||||
|
|
||||||
|
scroll_up k Up
|
||||||
|
scroll_down j Down
|
||||||
|
scroll_right l Right
|
||||||
|
scroll_left h Left
|
||||||
|
|
||||||
|
toggle_fullscreen f
|
||||||
|
save_filelist F
|
24
.config/fontconfig/fonts.conf
Executable file
24
.config/fontconfig/fonts.conf
Executable file
|
@ -0,0 +1,24 @@
|
||||||
|
<?xml version='1.0'?>
|
||||||
|
<!DOCTYPE fontconfig SYSTEM 'fonts.dtd'>
|
||||||
|
<fontconfig>
|
||||||
|
|
||||||
|
<alias>
|
||||||
|
<family>serif</family>
|
||||||
|
<prefer><family>Tinos</family></prefer>
|
||||||
|
</alias>
|
||||||
|
<alias>
|
||||||
|
<family>sans-serif</family>
|
||||||
|
<prefer><family>Arimo</family></prefer>
|
||||||
|
</alias>
|
||||||
|
<alias>
|
||||||
|
<family>sans</family>
|
||||||
|
<prefer><family>Arimo</family></prefer>
|
||||||
|
</alias>
|
||||||
|
<alias>
|
||||||
|
<family>monospace</family>
|
||||||
|
<prefer><family>Tamzen</family></prefer>
|
||||||
|
</alias>
|
||||||
|
|
||||||
|
</fontconfig>
|
||||||
|
|
||||||
|
|
475
.config/i3/config
Normal file
475
.config/i3/config
Normal file
|
@ -0,0 +1,475 @@
|
||||||
|
# vim: filetype=i3
|
||||||
|
|
||||||
|
# This is Luke Smith's i3-gaps configuration file.
|
||||||
|
# Me: http://lukesmith.xyz
|
||||||
|
# Email: luke@lukesmith.xyz
|
||||||
|
# YouTube: https://youtube.com/c/LukeSmithxyz
|
||||||
|
# Github: https://github.com/LukeSmithxyz
|
||||||
|
|
||||||
|
# Be sure that you have your $BROWSER environmental variable set to your favorite browser.
|
||||||
|
# E.g., put `export BROWSER="firefox"` into your bash_profile
|
||||||
|
|
||||||
|
# #---Basic Definitions---# #
|
||||||
|
#Needed for i3-gaps
|
||||||
|
for_window [class="^.*"] border pixel 3
|
||||||
|
gaps inner 15
|
||||||
|
gaps outer 15
|
||||||
|
font pango:mono 9
|
||||||
|
set $mod Mod4
|
||||||
|
set $term --no-startup-id st
|
||||||
|
set $video --no-startup-id bash ~/.config/Scripts/video.sh
|
||||||
|
set $stoprec --no-startup-id killall ffmpeg & killall screenkey
|
||||||
|
|
||||||
|
|
||||||
|
# #---Starting External Scripts---# #
|
||||||
|
#Music player daemon:
|
||||||
|
exec --no-startup-id mpd
|
||||||
|
#Torrent daemon:
|
||||||
|
exec --no-startup-id transmission-daemon
|
||||||
|
#Mount other drives:
|
||||||
|
exec --no-startup-id sudo mount -a
|
||||||
|
#Composite manager:
|
||||||
|
exec --no-startup-id compton --xrender-sync-fence
|
||||||
|
#Try to load VGA screen if available:
|
||||||
|
exec --no-startup-id ~/.config/Scripts/screen.sh v
|
||||||
|
#Launch Polybar where appropriate:
|
||||||
|
exec_always --no-startup-id ~/.config/polybar/launch.sh
|
||||||
|
#Start the offlineimap daemon;
|
||||||
|
exec --no-startup-id killall python ~/.config/Scripts/offlineimap-daemon.py
|
||||||
|
exec --no-startup-id python ~/.config/Scripts/offlineimap-daemon.py
|
||||||
|
#Add wallpaper:
|
||||||
|
exec --no-startup-id feh --bg-scale ~/.config/wall.png
|
||||||
|
#exec_always --no-startup-id wal -c -i ~/.config/wall.png
|
||||||
|
#Remaps the caps lock button to escape and uses the US international keyboard with dead keys
|
||||||
|
exec_always --no-startup-id setxkbmap -option caps:escape
|
||||||
|
#exec_always --no-startup-id setxkbmap -layout us -variant altgr-intl -option caps:escape
|
||||||
|
#Remap Menu button to Super:
|
||||||
|
#exec_always --no-startup-id xmodmap -e 'keycode 135 = Super_R'
|
||||||
|
bindsym Menu exec --no-startup-id xmodmap -e 'keycode 135 = Super_R'
|
||||||
|
#Unclutter makes the mouse invisible after a brief period
|
||||||
|
exec --no-startup-id unclutter
|
||||||
|
|
||||||
|
#OPENRC
|
||||||
|
#set $shutdown sudo openrc-shutdown -p
|
||||||
|
#set $reboot sudo openrc-shutdown -r
|
||||||
|
#set $netrefresh --no-startup-id sudo rc-service NetworkManager restart
|
||||||
|
|
||||||
|
#SYSTEMD
|
||||||
|
set $shutdown sudo shutdown -h now
|
||||||
|
set $reboot sudo reboot
|
||||||
|
set $netrefresh --no-startup-id sudo systemctl restart NetworkManager
|
||||||
|
|
||||||
|
###---Audio and Music Definitions---###
|
||||||
|
|
||||||
|
##For spotify
|
||||||
|
#set $music spotify
|
||||||
|
#set $pause dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.PlayPause
|
||||||
|
#set $trupause dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.Pause
|
||||||
|
#set $play dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.Play
|
||||||
|
#set $next dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.Next
|
||||||
|
#set $prev dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.Previous
|
||||||
|
#set $lilfor dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.Seek
|
||||||
|
#set $bigfor dbus-send --print-reply --dest=org.mpris.MediaPlayer2.spotify /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.Seek(
|
||||||
|
|
||||||
|
# #---Audio and Music Definitions---# #
|
||||||
|
# For mpc:
|
||||||
|
set $music --no-startup-id st -e ncmpcpp
|
||||||
|
set $pause --no-startup-id mpc toggle
|
||||||
|
set $trupause --no-startup-id mpc pause
|
||||||
|
set $next --no-startup-id mpc next
|
||||||
|
set $prev --no-startup-id mpc prev
|
||||||
|
set $lilfor --no-startup-id mpc seek +10
|
||||||
|
set $bigfor --no-startup-id mpc seek +120
|
||||||
|
set $lilbak --no-startup-id mpc seek -10
|
||||||
|
set $bigbak --no-startup-id mpc seek -120
|
||||||
|
set $beg --no-startup-id mpc seek 0%
|
||||||
|
|
||||||
|
# For moc:
|
||||||
|
#set $music --no-startup-id st -e mocp
|
||||||
|
#set $pause --no-startup-id mocp -G
|
||||||
|
#set $truepause --no-startup-id mocp -P
|
||||||
|
#set $next --no-startup-id mocp -f
|
||||||
|
#set $prev --no-startup-id mocp -r
|
||||||
|
#set $lilfor --no-startup-id mocp -k 10
|
||||||
|
#set $bigfor --no-startup-id mocp -k 120
|
||||||
|
#set $lilbak --no-startup-id mocp -k -10
|
||||||
|
#set $bigbak --no-startup-id mocp -k -120
|
||||||
|
#set $beg --no-startup-id mocp -j 0%
|
||||||
|
|
||||||
|
# For cmus:
|
||||||
|
#set $music --no-startup-id st -e cmus
|
||||||
|
#set $pause --no-startup-id cmus-remote -u
|
||||||
|
#set $next --no-startup-id cmus-remote -n
|
||||||
|
#set $prev --no-startup-id cmus-remote -r
|
||||||
|
#set $lilfor --no-startup-id cmus-remote -k +10
|
||||||
|
#set $bigfor --no-startup-id cmus-remote -k +120
|
||||||
|
#set $lilbak --no-startup-id cmus-remote -k -10
|
||||||
|
#set $bigbak --no-startup-id cmus-remote -k -120
|
||||||
|
#set $beg --no-startup-id cmus-remote -k 00:00:00
|
||||||
|
|
||||||
|
#FOR ALSA/AMIXER
|
||||||
|
#set $inc --no-startup-id amixer sset Master 2%+
|
||||||
|
#set $biginc --no-startup-id amixer sset Master 5%+
|
||||||
|
#set $dec --no-startup-id amixer sset Master 2%-
|
||||||
|
#set $bigdec --no-startup-id amixer sset Master 5%-
|
||||||
|
#set $mute --no-startup-id amixer sset Master toggle
|
||||||
|
#set $truemute --no-startup-id amixer sset Master mute
|
||||||
|
#set $screencast --no-startup-id bash ~/.config/Scripts/screencast_alsa.sh
|
||||||
|
#set $audio --no-startup-id bash ~/.config/Scripts/audio_alsa.sh
|
||||||
|
|
||||||
|
#For PULSEAUDIO/PAMIXER
|
||||||
|
set $inc --no-startup-id pamixer --allow-boost -i 5
|
||||||
|
set $biginc --no-startup-id pamixer --allow-boost -i 15
|
||||||
|
set $dec --no-startup-id pamixer --allow-boost -d 5
|
||||||
|
set $bigdec --no-startup-id pamixer --allow-boost -d 15
|
||||||
|
set $mute --no-startup-id pamixer --allow-boost -t
|
||||||
|
set $micmute --no-startup-id pamixer --allow-boost -t
|
||||||
|
set $truemute --no-startup-id pamixer -m
|
||||||
|
set $screencast --no-startup-id bash ~/.config/Scripts/screencast_pulse.sh
|
||||||
|
set $audio --no-startup-id bash ~/.config/Scripts/audio_pulse.sh
|
||||||
|
|
||||||
|
# #---Basic Bindings---# #
|
||||||
|
bindsym $mod+Return exec $term
|
||||||
|
##bindsym $mod+Shift+Return exec $term -e tmux
|
||||||
|
|
||||||
|
bindsym $mod+Shift+space floating toggle
|
||||||
|
bindsym $mod+space focus mode_toggle
|
||||||
|
|
||||||
|
bindsym $mod+Escape workspace prev
|
||||||
|
bindsym $mod+Shift+Escape exec i3-msg exit
|
||||||
|
|
||||||
|
# bindsym $mod+BackSpace
|
||||||
|
bindsym $mod+Shift+BackSpace exec $reboot
|
||||||
|
|
||||||
|
# bindsym $mod+grave
|
||||||
|
##bindsym $mod+asciitilde
|
||||||
|
|
||||||
|
#STOP/HIDE EVERYTHING:
|
||||||
|
bindsym $mod+Shift+Delete exec $truemute ; exec $truepause ; workspace lmao ; exec $term -e htop ; exec $term -e ranger
|
||||||
|
|
||||||
|
# #---Letter Key Bindings---# #
|
||||||
|
bindsym $mod+q kill
|
||||||
|
bindsym $mod+Shift+q kill
|
||||||
|
|
||||||
|
bindsym $mod+w exec $term -e sudo wifi-menu
|
||||||
|
bindsym $mod+Shift+w exec --no-startup-id $BROWSER
|
||||||
|
|
||||||
|
bindsym $mod+e exec $term -e neomutt
|
||||||
|
##bindsym $mod+Shift+e
|
||||||
|
|
||||||
|
bindsym $mod+r exec $term -e ranger
|
||||||
|
bindsym $mod+Shift+r exec $term -e sudo ranger /
|
||||||
|
|
||||||
|
bindsym $mod+t split toggle
|
||||||
|
bindsym $mod+Shift+t gaps inner current set 15; gaps outer current set 15
|
||||||
|
|
||||||
|
bindsym $mod+y exec $term -e calcurse
|
||||||
|
bindsym $mod+Shift+y resize shrink width 10 px or 10ppt
|
||||||
|
|
||||||
|
bindsym $mod+u [instance="dropdown"] scratchpad show; [instance="dropdown"] move position center
|
||||||
|
bindsym $mod+Shift+u resize shrink height 10 px or 10 ppt
|
||||||
|
|
||||||
|
bindsym $mod+i exec $term -e htop
|
||||||
|
bindsym $mod+Shift+i resize grow height 10 px or 10 ppt
|
||||||
|
|
||||||
|
bindsym $mod+o sticky toggle
|
||||||
|
bindsym $mod+Shift+o resize grow width 10 px or 10 ppt
|
||||||
|
|
||||||
|
bindsym $mod+p exec $pause
|
||||||
|
bindsym $mod+Shift+p exec mypaint
|
||||||
|
|
||||||
|
bindsym $mod+a [instance="math"] scratchpad show; [instance="math"] move position center
|
||||||
|
bindsym $mod+Shift+a exec $term -e ncpamixer
|
||||||
|
|
||||||
|
bindsym $mod+s gaps inner current plus 5
|
||||||
|
bindsym $mod+Shift+s gaps inner current minus 5
|
||||||
|
|
||||||
|
bindsym $mod+d exec rofi -show run
|
||||||
|
bindsym $mod+Shift+d gaps inner current set 0; gaps outer current set 0
|
||||||
|
|
||||||
|
bindsym $mod+f fullscreen toggle
|
||||||
|
##bindsym $mod+Shift+f
|
||||||
|
|
||||||
|
bindsym $mod+g workspace prev
|
||||||
|
bindsym $mod+Shift+g exec --no-startup-id gimp; workspace $ws5
|
||||||
|
|
||||||
|
bindsym $mod+h focus left
|
||||||
|
bindsym $mod+Shift+h move left 30
|
||||||
|
|
||||||
|
bindsym $mod+j focus down
|
||||||
|
bindsym $mod+Shift+j move down 30
|
||||||
|
|
||||||
|
bindsym $mod+k focus up
|
||||||
|
bindsym $mod+Shift+k move up 30
|
||||||
|
|
||||||
|
bindsym $mod+l focus right
|
||||||
|
bindsym $mod+Shift+l move right 30
|
||||||
|
|
||||||
|
bindsym $mod+z gaps outer current plus 5
|
||||||
|
bindsym $mod+Shift+z gaps outer current minus 5
|
||||||
|
|
||||||
|
bindsym $mod+x exec --no-startup-id ~/.config/i3/lock.sh
|
||||||
|
bindsym $mod+Shift+x exec $shutdown
|
||||||
|
|
||||||
|
# Bindings to make the webcam float and stick.
|
||||||
|
for_window [title="video0 - mpv"] floating enable
|
||||||
|
for_window [title="video0 - mpv"] sticky enable
|
||||||
|
|
||||||
|
bindsym $mod+c exec --no-startup-id mpv --geometry=-0-0 --autofit=30% /dev/video0
|
||||||
|
bindsym $mod+Shift+c exec killall mpv /dev/video0
|
||||||
|
|
||||||
|
bindsym $mod+v exec $term -e ncmpcpp -s visualizer
|
||||||
|
bindsym $mod+Shift+v exec projectM-pulseaudio
|
||||||
|
|
||||||
|
##bindsym $mod+b exec $prev
|
||||||
|
bindsym $mod+Shift+b exec --no-startup-id blender; workspace $ws6
|
||||||
|
|
||||||
|
bindsym $mod+n exec $term -e newsboat
|
||||||
|
##bindsym $mod+Shift+n
|
||||||
|
|
||||||
|
bindsym $mod+m exec $music
|
||||||
|
bindsym $mod+Shift+m exec $mute
|
||||||
|
|
||||||
|
|
||||||
|
# #---Workspace Bindings---# #
|
||||||
|
bindsym $mod+Home workspace $ws1
|
||||||
|
bindsym $mod+Shift+Home move container to workspace $ws1
|
||||||
|
bindsym $mod+End workspace $ws10
|
||||||
|
bindsym $mod+Shift+End move container to workspace $ws10
|
||||||
|
bindsym $mod+Prior workspace prev
|
||||||
|
bindsym $mod+Shift+Prior move container to workspace prev
|
||||||
|
bindsym $mod+Next workspace next
|
||||||
|
bindsym $mod+Shift+Next move container to workspace next
|
||||||
|
bindsym $mod+Tab workspace back_and_forth
|
||||||
|
bindsym $mod+XF86Back workspace prev
|
||||||
|
##bindsym $mod+Shift+XF86Back
|
||||||
|
bindsym $mod+XF86Forward workspace next
|
||||||
|
##bindsym $mod+Shift+XF86Forward
|
||||||
|
bindsym $mod+semicolon workspace next
|
||||||
|
bindsym $mod+apostrophe split horizontal ;; exec $term
|
||||||
|
bindsym $mod+slash split vertical ;; exec $term
|
||||||
|
bindsym $mod+Shift+slash kill
|
||||||
|
bindsym $mod+backslash workspace back_and_forth
|
||||||
|
|
||||||
|
set $ws1 "1"
|
||||||
|
set $ws2 "2"
|
||||||
|
set $ws3 "3"
|
||||||
|
set $ws4 "4"
|
||||||
|
set $ws5 "5"
|
||||||
|
set $ws6 "6"
|
||||||
|
set $ws7 "7"
|
||||||
|
set $ws8 "8"
|
||||||
|
set $ws9 "9"
|
||||||
|
set $ws10 "10"
|
||||||
|
|
||||||
|
# switch to workspace
|
||||||
|
bindsym $mod+1 workspace $ws1
|
||||||
|
bindsym $mod+2 workspace $ws2
|
||||||
|
bindsym $mod+3 workspace $ws3
|
||||||
|
bindsym $mod+4 workspace $ws4
|
||||||
|
bindsym $mod+5 workspace $ws5
|
||||||
|
bindsym $mod+6 workspace $ws6
|
||||||
|
bindsym $mod+7 workspace $ws7
|
||||||
|
bindsym $mod+8 workspace $ws8
|
||||||
|
bindsym $mod+9 workspace $ws9
|
||||||
|
bindsym $mod+0 workspace $ws10
|
||||||
|
|
||||||
|
# move focused container to workspace
|
||||||
|
bindsym $mod+Shift+1 move container to workspace $ws1
|
||||||
|
bindsym $mod+Shift+2 move container to workspace $ws2
|
||||||
|
bindsym $mod+Shift+3 move container to workspace $ws3
|
||||||
|
bindsym $mod+Shift+4 move container to workspace $ws4
|
||||||
|
bindsym $mod+Shift+5 move container to workspace $ws5
|
||||||
|
bindsym $mod+Shift+6 move container to workspace $ws6
|
||||||
|
bindsym $mod+Shift+7 move container to workspace $ws7
|
||||||
|
bindsym $mod+Shift+8 move container to workspace $ws8
|
||||||
|
bindsym $mod+Shift+9 move container to workspace $ws9
|
||||||
|
bindsym $mod+Shift+0 move container to workspace $ws10
|
||||||
|
|
||||||
|
for_window [class="Blender"] move to workspace $ws6
|
||||||
|
for_window [class="Thunderbird"] move to workspace $ws9
|
||||||
|
for_window [class="marble"] move to workspace $ws7
|
||||||
|
#for_window [class="Firefox"] move to workspace $ws2
|
||||||
|
for_window [title="GIMP Startup"] move workspace $ws5
|
||||||
|
for_window [class="Gimp"] move workspace $ws5
|
||||||
|
for_window [window_role="gimp-dock"] floating disable; move left; resize shrink width 50 px or 50ppt
|
||||||
|
for_window [window_role="gimp-toolbox"] floating disable; move right; resize grow width 30 px or 30ppt
|
||||||
|
for_window [window_role="tr-main"] move to workspace $ws8
|
||||||
|
for_window [window_role="GtkFileChooserDialog"] resize shrink height 10 px
|
||||||
|
|
||||||
|
|
||||||
|
workspace $ws6 gaps inner 0
|
||||||
|
workspace $ws6 gaps outer 0
|
||||||
|
workspace $ws5 gaps inner 0
|
||||||
|
workspace $ws5 gaps outer 0
|
||||||
|
workspace $ws8 gaps inner 0
|
||||||
|
workspace $ws8 gaps outer 0
|
||||||
|
|
||||||
|
# #---Function Buttons---# #
|
||||||
|
##bindsym F1 nop
|
||||||
|
##bindsym F2
|
||||||
|
##bindsym F3
|
||||||
|
##bindsym F4
|
||||||
|
##bindsym F5
|
||||||
|
##bindsym F6
|
||||||
|
##bindsym F7
|
||||||
|
##bindsym F8
|
||||||
|
##bindsym F9
|
||||||
|
##bindsym F10
|
||||||
|
bindsym F11 fullscreen toggle
|
||||||
|
##bindsym F12
|
||||||
|
|
||||||
|
bindsym $mod+F1 exec --no-startup-id mupdf ~/.config/i3/i3_guide.pdf
|
||||||
|
bindsym $mod+F2 restart
|
||||||
|
bindsym $mod+F3 exec --no-startup-id arandr
|
||||||
|
bindsym $mod+F4 exec --no-startup-id sudo zzz
|
||||||
|
bindsym $mod+F5 exec --no-startup-id $netrefresh
|
||||||
|
bindsym $mod+F6 exec --no-startup-id $term -e transmission-remote-cli
|
||||||
|
##bindsym $mod+F7
|
||||||
|
##bindsym $mod+F8
|
||||||
|
bindsym $mod+F9 exec --no-startup-id sudo mount -a
|
||||||
|
bindsym $mod+F10 exec --no-startup-id ~/.config/Scripts/screen.sh l ;; exec --no-startup-id ~/.config/polybar/launch.sh
|
||||||
|
bindsym $mod+F11 exec --no-startup-id ~/.config/Scripts/screen.sh v ;; exec --no-startup-id ~/.config/polybar/launch.sh
|
||||||
|
bindsym $mod+F12 exec --no-startup-id ~/.config/Scripts/screen.sh d ;; exec --no-startup-id ~/.config/polybar/launch.sh
|
||||||
|
|
||||||
|
|
||||||
|
# #---Arrow Keys---# #
|
||||||
|
bindsym $mod+Left focus left
|
||||||
|
bindsym $mod+Down focus down
|
||||||
|
bindsym $mod+Up focus up
|
||||||
|
bindsym $mod+Right focus right
|
||||||
|
bindsym $mod+Shift+Left move left
|
||||||
|
bindsym $mod+Shift+Down move down
|
||||||
|
bindsym $mod+Shift+Up move up
|
||||||
|
bindsym $mod+Shift+Right move right
|
||||||
|
|
||||||
|
|
||||||
|
# #---Media Keys---# #
|
||||||
|
|
||||||
|
# Volume keys
|
||||||
|
bindsym $mod+plus exec $inc
|
||||||
|
bindsym $mod+Shift+plus exec $biginc
|
||||||
|
bindsym $mod+minus exec $dec
|
||||||
|
bindsym $mod+Shift+minus exec $bigdec
|
||||||
|
bindsym $mod+less exec $prev
|
||||||
|
bindsym $mod+Shift+less exec $beg
|
||||||
|
bindsym $mod+greater exec $next
|
||||||
|
bindsym $mod+Shift+greater exec $next
|
||||||
|
|
||||||
|
# For advancing forward/backward in an mpd song
|
||||||
|
bindsym $mod+bracketleft exec $lilbak
|
||||||
|
bindsym $mod+Shift+bracketleft exec $bigbak
|
||||||
|
bindsym $mod+bracketright exec $lilfor
|
||||||
|
bindsym $mod+Shift+bracketright exec $bigfor
|
||||||
|
|
||||||
|
# Print screen takes a screenshot.
|
||||||
|
# With shift, it takes one only of the given window.
|
||||||
|
bindsym Print exec --no-startup-id scrot
|
||||||
|
bindsym Shift+Print exec --no-startup-id scrot -u
|
||||||
|
|
||||||
|
# For recording audio/video or stop recording. Also screenkey for visual typing.
|
||||||
|
bindsym $mod+Print exec --no-startup-id screenkey
|
||||||
|
bindsym $mod+Scroll_Lock exec $audio
|
||||||
|
bindsym $mod+Insert exec $screencast
|
||||||
|
bindsym $mod+Pause exec $video
|
||||||
|
bindsym $mod+Delete exec $stoprec
|
||||||
|
##bindsym XF86Launch1 exec $stoprec
|
||||||
|
bindsym XF86Launch1 exec $stoprec & xset dpms force off
|
||||||
|
|
||||||
|
# #---Dropdown/Scratchpad Windows---# #
|
||||||
|
# First I have a tmux window used for background scripts.
|
||||||
|
# I'll later bind this to mod+u.
|
||||||
|
for_window [instance="dropdown"] floating enable
|
||||||
|
for_window [instance="dropdown"] resize set 625 400
|
||||||
|
for_window [instance="dropdown"] move scratchpad
|
||||||
|
for_window [instance="dropdown"] border pixel 3
|
||||||
|
exec --no-startup-id $term -n dropdown -e tmux
|
||||||
|
|
||||||
|
# Then I have a window running R I use for basic arithmetic
|
||||||
|
# I'll later bind this to mod+a.
|
||||||
|
for_window [instance="math"] floating enable
|
||||||
|
for_window [instance="math"] resize set 800 300
|
||||||
|
for_window [instance="math"] move scratchpad
|
||||||
|
for_window [instance="math"] border pixel 5
|
||||||
|
exec --no-startup-id $term -n math -f mono:pixelsize=24 -e R -q
|
||||||
|
|
||||||
|
|
||||||
|
# #---Extra XF86 Keys---# #
|
||||||
|
# These are the extra media keys that some keyboards have.
|
||||||
|
bindsym XF86AudioMute exec $mute
|
||||||
|
bindsym XF86AudioLowerVolume exec $dec
|
||||||
|
bindsym XF86AudioRaiseVolume exec $inc
|
||||||
|
bindsym XF86PowerOff exec $shutdown
|
||||||
|
##bindsym XF86Copy exec
|
||||||
|
##bindsym XF86Open exec
|
||||||
|
##bindsym XF86Paste exec
|
||||||
|
##bindsym XF86Cut exec
|
||||||
|
##bindsym XF86MenuKB exec
|
||||||
|
bindsym XF86Calculator exec $term -e R -q
|
||||||
|
bindsym XF86Sleep exec sudo zzz
|
||||||
|
##bindsym XF86WakeUp exec
|
||||||
|
bindsym XF86Explorer exec $term -e ranger
|
||||||
|
##bindsym XF86Send exec
|
||||||
|
##bindsym XF86Xfer exec
|
||||||
|
bindsym XF86WWW exec --no-startup-id $BROWSER
|
||||||
|
##bindsym XF86DOS exec
|
||||||
|
bindsym XF86ScreenSaver exec exec --no-startup-id ~/.config/i3/lock.sh
|
||||||
|
##bindsym XF86RotateWindows exec
|
||||||
|
##bindsym XF86TaskPane exec
|
||||||
|
##bindsym XF86Favorites exec
|
||||||
|
bindsym XF86MyComputer exec $term -e ranger
|
||||||
|
##bindsym XF86Back exec
|
||||||
|
##bindsym XF86Forward exec
|
||||||
|
bindsym XF86Eject exec sudo umount -R /mnt
|
||||||
|
bindsym XF86AudioNext exec $next
|
||||||
|
bindsym XF86AudioPlay exec $pause
|
||||||
|
bindsym XF86AudioPrev exec $prev
|
||||||
|
bindsym XF86AudioStop exec $pause
|
||||||
|
bindsym XF86AudioRecord exec $audio
|
||||||
|
bindsym XF86AudioRewind exec $lilbak
|
||||||
|
bindsym XF86AudioForward exec $lilfor
|
||||||
|
##bindsym XF86Phone exec
|
||||||
|
##bindsym XF86Tools exec
|
||||||
|
bindsym XF86HomePage exec $BROWSER https://lukesmith.xyz
|
||||||
|
bindsym XF86Reload restart
|
||||||
|
##bindsym XF86ScrollUp exec
|
||||||
|
##bindsym XF86ScrollDown exec
|
||||||
|
##bindsym XF86New exec
|
||||||
|
##bindsym XF86LaunchA exec
|
||||||
|
##bindsym XF86LaunchB exec
|
||||||
|
##bindsym XF86Launch2 exec
|
||||||
|
##bindsym XF86Launch3 exec
|
||||||
|
##bindsym XF86Launch4 exec
|
||||||
|
##bindsym XF86Launch5 exec
|
||||||
|
##bindsym XF86Launch6 exec
|
||||||
|
##bindsym XF86Launch7 exec
|
||||||
|
##bindsym XF86Launch8 exec
|
||||||
|
##bindsym XF86Launch9 exec
|
||||||
|
bindsym XF86AudioMicMute exec $micmute
|
||||||
|
##bindsym XF86TouchpadToggle exec
|
||||||
|
bindsym XF86TouchpadOn exec --no-startup-id exec synclient TouchpadOff=0
|
||||||
|
bindsym XF86TouchpadOff exec --no-startup-id exec synclient TouchpadOff=1
|
||||||
|
bindsym XF86Suspend exec --no-startup-id ~/.config/i3/lock.sh
|
||||||
|
bindsym XF86Close kill
|
||||||
|
bindsym XF86WebCam exec mpv /dev/video0
|
||||||
|
bindsym XF86Mail exec $term -e neomutt
|
||||||
|
bindsym XF86Messenger exec $term -e weechat
|
||||||
|
bindsym XF86Search exec $BROWSER https://duckduckgo.com
|
||||||
|
##bindsym XF86Go exec
|
||||||
|
##bindsym XF86Finance exec
|
||||||
|
##bindsym XF86Game exec
|
||||||
|
bindsym XF86Shop exec $BROWSER https://ebay.com
|
||||||
|
bindsym XF86MonBrightnessDown exec --no-startup-id xbacklight -dec 15
|
||||||
|
bindsym XF86MonBrightnessUp exec --no-startup-id xbacklight -inc 15
|
||||||
|
bindsym XF86AudioMedia exec $music
|
||||||
|
bindsym XF86Display exec --no-startup-id arandr
|
||||||
|
#bindsym XF86KbdLightOnOff exec
|
||||||
|
bindsym XF86KbdBrightnessDown exec --no-startup-id python3.6 ~/.i3/kb-lights.py -
|
||||||
|
bindsym XF86KbdBrightnessUp exec --no-startup-id python3.6 ~/.i3/kb-lights.py +
|
||||||
|
#bindsym XF86Reply exec
|
||||||
|
#bindsym XF86MailForward exec
|
||||||
|
#bindsym XF86Save exec
|
||||||
|
bindsym XF86Documents exec $term -e ranger ~/Documents
|
||||||
|
##bindsym XF86Battery exec
|
||||||
|
##bindsym XF86Bluetooth exec
|
||||||
|
bindsym XF86WLAN exec --no-startup-id sudo systemctl restart NetworkManager
|
182
.config/i3/i3_guide.rmd
Normal file
182
.config/i3/i3_guide.rmd
Normal file
|
@ -0,0 +1,182 @@
|
||||||
|
---
|
||||||
|
title: A Friendly Guide to Luke's i3 Rice
|
||||||
|
author: Luke Smith
|
||||||
|
output: pdf_document
|
||||||
|
linkcolor: blue
|
||||||
|
---
|
||||||
|
|
||||||
|
Use vim keys (h/j/k/l) to navigate this document. Pressing W will fit it to window width. + and - zoom in and out. f to toggle fullscreen. q to quit. (These are general mupdf shortcuts.)
|
||||||
|
|
||||||
|
+ Mod+F1 will show this document at any time.
|
||||||
|
+ By "Mod" I mean the Super Key, usually known as "the Windows Key."
|
||||||
|
|
||||||
|
Questions or suggestions? Email me at [luke@lukesmith.xyz](mailto:luke@lukesmith.xyz).
|
||||||
|
|
||||||
|
## Basic goals and principles of this system:
|
||||||
|
|
||||||
|
+ Naturalness -- Remove the border between mind and matter: everything important should be as few keypresses as possible away from you, and you shouldn't have to think about what you're doing. Immersion.
|
||||||
|
+ Economy -- Programs should be simple and light on system resources and highly extensible. Because of this, many are terminal or small ncurses programs that have all the magic inside of them.
|
||||||
|
+ Keyboard/vim-centrality -- All terminal programs (and other programs) use vim keys when possible. Your hands never need leave the home row or thereabout.
|
||||||
|
|
||||||
|
## General changes
|
||||||
|
|
||||||
|
+ Capslock is now an alternative escape. Makes vim-craft much more efficient.
|
||||||
|
+ The menu button (usually between the right Alt and Ctrl) is an alternative Super/Mod button. This is to make one-handing on my laptops easier.
|
||||||
|
+ The rice also uses the US International keyboard by default. This allows you to type a lot of characters in many different European languages. If you'd like to change this, you need only remove the `setxkbmap` line in the i3 config.
|
||||||
|
|
||||||
|
# The Polybar Status Bar
|
||||||
|
|
||||||
|
If you're new to i3, notice the status bar on the top of the screen. This is Polybar. To the left side, you'll see the numbers of your current workspace(s). If you have a song playing in mpd, its name will appear to the left as well. On the right side, you'll see various system status notifiers, date, CPU tempurature, remaining hard drive space, etc. I'm sure you can figure it out. Several modules will be click-sensitive, although if you're using my system as indended, you probably won't be doing much clicking.
|
||||||
|
|
||||||
|
# Key Bindings
|
||||||
|
|
||||||
|
## Window basics
|
||||||
|
|
||||||
|
Notice the case sensitivity of the shortcuts.
|
||||||
|
|
||||||
|
Be sure you play around with these. Be flexible with the basic commands and the rice will grow on you quick.
|
||||||
|
|
||||||
|
+ Mod+Enter -- Spawn terminal
|
||||||
|
+ Mod+q or Q -- Close window
|
||||||
|
+ Mod+d -- rofi (For running commands or programs without shortcuts)
|
||||||
|
+ Mod+t -- Toggle between spawning vertically and horizontally
|
||||||
|
+ Mod+f or F11 -- Fullscreen
|
||||||
|
+ Mod+h/j/k/l -- Move to different windows
|
||||||
|
+ Mod+H/J/K/L -- Move a window around
|
||||||
|
+ Mod+Y/U/I/O -- Resize windows
|
||||||
|
+ Mod+/ -- Spawn vertical terminal
|
||||||
|
+ Mod+' -- Spawn horizontal terminal
|
||||||
|
+ Mod+s/S -- Increase/decrease inner gaps
|
||||||
|
+ Mod+z/Z -- Increase/decrease outer gaps
|
||||||
|
+ Mod+D -- Reduce gaps to 0 pixels
|
||||||
|
+ Mod+T -- Restore gaps to default (15 pixels)
|
||||||
|
+ Mod+Shift+Space -- Make a window float (you can still resize and move floating windows with the same keys above)
|
||||||
|
+ Mod+Space -- Switch focus from a floating window to a non-floating one (or vice versa)
|
||||||
|
|
||||||
|
## Basic Programs
|
||||||
|
|
||||||
|
+ Mod+r -- ranger (file browser/manager)
|
||||||
|
+ Mod+e -- mutt (email)
|
||||||
|
+ Mod+m -- ncmpcpp (music player)
|
||||||
|
+ Mod+a -- R calculator (be sure to close with Mod+a for reusability)
|
||||||
|
+ Mod+i -- htop (system info)
|
||||||
|
+ Mod+n -- newsboat (RSS feed reader)
|
||||||
|
+ Mod+y -- calcurse (calendar and schedule)
|
||||||
|
+ Mod+u -- "Dropdown" terminal (close with Mod+u for reusability)
|
||||||
|
+ Mod+A -- ncpamixer (audio system control)
|
||||||
|
+ mod+w -- wifi-menu (accessing wifi networks)
|
||||||
|
|
||||||
|
## Larger programs
|
||||||
|
|
||||||
|
+ Mod+W -- qutebrowser
|
||||||
|
+ Mod+B -- Blender (video and 3d editor)
|
||||||
|
+ Mod+G -- GIMP (for general image manipulation)
|
||||||
|
+ Mod+P -- MyPaint (for light sketching)
|
||||||
|
|
||||||
|
## System
|
||||||
|
|
||||||
|
+ Mod+R -- ranger as root user
|
||||||
|
+ Mod+x -- i3lock (Enter password to return)
|
||||||
|
+ Mod+X -- shutdown now (Be careful with this one!)
|
||||||
|
+ Mod+Shift+Backspace -- reboot (And this one!)
|
||||||
|
+ Mod+Shift+Escape -- exit i3 (And this one as well!)
|
||||||
|
+ Mod+F1 -- Shows this document
|
||||||
|
+ Mod+F2 -- Refresh i3
|
||||||
|
+ Mod+F3 -- arandr (For adding screens/HDMI/VGA connections)
|
||||||
|
+ Mod+F4 -- Hibernate
|
||||||
|
+ Mod+F6 -- transmission torrent client (cli)
|
||||||
|
+ Mod+F5 -- Reset Network Manager, search for new networks
|
||||||
|
+ Mod+F7 -- <++>
|
||||||
|
+ Mod+F8 -- <++>
|
||||||
|
+ Mod+F10 -- Switch to laptop screen
|
||||||
|
+ Mod+F11 -- Switch to VGA display (if available)
|
||||||
|
+ Mod+F12 -- Switch to dual VGA/laptop display (if available)
|
||||||
|
|
||||||
|
## Audio
|
||||||
|
|
||||||
|
I use ncmpcpp as a music player, which is a front end for mpd. If you prefer cmus or mocp, I have commented out shortcuts you can activate for it instead in the i3 config.
|
||||||
|
|
||||||
|
+ Mod+m -- ncmpcpp music player
|
||||||
|
+ Mod+. -- Next track
|
||||||
|
+ Mod+, -- Previous track
|
||||||
|
+ Mod+< -- Restart track
|
||||||
|
+ Mod+p -- Pause
|
||||||
|
+ Mod+M -- Mute all audio
|
||||||
|
+ Mod+v -- visualizer
|
||||||
|
+ Mod+- -- Decrease volume (holding shift increases amount)
|
||||||
|
+ Mod++ -- Increase volume (holding shift increases amount)
|
||||||
|
+ Mod+[ -- Back 10 seconds (holding shift increases amount)
|
||||||
|
+ Mod+] -- Forward 10 seconds (holding shift increases amount)
|
||||||
|
+ Mod+A -- ncpamixer (general volume sink/source control)
|
||||||
|
|
||||||
|
## Workspaces
|
||||||
|
|
||||||
|
There are ten workspaces. They work just like those in vanilla i3 with some additions.
|
||||||
|
|
||||||
|
+ Mod+(Number) -- Go to that number workspace
|
||||||
|
+ Mod+Shift+(Number) -- Send window to that workspace
|
||||||
|
+ Mod+Tab -- Go to previous workspace
|
||||||
|
+ Mod+g or escape -- Go to left workspace
|
||||||
|
+ Mod+; -- Go to right workspace
|
||||||
|
+ Mod+Shift+Delete -- "Porno-mode" Press this key sequence if you want to hide what you have on your screen. Moves to a totally new workspace, mutes sound, pauses music and brings up distraction windows.
|
||||||
|
|
||||||
|
## Recording
|
||||||
|
|
||||||
|
I use scrot and ffmpeg to make different recordings of the desktop and audio. All of these recording shortcuts will output into `~`, and will not overwrite previous recordings.
|
||||||
|
|
||||||
|
+ Print Screen -- Take a scrot screenshot
|
||||||
|
+ Shift+Print Screen -- Take a scrot screenshot of only selected window
|
||||||
|
+ Mod+Insert -- Begin screencast
|
||||||
|
+ Mod+ScrollLock -- Begin audio recording
|
||||||
|
+ Mod+Pause -- Begin screen recording without audio
|
||||||
|
+ Mod+Print Screen -- Start screenkey
|
||||||
|
+ Mod+Delete -- kills ffmpeg and screenkey, thus ending recordings and screen
|
||||||
|
+ ThinkVantage button (on Thinkpads) -- kills ffmpeg and screenkey, thus ending recordings
|
||||||
|
|
||||||
|
Each of the recording scripts are located in `~/.config/Scripts/`. You can check them out or modify them if needed.
|
||||||
|
|
||||||
|
## Other buttons
|
||||||
|
|
||||||
|
I've mapped those extra buttons that some keyboards have (play and pause buttons, email, webbrowsing buttons, etc.) to what you would expect.
|
||||||
|
|
||||||
|
# Special traits of my rice
|
||||||
|
|
||||||
|
## Easy config access
|
||||||
|
|
||||||
|
Open a terminal and type `cfc`. This will open a file where you will see customizable pairs of key shortcuts and config files. Enter any of these shortcuts in bash or ranger to immediately open the file in vim.
|
||||||
|
|
||||||
|
You may add new entries here and they will be refreshed when you save the file in vim. This will take effect immediately once you start a new instance of bash or ranger.
|
||||||
|
|
||||||
|
## Folder and config shortcuts
|
||||||
|
|
||||||
|
Open a terminal and type `cff`. This opens a file when you can keep and create folder shortcuts. There are only a few here now, because I don't know what your folder structure is going to look like, but on my machine, I have 81 and growing.
|
||||||
|
|
||||||
|
Each line has a shortcut key/keys and its target. These can be used in serveral applications. In bash, simply press `d`, the shortcut for `~/Documents` and you will cd there (and automatically `ls -a`).
|
||||||
|
|
||||||
|
ranger works similarly. When in ranger, just press `g` then the shortcut of the folder you want to go to. You may also press `t` plus the shortcut to open a new tab there. `m` plus the shortcut moves the selected files to the folder and `Y` copies them there. **Get good at this. It will make management of even the most complex file system easy.**
|
||||||
|
|
||||||
|
Lastly qutebrowser implements these shortcuts as well. When you see a file or image you want to download, press `;` followed by the folder shortcut and qutebrowser will let you select the file with its hint system. The file will then download to the directory you chose.
|
||||||
|
|
||||||
|
## Dynamically constructed configs
|
||||||
|
|
||||||
|
Each time you save changes to either the config shortcut file or the folder shortcut file in vim, vim will automatically run a bash script that updates your bash/ranger config, allowing you to use your new shortcuts in your next instance of bash/ranger or after resourcing your rc files.
|
||||||
|
|
||||||
|
# Explore and customize
|
||||||
|
|
||||||
|
Don't like something about the rice? Change it. If you have a problem, try figuring it out yourself, but if you can't, ask on my YouTube or by my email.
|
||||||
|
|
||||||
|
EDIT: July 31, 2017. All the feedback I've gotten is tremendous and I'm glad this has gotten so many people into customization!
|
||||||
|
|
||||||
|
# Contact
|
||||||
|
|
||||||
|
[luke@lukesmith.xyz](mailto:luke@lukesmith.xyz) -- For questions!
|
||||||
|
|
||||||
|
[http://lukesmith.xyz](http://lukesmith.xyz) -- For stalking!
|
||||||
|
|
||||||
|
[Send Me Money!](https://paypal.me/LukeMSmith) -- For gratitude!
|
||||||
|
|
||||||
|
[My Github Page](https://github.com/LukeSmithxyz) -- For the code behind it!
|
||||||
|
|
||||||
|
[Twitter](https://twitter.com/lukesfiat) -- For updates!
|
||||||
|
|
||||||
|
[RSS](http://lukesmith.xyz/rss.xml) -- For even better updates!
|
35
.config/i3/kb-lights.py
Executable file
35
.config/i3/kb-lights.py
Executable file
|
@ -0,0 +1,35 @@
|
||||||
|
#!/usr/bin/env python3
|
||||||
|
# coding: utf-8
|
||||||
|
|
||||||
|
from sys import argv
|
||||||
|
import dbus
|
||||||
|
|
||||||
|
|
||||||
|
def kb_light_set(delta):
|
||||||
|
bus = dbus.SystemBus()
|
||||||
|
kbd_backlight_proxy = bus.get_object('org.freedesktop.UPower', '/org/freedesktop/UPower/KbdBacklight')
|
||||||
|
kbd_backlight = dbus.Interface(kbd_backlight_proxy, 'org.freedesktop.UPower.KbdBacklight')
|
||||||
|
|
||||||
|
current = kbd_backlight.GetBrightness()
|
||||||
|
maximum = kbd_backlight.GetMaxBrightness()
|
||||||
|
new = max(0, current + delta)
|
||||||
|
|
||||||
|
if 0 <= new <= maximum:
|
||||||
|
current = new
|
||||||
|
kbd_backlight.SetBrightness(current)
|
||||||
|
|
||||||
|
# Return current backlight level percentage
|
||||||
|
return 100 * current / maximum
|
||||||
|
|
||||||
|
if __name__ == '__main__':
|
||||||
|
if len(argv[1:]) == 1:
|
||||||
|
if argv[1] == "--up" or argv[1] == "+":
|
||||||
|
# ./kb-light.py (+|--up) to increment
|
||||||
|
print(kb_light_set(1))
|
||||||
|
elif argv[1] == "--down" or argv[1] == "-":
|
||||||
|
# ./kb-light.py (-|--down) to decrement
|
||||||
|
print(kb_light_set(-1))
|
||||||
|
else:
|
||||||
|
print("Unknown argument:", argv[1])
|
||||||
|
else:
|
||||||
|
print("Script takes exactly one argument.", len(argv[1:]), "arguments provided.")
|
BIN
.config/i3/lock.png
Normal file
BIN
.config/i3/lock.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 4.9 KiB |
8
.config/i3/lock.sh
Executable file
8
.config/i3/lock.sh
Executable file
|
@ -0,0 +1,8 @@
|
||||||
|
#!/bin/bash
|
||||||
|
scrot /tmp/screen.png
|
||||||
|
#convert /tmp/screen.png -scale 10% -scale 1000% /tmp/screen.png
|
||||||
|
#convert /tmp/screen.png -paint 3 -modulate 80 /tmp/screen.png
|
||||||
|
convert /tmp/screen.png -paint 3 /tmp/screen.png
|
||||||
|
[[ -f ~/.config/i3/lock.png ]] && convert /tmp/screen.png ~/.config/i3/lock.png -gravity center -composite -matte /tmp/screen.png
|
||||||
|
mocp -P
|
||||||
|
i3lock -u -e -i /tmp/screen.png
|
26
.config/mimeapps.list
Normal file
26
.config/mimeapps.list
Normal file
|
@ -0,0 +1,26 @@
|
||||||
|
[Default Applications]
|
||||||
|
x-scheme-handler/http=userapp-Firefox-L5HJ0Y.desktop
|
||||||
|
x-scheme-handler/https=userapp-Firefox-L5HJ0Y.desktop
|
||||||
|
x-scheme-handler/ftp=userapp-Firefox-L5HJ0Y.desktop
|
||||||
|
x-scheme-handler/chrome=userapp-Firefox-L5HJ0Y.desktop
|
||||||
|
text/html=userapp-Firefox-L5HJ0Y.desktop
|
||||||
|
application/x-extension-htm=userapp-Firefox-L5HJ0Y.desktop
|
||||||
|
application/x-extension-html=userapp-Firefox-L5HJ0Y.desktop
|
||||||
|
application/x-extension-shtml=userapp-Firefox-L5HJ0Y.desktop
|
||||||
|
application/xhtml+xml=userapp-Firefox-L5HJ0Y.desktop
|
||||||
|
application/x-extension-xhtml=userapp-Firefox-L5HJ0Y.desktop
|
||||||
|
application/x-extension-xht=userapp-Firefox-L5HJ0Y.desktop
|
||||||
|
application/pdf=mupdf.desktop
|
||||||
|
|
||||||
|
[Added Associations]
|
||||||
|
x-scheme-handler/http=userapp-Firefox-L5HJ0Y.desktop;
|
||||||
|
x-scheme-handler/https=userapp-Firefox-L5HJ0Y.desktop;
|
||||||
|
x-scheme-handler/ftp=userapp-Firefox-L5HJ0Y.desktop;
|
||||||
|
x-scheme-handler/chrome=userapp-Firefox-L5HJ0Y.desktop;
|
||||||
|
text/html=userapp-Firefox-L5HJ0Y.desktop;
|
||||||
|
application/x-extension-htm=userapp-Firefox-L5HJ0Y.desktop;
|
||||||
|
application/x-extension-html=userapp-Firefox-L5HJ0Y.desktop;
|
||||||
|
application/x-extension-shtml=userapp-Firefox-L5HJ0Y.desktop;
|
||||||
|
application/xhtml+xml=userapp-Firefox-L5HJ0Y.desktop;
|
||||||
|
application/x-extension-xhtml=userapp-Firefox-L5HJ0Y.desktop;
|
||||||
|
application/x-extension-xht=userapp-Firefox-L5HJ0Y.desktop;
|
13
.config/moc/config
Normal file
13
.config/moc/config
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
Keymap = ${HOME}/.config/moc/keymap
|
||||||
|
Theme = ${HOME}/.config/moc/themes/theme
|
||||||
|
#readtags = no
|
||||||
|
QueueNextSongReturn = no
|
||||||
|
FormatString = "%(n:%n :)%(t:%t:)%(a: \(by %a\):)%(A: \(in %A\):)"
|
||||||
|
##%(A: \(%A\):)"
|
||||||
|
|
||||||
|
MusicDir = ${HOME}/Music
|
||||||
|
Fastdir1 = ${HOME}/Talks/Audiobooks
|
||||||
|
Fastdir2 = ${HOME}/Talks/Lectures
|
||||||
|
Fastdir3 = ${HOME}/Talks/Podcasts
|
||||||
|
Fastdir4 = ${HOME}/Downloads
|
||||||
|
Fastdir5 = ${HOME}/Creations
|
188
.config/moc/keymap
Normal file
188
.config/moc/keymap
Normal file
|
@ -0,0 +1,188 @@
|
||||||
|
# This is the example keymap file for MOC. You can define your own key
|
||||||
|
# bindings for MOC commands by creating your own keymap file and setting
|
||||||
|
# the 'Keymap' option in ~/.moc/config.
|
||||||
|
#
|
||||||
|
# The format of this file is:
|
||||||
|
#
|
||||||
|
# - Lines beginning with # are comments.
|
||||||
|
# - Blank lines are ignored.
|
||||||
|
# - Every other line is expected to be in one of the formats:
|
||||||
|
#
|
||||||
|
# COMMAND = [KEY ...]
|
||||||
|
# COMMAND += KEY ...
|
||||||
|
#
|
||||||
|
# The KEY can be:
|
||||||
|
#
|
||||||
|
# - Just a char, like i, L, ", *
|
||||||
|
# - CTRL-KEY sequence: ^k (CTRL-k), ^4
|
||||||
|
# - ALT-KEY (meta) sequence: M-j (ALT-j), M-/
|
||||||
|
# - Special keys: DOWN, UP
|
||||||
|
# LEFT, RIGHT
|
||||||
|
# HOME, END
|
||||||
|
# BACKSPACE
|
||||||
|
# INS, DEL
|
||||||
|
# ENTER
|
||||||
|
# PAGE_UP, PAGE_DOWN
|
||||||
|
# SPACE, TAB
|
||||||
|
# KEYPAD_CENTER
|
||||||
|
# ESCAPE
|
||||||
|
# F1 - F12
|
||||||
|
#
|
||||||
|
# Note that the use of a digit as a KEY is deprecated.
|
||||||
|
#
|
||||||
|
# Maximum number of KEYs for one COMMAND is 5.
|
||||||
|
#
|
||||||
|
# Omitting the KEY for a COMMAND will unbind all its default keys. They
|
||||||
|
# will also be automatically unbound when you bind new KEYs to it. Individual
|
||||||
|
# default KEYs will be automatically unbound when they are explicitly bound
|
||||||
|
# to some other COMMAND.
|
||||||
|
#
|
||||||
|
# Using the '+=' form will cause the KEYs to be appended to any existing
|
||||||
|
# (default or explicit) bindings for the COMMAND. Appending an existing
|
||||||
|
# default binding for the same COMMAND will cause MOC to think of that KEY
|
||||||
|
# as then being explicitly bound.
|
||||||
|
#
|
||||||
|
# Only one binding for any given COMMAND can appear in the keymap file. One
|
||||||
|
# exception to this is that if the default keys for a COMMAND are explicitly
|
||||||
|
# unbound then a subsequent binding may appear for it. A second exception
|
||||||
|
# is that multiple appending bindings may appear.
|
||||||
|
#
|
||||||
|
# Meta-key detection is sensitive to the ESCDELAY environment variable (see
|
||||||
|
# the manpage for ncurses(3)). In its absence, MOC resets the default
|
||||||
|
# delay to 25ms. If you need to emulate meta-key sequences using the ESC
|
||||||
|
# key, then you may need to set the value of ESCDELAY back to its ncurses
|
||||||
|
# default of 1000ms (but doing so will make the response to the ESC key
|
||||||
|
# sluggish).
|
||||||
|
#
|
||||||
|
# If MOC's keypresses are being filtered through some other program (in a
|
||||||
|
# GUI environment, for example) which also does meta-key detection, then
|
||||||
|
# MOC is at the mercy of the timings with which that program presents them.
|
||||||
|
#
|
||||||
|
# Default key configuration for MOC (and a list of all available commands):
|
||||||
|
|
||||||
|
# MOC control keys:
|
||||||
|
quit_client = q
|
||||||
|
quit = Q
|
||||||
|
|
||||||
|
# Menu and interface control keys:
|
||||||
|
go = ENTER l
|
||||||
|
menu_down = DOWN j
|
||||||
|
menu_up = UP k
|
||||||
|
menu_page_down = PAGE_DOWN ^d d
|
||||||
|
menu_page_up = PAGE_UP ^p ^u u
|
||||||
|
menu_first_item = HOME g
|
||||||
|
menu_last_item = END G
|
||||||
|
search_menu = /
|
||||||
|
toggle_read_tags = f
|
||||||
|
toggle_show_time = ^t
|
||||||
|
toggle_show_format = ^f
|
||||||
|
toggle_menu = TAB
|
||||||
|
#toggle_layout = L
|
||||||
|
#toggle_hidden_files = H
|
||||||
|
next_search = ^g ^n
|
||||||
|
#show_lyrics = L
|
||||||
|
theme_menu = T
|
||||||
|
help = ?
|
||||||
|
refresh = ^r
|
||||||
|
reload = r
|
||||||
|
|
||||||
|
# Audio playing and positioning keys:
|
||||||
|
seek_forward = RIGHT
|
||||||
|
seek_backward = LEFT
|
||||||
|
seek_forward_fast = ]
|
||||||
|
seek_backward_fast = [
|
||||||
|
pause = p SPACE
|
||||||
|
stop = s
|
||||||
|
next = n L ^l
|
||||||
|
previous = b H ^h
|
||||||
|
toggle_shuffle = S
|
||||||
|
toggle_repeat = R
|
||||||
|
toggle_auto_next = X N
|
||||||
|
#toggle_mixer = x
|
||||||
|
go_url = o
|
||||||
|
|
||||||
|
# Volume control keys:
|
||||||
|
volume_down_1 = <
|
||||||
|
volume_up_1 = >
|
||||||
|
volume_down_5 = , -
|
||||||
|
volume_up_5 = . =
|
||||||
|
volume_10 = M-1
|
||||||
|
volume_20 = M-2
|
||||||
|
volume_30 = M-3
|
||||||
|
volume_40 = M-4
|
||||||
|
volume_50 = M-5
|
||||||
|
volume_60 = M-6
|
||||||
|
volume_70 = M-7
|
||||||
|
volume_80 = M-8
|
||||||
|
volume_90 = M-9
|
||||||
|
|
||||||
|
# Directory navigation keys: defaults are Shift-number
|
||||||
|
# (i.e., 'shift 1' -> '!' -> 'Fastdir1').
|
||||||
|
go_to_a_directory = i
|
||||||
|
go_to_music_directory = M-m
|
||||||
|
go_to_fast_dir1 = M-a
|
||||||
|
go_to_fast_dir2 = M-l
|
||||||
|
go_to_fast_dir3 = M-p
|
||||||
|
go_to_fast_dir4 = M-d
|
||||||
|
go_to_fast_dir5 = M-c
|
||||||
|
go_to_fast_dir6 = ^
|
||||||
|
go_to_fast_dir7 = &
|
||||||
|
go_to_fast_dir8 = *
|
||||||
|
go_to_fast_dir9 = (
|
||||||
|
go_to_fast_dir10 = )
|
||||||
|
#go_to_playing_file = G
|
||||||
|
go_up = h
|
||||||
|
|
||||||
|
# Playlist specific keys:
|
||||||
|
add_file = a
|
||||||
|
add_directory = A
|
||||||
|
#plist_add_stream = u
|
||||||
|
delete_from_playlist = x
|
||||||
|
playlist_full_paths = P
|
||||||
|
plist_move_up = K
|
||||||
|
plist_move_down = J
|
||||||
|
save_playlist = V
|
||||||
|
remove_dead_entries = Y
|
||||||
|
clear_playlist = C
|
||||||
|
|
||||||
|
# Queue manipulation keys:
|
||||||
|
enqueue_file = z
|
||||||
|
clear_queue = Z
|
||||||
|
|
||||||
|
# User interaction control:
|
||||||
|
history_up = UP
|
||||||
|
history_down = DOWN
|
||||||
|
delete_to_start = ^u
|
||||||
|
delete_to_end = ^k
|
||||||
|
cancel = ^x ESCAPE
|
||||||
|
hide_message = M
|
||||||
|
|
||||||
|
# Softmixer specific keys:
|
||||||
|
toggle_softmixer = w
|
||||||
|
#toggle_make_mono = J
|
||||||
|
|
||||||
|
# Equalizer specific keys:
|
||||||
|
toggle_equalizer = E
|
||||||
|
equalizer_refresh = e
|
||||||
|
#equalizer_prev = K
|
||||||
|
#equalizer_next = k
|
||||||
|
|
||||||
|
# External commands:
|
||||||
|
mark_start = '
|
||||||
|
mark_end = "
|
||||||
|
exec_command1 = F1
|
||||||
|
exec_command2 = F2
|
||||||
|
exec_command3 = F3
|
||||||
|
exec_command4 = F4
|
||||||
|
exec_command5 = F5
|
||||||
|
exec_command6 = F6
|
||||||
|
exec_command7 = F7
|
||||||
|
exec_command8 = F8
|
||||||
|
exec_command9 = F9
|
||||||
|
exec_command10 = F10
|
||||||
|
|
||||||
|
# The following commands are available but not assigned to any keys by
|
||||||
|
# default:
|
||||||
|
#
|
||||||
|
# toggle_percent Switch on/off play progress bar time percentage
|
||||||
|
#
|
32
.config/moc/themes/theme
Executable file
32
.config/moc/themes/theme
Executable file
|
@ -0,0 +1,32 @@
|
||||||
|
background = default default
|
||||||
|
frame = red default
|
||||||
|
window_title = white default
|
||||||
|
directory = blue default bold
|
||||||
|
selected_directory = black blue bold
|
||||||
|
playlist = white default bold
|
||||||
|
selected_playlist = black blue bold
|
||||||
|
file = yellow default
|
||||||
|
selected_file = black yellow
|
||||||
|
marked_file = green default bold
|
||||||
|
marked_selected_file = black blue bold
|
||||||
|
info = blue default bold
|
||||||
|
status = white default
|
||||||
|
title = white default bold
|
||||||
|
state = white default bold
|
||||||
|
current_time = white default bold
|
||||||
|
time_left = white default
|
||||||
|
total_time = white default bold
|
||||||
|
time_total_frames = white default
|
||||||
|
sound_parameters = white default bold
|
||||||
|
legend = white default
|
||||||
|
disabled = blue default
|
||||||
|
enabled = white default bold
|
||||||
|
empty_mixer_bar = white default
|
||||||
|
filled_mixer_bar = black cyan
|
||||||
|
empty_time_bar = white default
|
||||||
|
filled_time_bar = black cyan
|
||||||
|
entry = red default
|
||||||
|
entry_title = black cyan
|
||||||
|
error = red default bold
|
||||||
|
message = green default bold
|
||||||
|
plist_time = white default bold
|
29
.config/mpd/mpd.conf
Normal file
29
.config/mpd/mpd.conf
Normal file
|
@ -0,0 +1,29 @@
|
||||||
|
####### MPD CONFIG #######
|
||||||
|
|
||||||
|
# Required files
|
||||||
|
db_file "~/.config/mpd/database"
|
||||||
|
log_file "~/.config/mpd/log"
|
||||||
|
|
||||||
|
# Optional
|
||||||
|
music_directory "~/Music"
|
||||||
|
playlist_directory "~/.config/mpd/playlists"
|
||||||
|
pid_file "~/.config/mpd/pid"
|
||||||
|
state_file "~/.config/mpd/state"
|
||||||
|
sticker_file "~/.config/mpd/sticker.sql"
|
||||||
|
|
||||||
|
max_output_buffer_size "16384"
|
||||||
|
|
||||||
|
audio_output {
|
||||||
|
type "alsa"
|
||||||
|
name "mpd alsamixer-output"
|
||||||
|
mixer_type "software"
|
||||||
|
}
|
||||||
|
|
||||||
|
audio_output {
|
||||||
|
type "fifo"
|
||||||
|
name "toggle_visualizer"
|
||||||
|
path "/tmp/mpd.fifo"
|
||||||
|
format "44100:16:2"
|
||||||
|
}
|
||||||
|
|
||||||
|
####### END MPD CONFIG #######
|
199
.config/mpv/input.conf
Normal file
199
.config/mpv/input.conf
Normal file
|
@ -0,0 +1,199 @@
|
||||||
|
# mpv keybindings
|
||||||
|
#
|
||||||
|
# Location of user-defined bindings: ~/.config/mpv/input.conf
|
||||||
|
#
|
||||||
|
# Lines starting with # are comments. Use SHARP to assign the # key.
|
||||||
|
# Copy this file and uncomment and edit the bindings you want to change.
|
||||||
|
#
|
||||||
|
# List of commands and further details: DOCS/man/input.rst
|
||||||
|
# List of special keys: --input-keylist
|
||||||
|
# Keybindings testing mode: mpv --input-test --force-window --idle
|
||||||
|
#
|
||||||
|
# Use 'ignore' to unbind a key fully (e.g. 'ctrl+a ignore').
|
||||||
|
#
|
||||||
|
# Strings need to be quoted and escaped:
|
||||||
|
# KEY show-text "This is a single backslash: \\ and a quote: \" !"
|
||||||
|
#
|
||||||
|
# You can use modifier-key combinations like Shift+Left or Ctrl+Alt+x with
|
||||||
|
# the modifiers Shift, Ctrl, Alt and Meta (may not work on the terminal).
|
||||||
|
#
|
||||||
|
# The default keybindings are hardcoded into the mpv binary.
|
||||||
|
# You can disable them completely with: --no-input-default-bindings
|
||||||
|
|
||||||
|
# Developer note:
|
||||||
|
# On compilation, this file is baked into the mpv binary, and all lines are
|
||||||
|
# uncommented (unless '#' is followed by a space) - thus this file defines the
|
||||||
|
# default key bindings.
|
||||||
|
|
||||||
|
# If this is enabled, treat all the following bindings as default.
|
||||||
|
#default-bindings start
|
||||||
|
|
||||||
|
#MOUSE_BTN0 ignore # don't do anything
|
||||||
|
#MOUSE_BTN0_DBL cycle fullscreen # toggle fullscreen on/off
|
||||||
|
#MOUSE_BTN2 cycle pause # toggle pause on/off
|
||||||
|
#MOUSE_BTN3 seek 10
|
||||||
|
#MOUSE_BTN4 seek -10
|
||||||
|
#MOUSE_BTN5 add volume -2
|
||||||
|
#MOUSE_BTN6 add volume 2
|
||||||
|
|
||||||
|
# Mouse wheels, touchpad or other input devices that have axes
|
||||||
|
# if the input devices supports precise scrolling it will also scale the
|
||||||
|
# numeric value accordingly
|
||||||
|
#AXIS_UP seek 10
|
||||||
|
#AXIS_DOWN seek -10
|
||||||
|
#AXIS_LEFT seek 5
|
||||||
|
#AXIS_RIGHT seek -5
|
||||||
|
|
||||||
|
## Seek units are in seconds, but note that these are limited by keyframes
|
||||||
|
#RIGHT seek 5
|
||||||
|
#LEFT seek -5
|
||||||
|
#UP seek 60
|
||||||
|
#DOWN seek -60
|
||||||
|
# Do smaller, always exact (non-keyframe-limited), seeks with shift.
|
||||||
|
# Don't show them on the OSD (no-osd).
|
||||||
|
#Shift+RIGHT no-osd seek 1 exact
|
||||||
|
#Shift+LEFT no-osd seek -1 exact
|
||||||
|
#Shift+UP no-osd seek 5 exact
|
||||||
|
#Shift+DOWN no-osd seek -5 exact
|
||||||
|
# Skip to previous/next subtitle (subject to some restrictions; see manpage)
|
||||||
|
#Ctrl+LEFT no-osd sub-seek -1
|
||||||
|
#Ctrl+RIGHT no-osd sub-seek 1
|
||||||
|
#PGUP add chapter 1 # skip to next chapter
|
||||||
|
#PGDWN add chapter -1 # skip to previous chapter
|
||||||
|
#Shift+PGUP seek 600
|
||||||
|
#Shift+PGDWN seek -600
|
||||||
|
#[ multiply speed 0.9091 # scale playback speed
|
||||||
|
#] multiply speed 1.1
|
||||||
|
#{ multiply speed 0.5
|
||||||
|
#} multiply speed 2.0
|
||||||
|
#BS set speed 1.0 # reset speed to normal
|
||||||
|
#q quit
|
||||||
|
#Q quit-watch-later
|
||||||
|
#q {encode} quit 4
|
||||||
|
#ESC set fullscreen no
|
||||||
|
#ESC {encode} quit 4
|
||||||
|
#p cycle pause # toggle pause/playback mode
|
||||||
|
#. frame-step # advance one frame and pause
|
||||||
|
#, frame-back-step # go back by one frame and pause
|
||||||
|
#SPACE cycle pause
|
||||||
|
#> playlist-next # skip to next file
|
||||||
|
#ENTER playlist-next # skip to next file
|
||||||
|
#< playlist-prev # skip to previous file
|
||||||
|
#O no-osd cycle-values osd-level 3 1 # cycle through OSD mode
|
||||||
|
#o show-progress
|
||||||
|
#P show-progress
|
||||||
|
#I show-text "${filename}" # display filename in osd
|
||||||
|
#z add sub-delay -0.1 # subtract 100 ms delay from subs
|
||||||
|
#x add sub-delay +0.1 # add
|
||||||
|
#ctrl++ add audio-delay 0.100 # this changes audio/video sync
|
||||||
|
#ctrl+- add audio-delay -0.100
|
||||||
|
#9 add volume -2
|
||||||
|
#/ add volume -2
|
||||||
|
#0 add volume 2
|
||||||
|
#* add volume 2
|
||||||
|
#m cycle mute
|
||||||
|
#1 add contrast -1
|
||||||
|
#2 add contrast 1
|
||||||
|
#3 add brightness -1
|
||||||
|
#4 add brightness 1
|
||||||
|
#5 add gamma -1
|
||||||
|
#6 add gamma 1
|
||||||
|
#7 add saturation -1
|
||||||
|
#8 add saturation 1
|
||||||
|
#Alt+0 set window-scale 0.5
|
||||||
|
#Alt+1 set window-scale 1.0
|
||||||
|
#Alt+2 set window-scale 2.0
|
||||||
|
# toggle deinterlacer (automatically inserts or removes required filter)
|
||||||
|
#d cycle deinterlace
|
||||||
|
#r add sub-pos -1 # move subtitles up
|
||||||
|
#t add sub-pos +1 # down
|
||||||
|
#v cycle sub-visibility
|
||||||
|
# stretch SSA/ASS subtitles with anamorphic videos to match historical
|
||||||
|
#V cycle sub-ass-vsfilter-aspect-compat
|
||||||
|
# switch between applying no style overrides to SSA/ASS subtitles, and
|
||||||
|
# overriding them almost completely with the normal subtitle style
|
||||||
|
#u cycle-values sub-ass-style-override "force" "no"
|
||||||
|
#j cycle sub # cycle through subtitles
|
||||||
|
#J cycle sub down # ...backwards
|
||||||
|
#SHARP cycle audio # switch audio streams
|
||||||
|
#_ cycle video
|
||||||
|
#T cycle ontop # toggle video window ontop of other windows
|
||||||
|
#f cycle fullscreen # toggle fullscreen
|
||||||
|
#s screenshot # take a screenshot
|
||||||
|
#S screenshot video # ...without subtitles
|
||||||
|
#Ctrl+s screenshot window # ...with subtitles and OSD, and scaled
|
||||||
|
#Alt+s screenshot each-frame # automatically screenshot every frame
|
||||||
|
#w add panscan -0.1 # zoom out with -panscan 0 -fs
|
||||||
|
#e add panscan +0.1 # in
|
||||||
|
# cycle video aspect ratios; "-1" is the container aspect
|
||||||
|
#A cycle-values video-aspect "16:9" "4:3" "2.35:1" "-1"
|
||||||
|
#POWER quit
|
||||||
|
#PLAY cycle pause
|
||||||
|
#PAUSE cycle pause
|
||||||
|
#PLAYPAUSE cycle pause
|
||||||
|
#STOP quit
|
||||||
|
#FORWARD seek 60
|
||||||
|
#REWIND seek -60
|
||||||
|
#NEXT playlist-next
|
||||||
|
#PREV playlist-prev
|
||||||
|
#VOLUME_UP add volume 2
|
||||||
|
#VOLUME_DOWN add volume -2
|
||||||
|
#MUTE cycle mute
|
||||||
|
#CLOSE_WIN quit
|
||||||
|
#CLOSE_WIN {encode} quit 4
|
||||||
|
#E cycle edition # next edition
|
||||||
|
#l ab-loop # Set/clear A-B loop points
|
||||||
|
#L cycle-values loop "inf" "no" # toggle infinite looping
|
||||||
|
#ctrl+c quit 4
|
||||||
|
|
||||||
|
# Apple Remote section
|
||||||
|
#AR_PLAY cycle pause
|
||||||
|
#AR_PLAY_HOLD quit
|
||||||
|
#AR_CENTER cycle pause
|
||||||
|
#AR_CENTER_HOLD quit
|
||||||
|
#AR_NEXT seek 10
|
||||||
|
#AR_NEXT_HOLD seek 120
|
||||||
|
#AR_PREV seek -10
|
||||||
|
#AR_PREV_HOLD seek -120
|
||||||
|
#AR_MENU show-progress
|
||||||
|
#AR_MENU_HOLD cycle mute
|
||||||
|
#AR_VUP add volume 2
|
||||||
|
#AR_VUP_HOLD add chapter 1
|
||||||
|
#AR_VDOWN add volume -2
|
||||||
|
#AR_VDOWN_HOLD add chapter -1
|
||||||
|
|
||||||
|
# For tv://
|
||||||
|
#h cycle tv-channel -1 # previous channel
|
||||||
|
#k cycle tv-channel +1 # next channel
|
||||||
|
|
||||||
|
# For dvb://
|
||||||
|
#H cycle dvb-channel-name -1 # previous channel
|
||||||
|
#K cycle dvb-channel-name +1 # next channel
|
||||||
|
|
||||||
|
#
|
||||||
|
# Legacy bindings (may or may not be removed in the future)
|
||||||
|
#
|
||||||
|
#! add chapter -1 # skip to previous chapter
|
||||||
|
#@ add chapter 1 # next
|
||||||
|
|
||||||
|
#
|
||||||
|
# Not assigned by default
|
||||||
|
# (not an exhaustive list of unbound commands)
|
||||||
|
#
|
||||||
|
|
||||||
|
# ? add sub-scale +0.1 # increase subtitle font size
|
||||||
|
# ? add sub-scale -0.1 # decrease subtitle font size
|
||||||
|
# ? sub-step -1 # immediately display next subtitle
|
||||||
|
# ? sub-step +1 # previous
|
||||||
|
# ? cycle angle # switch DVD/Bluray angle
|
||||||
|
# ? add balance -0.1 # adjust audio balance in favor of left
|
||||||
|
# ? add balance 0.1 # right
|
||||||
|
# ? cycle sub-forced-only # toggle DVD forced subs
|
||||||
|
# ? cycle program # cycle transport stream programs
|
||||||
|
# ? stop # stop playback (quit or enter idle mode)
|
||||||
|
|
||||||
|
l seek 5
|
||||||
|
h seek -5
|
||||||
|
j seek -60
|
||||||
|
k seek 60
|
||||||
|
S cycle sub
|
13
.config/mutt/aliases
Normal file
13
.config/mutt/aliases
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
#Here you can put email aliases. Here's an example:
|
||||||
|
|
||||||
|
alias luke luke@lukesmith.xyz
|
||||||
|
|
||||||
|
#When you put "luke" as the recipient in mutt, it will automatically direct it to my email address.
|
||||||
|
|
||||||
|
#You can also put multiple emails under one aliases:
|
||||||
|
|
||||||
|
alias project_members billy@gmail.com, sally@gmail.com, amanda@gmail.com, chad@gmail.com
|
||||||
|
|
||||||
|
#With the above alias, if you put "project_members" as the recipient, mutt will fill in all the emails above as the recipients.
|
||||||
|
#
|
||||||
|
#This is extremely useful, so take advantage of it!
|
40
.config/mutt/email.md
Normal file
40
.config/mutt/email.md
Normal file
|
@ -0,0 +1,40 @@
|
||||||
|
# Luke's mutt/OfflineIMAP/msmtp/notmuch setup
|
||||||
|
|
||||||
|
## My email setup gives you the following:
|
||||||
|
|
||||||
|
+ A clean, fast and vim-like terminal interface to send and read email (mutt)
|
||||||
|
+ OfflineIMAP, which takes keep a copy of all of your mail offline, allowing you to read and
|
||||||
|
+ notmuch as an email indexer, which allows you to easily search email by content within mutt.
|
||||||
|
+ A looping script which continually uses OfflineIMAP to check mail, and if there is new mail, it will both notify you with a ding and then tell notmuch to quickly index the new mail for searching.
|
||||||
|
|
||||||
|
All of these features are well synced together and require just a little setup.
|
||||||
|
|
||||||
|
To use my email setup, be sure to have `neomutt`, `offlineimap`, `msmtp` `notmuch` and `notmuch-mutt` installed.
|
||||||
|
|
||||||
|
Note that the notification sound will work on i3 by default. You can edit the notification command that runs in `.config/Scripts/check.sh`.
|
||||||
|
|
||||||
|
## How to set it up.
|
||||||
|
|
||||||
|
To use this setup, you have to add your email settings where required.
|
||||||
|
|
||||||
|
There are several steps after which everything should work nicely.
|
||||||
|
|
||||||
|
+ **First**, open `.offlineimaprc` and add your email account and server info (details are in that file.
|
||||||
|
+ To index your mail for quick searching, run `notmuch setup` and give your mail directory (`~/.Mail` by default in my configs)
|
||||||
|
+ Then you can go ahead and start syncing your email by running `offlineimap -o`. This will download your mail from all the accounts you use to `~/.Mail`.
|
||||||
|
+ If you want to use my autosync loop script, make sure to check `.config/Scripts/inboxes` to ensure that your inboxes are there.
|
||||||
|
+ Next, add your email account info to `.msmtprc`.
|
||||||
|
+ And the same to `.config/mutt/personalrc` or `.config/mutt/gmailrc` or your own rc file.
|
||||||
|
+ (mutt will try to load the `gmailrc` by default. You can change this in `.config/mutt/muttrc`.)
|
||||||
|
|
||||||
|
## Updating
|
||||||
|
|
||||||
|
As I said before, I have a loop script in `.config/Scripts/mailsyncloop.sh` which will run OfflineIMAPs every few minutes and will play a notification sound and run notmuch if new mail is found.
|
||||||
|
|
||||||
|
I suggest running this scipt in a tty or tmux session, so you can check up on it if you really want. That's what I do.
|
||||||
|
|
||||||
|
## Enjoy your email!
|
||||||
|
|
||||||
|
If you're using my i3 config, you can run mutt with `mutt`. Explore the `muttrc` to see my bindings and add your own.
|
||||||
|
|
||||||
|
If you're not using my i3 config, you may want to move `muttrc` to `~/.muttrc`, because I keep my `muttrc` in the `.config` directory to different reasons, but it will look only in `~` by default.
|
30
.config/mutt/gmailrc
Normal file
30
.config/mutt/gmailrc
Normal file
|
@ -0,0 +1,30 @@
|
||||||
|
# vim: filetype=muttrc
|
||||||
|
# Gmail app password should be generated for this configuration file. Never use your proper password in a standard text field.
|
||||||
|
set imap_user = "YOURNAME@gmail.com"
|
||||||
|
set smtp_url = "smtp://YOURNAME@smtp.gmail.com:587/"
|
||||||
|
set from = "YOURNAME@gmail.com"
|
||||||
|
set realname = "YOUR ACTUAL NAME"
|
||||||
|
set mbox_type = Maildir
|
||||||
|
set sendmail = "/usr/bin/msmtp -a gmail"
|
||||||
|
set folder = "~/.Mail/Gmail"
|
||||||
|
set spoolfile = "+INBOX"
|
||||||
|
set record = /dev/null
|
||||||
|
set mbox = "+[Gmail].All Mail"
|
||||||
|
set postponed = "+[Gmail].Drafts"
|
||||||
|
set header_cache = ~/.config/mutt/gmail/cache/headers
|
||||||
|
set message_cachedir = ~/.config/mutt/gmail/cache/bodies
|
||||||
|
set certificate_file = ~/.config/mutt/gmail/certificates
|
||||||
|
set ssl_starttls = yes
|
||||||
|
set ssl_force_tls = yes
|
||||||
|
|
||||||
|
mailboxes +INBOX
|
||||||
|
|
||||||
|
bind index g noop
|
||||||
|
macro index gi "<change-folder>=INBOX<enter>" "Go to inbox"
|
||||||
|
macro index ga "<change-folder>=[Gmail].All Mail<enter>" "Go to all mail"
|
||||||
|
macro index gs "<change-folder>=[Gmail].Sent Mail<enter>" "Go to sent mail"
|
||||||
|
macro index gS "<change-folder>=[Gmail].Spam<enter>" "Go to spam"
|
||||||
|
macro index gt "<change-folder>=[Gmail].Trash<enter>" "Go to trash"
|
||||||
|
macro index gd "<change-folder>=[Gmail].Drafts<enter>" "Go to drafts"
|
||||||
|
macro index gl "<change-folder>=lingcircle<enter>" "Go to lingcircle"
|
||||||
|
macro index gr "<change-folder>=ugaroml<enter>" "Go to ugaroml"
|
11
.config/mutt/mailcap
Normal file
11
.config/mutt/mailcap
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
#text/html; qutebrowser %s &; test=test -n "$DISPLAY"; needsterminal;
|
||||||
|
|
||||||
|
text/html; w3m -I %{charset} -T text/html; copiousoutput;
|
||||||
|
#text/html; mv %s %s.html && qutebrowser %s.html > /dev/null; needsterminal;
|
||||||
|
#
|
||||||
|
application/pdf; mv %s %s.pdf && mupdf %s.pdf > /dev/null; needsterminal;
|
||||||
|
|
||||||
|
image/*; ~/.config/mutt/muttimage.sh %s ; copiousoutput
|
||||||
|
|
||||||
|
#application/pdf; pdftotext '%s' -; copiousoutput; description=PDF Document;
|
||||||
|
#nametemplate=%s.pdf
|
151
.config/mutt/muttcol
Normal file
151
.config/mutt/muttcol
Normal file
|
@ -0,0 +1,151 @@
|
||||||
|
# vim: filetype=muttrc
|
||||||
|
|
||||||
|
#
|
||||||
|
#
|
||||||
|
# make sure that you are using mutt linked against slang, not ncurses, or
|
||||||
|
# suffer the consequences of weird color issues. use "mutt -v" to check this.
|
||||||
|
|
||||||
|
# custom body highlights -----------------------------------------------
|
||||||
|
# highlight my name and other personally relevant strings
|
||||||
|
#color body yellow default "(ethan|schoonover)"
|
||||||
|
# custom index highlights ----------------------------------------------
|
||||||
|
# messages which mention my name in the body
|
||||||
|
#color index yellow default "~b \"phil(_g|\!| gregory| gold)|pgregory\" !~N !~T !~F !~p !~P"
|
||||||
|
#color index J_cream brightwhite "~b \"phil(_g|\!| gregory| gold)|pgregory\" ~N !~T !~F !~p !~P"
|
||||||
|
#color index yellow cyan "~b \"phil(_g|\!| gregory| gold)|pgregory\" ~T !~F !~p !~P"
|
||||||
|
#color index yellow J_magent "~b \"phil(_g|\!| gregory| gold)|pgregory\" ~F !~p !~P"
|
||||||
|
## messages which are in reference to my mails
|
||||||
|
#color index J_magent default "~x \"(mithrandir|aragorn)\\.aperiodic\\.net|thorin\\.hillmgt\\.com\" !~N !~T !~F !~p !~P"
|
||||||
|
#color index J_magent brightwhite "~x \"(mithrandir|aragorn)\\.aperiodic\\.net|thorin\\.hillmgt\\.com\" ~N !~T !~F !~p !~P"
|
||||||
|
#color index J_magent cyan "~x \"(mithrandir|aragorn)\\.aperiodic\\.net|thorin\\.hillmgt\\.com\" ~T !~F !~p !~P"
|
||||||
|
#color index J_magent red "~x \"(mithrandir|aragorn)\\.aperiodic\\.net|thorin\\.hillmgt\\.com\" ~F !~p !~P"
|
||||||
|
|
||||||
|
# for background in 16 color terminal, valid background colors include:
|
||||||
|
# base03, bg, black, any of the non brights
|
||||||
|
|
||||||
|
# basic colors ---------------------------------------------------------
|
||||||
|
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 J_black J_status
|
||||||
|
color status brightyellow black
|
||||||
|
color indicator brightblack yellow
|
||||||
|
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 red default "~D(!~p|~p)" # deleted
|
||||||
|
#color index black default ~F # flagged
|
||||||
|
#color index brightred default ~= # duplicate messages
|
||||||
|
#color index brightgreen default "~A!~N!~T!~p!~Q!~F!~D!~P" # the rest
|
||||||
|
#color index J_base default "~A~N!~T!~p!~Q!~F!~D" # the rest, new
|
||||||
|
color index red default "~A" # all messages
|
||||||
|
color index brightred default "~E" # expired messages
|
||||||
|
color index blue 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 blue default "~U" # unread messages
|
||||||
|
color index blue default "~U~$" # unread, unreferenced messages
|
||||||
|
color index brightyellow default "~v" # messages part of a collapsed thread
|
||||||
|
color index brightyellow 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
|
||||||
|
# statusbg used to indicated flagged when foreground color shows other status
|
||||||
|
# for collapsed thread
|
||||||
|
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
|
||||||
|
#color index brightred red "~=" # duplicated messages
|
||||||
|
|
||||||
|
# message headers ------------------------------------------------------
|
||||||
|
|
||||||
|
#color header brightgreen default "^"
|
||||||
|
color hdrdefault brightgreen default
|
||||||
|
color header brightyellow default "^(From)"
|
||||||
|
color header blue default "^(Subject)"
|
||||||
|
|
||||||
|
# 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 "[*]?((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?
|
||||||
|
|
||||||
|
## 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<>\"]"
|
||||||
|
# and a heavy handed email regex
|
||||||
|
#color body J_magent default "((@(([0-9a-z-]+\\.)*[0-9a-z-]+\\.?|#[0-9]+|\\[[0-9]?[0-9]?[0-9]\\.[0-9]?[0-9]?[0-9]\\.[0-9]?[0-9]?[0-9]\\.[0-9]?[0-9]?[0-9]\\]),)*@(([0-9a-z-]+\\.)*[0-9a-z-]+\\.?|#[0-9]+|\\[[0-9]?[0-9]?[0-9]\\.[0-9]?[0-9]?[0-9]\\.[0-9]?[0-9]?[0-9]\\.[0-9]?[0-9]?[0-9]\\]):)?[0-9a-z_.+%$-]+@(([0-9a-z-]+\\.)*[0-9a-z-]+\\.?|#[0-9]+|\\[[0-2]?[0-9]?[0-9]\\.[0-2]?[0-9]?[0-9]\\.[0-2]?[0-9]?[0-9]\\.[0-2]?[0-9]?[0-9]\\])"
|
||||||
|
|
||||||
|
# Various smilies and the like
|
||||||
|
#color body brightwhite default "<[Gg]>" # <g>
|
||||||
|
#color body brightwhite default "<[Bb][Gg]>" # <bg>
|
||||||
|
#color body yellow default " [;:]-*[})>{(<|]" # :-) etc...
|
||||||
|
# *bold*
|
||||||
|
#color body blue default "(^|[[:space:][:punct:]])\\*[^*]+\\*([[:space:][:punct:]]|$)"
|
||||||
|
#mono body bold "(^|[[:space:][:punct:]])\\*[^*]+\\*([[:space:][:punct:]]|$)"
|
||||||
|
# _underline_
|
||||||
|
#color body blue default "(^|[[:space:][:punct:]])_[^_]+_([[:space:][:punct:]]|$)"
|
||||||
|
#mono body underline "(^|[[:space:][:punct:]])_[^_]+_([[:space:][:punct:]]|$)"
|
||||||
|
# /italic/ (Sometimes gets directory names)
|
||||||
|
#color body blue default "(^|[[:space:][:punct:]])/[^/]+/([[:space:][:punct:]]|$)"
|
||||||
|
#mono body underline "(^|[[:space:][:punct:]])/[^/]+/([[:space:][:punct:]]|$)"
|
||||||
|
|
||||||
|
# Border lines.
|
||||||
|
#color body blue default "( *[-+=#*~_]){6,}"
|
||||||
|
|
||||||
|
#folder-hook . "color status J_black J_status "
|
||||||
|
#folder-hook gmail/inbox "color status J_black yellow "
|
||||||
|
#folder-hook gmail/important "color status J_black yellow "
|
||||||
|
|
8
.config/mutt/muttimage.sh
Executable file
8
.config/mutt/muttimage.sh
Executable file
|
@ -0,0 +1,8 @@
|
||||||
|
#! /bin/sh
|
||||||
|
|
||||||
|
#### Determine size of Terminal
|
||||||
|
height=`stty size | awk 'BEGIN {FS = " "} {print $1;}'`
|
||||||
|
width=`stty size | awk 'BEGIN {FS = " "} {print $2;}'`
|
||||||
|
|
||||||
|
### Display Image / offset with mutt bar
|
||||||
|
echo -e "2;3;\n0;1;210;20;$((width*7-250));$((height*14-100));0;0;0;0;$1\n4;\n3;" | /usr/lib/w3m/w3mimgdisplay &
|
41
.config/mutt/muttrc
Normal file
41
.config/mutt/muttrc
Normal file
|
@ -0,0 +1,41 @@
|
||||||
|
source ~/.config/mutt/gmailrc
|
||||||
|
source ~/.config/mutt/muttcol
|
||||||
|
source ~/.config/mutt/aliases
|
||||||
|
|
||||||
|
set sort = 'reverse-date'
|
||||||
|
set editor = vim
|
||||||
|
#set copy = no
|
||||||
|
set timeout = "5"
|
||||||
|
set mail_check = "10"
|
||||||
|
set mailcap_path = ~/.config/mutt/mailcap
|
||||||
|
set date_format="%m/%d %I:%M"
|
||||||
|
set index_format="%2C %Z %d %-15.15F %s (%-4.4c)"
|
||||||
|
|
||||||
|
auto_view text/html
|
||||||
|
alternative_order text/plain text/enriched text/html
|
||||||
|
|
||||||
|
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]+
|
||||||
|
|
||||||
|
bind editor <space> noop
|
||||||
|
bind index G last-entry
|
||||||
|
bind index gg first-entry
|
||||||
|
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 R group-reply
|
||||||
|
|
||||||
|
auto_view application/pdf
|
||||||
|
|
||||||
|
macro index,pager U "<enter-command>set pipe_decode = yes<enter><pipe-message>urlview<enter><enter-command>set pipe_decode = no<enter>""view URLs"
|
23
.config/mutt/personalrc
Normal file
23
.config/mutt/personalrc
Normal file
|
@ -0,0 +1,23 @@
|
||||||
|
# vim: filetype=muttrc
|
||||||
|
set imap_user = "YOU@YOURDOMAIN.COM"
|
||||||
|
set smtp_url = "SMTPSERVERINFO:PORT"
|
||||||
|
set realname = "YOUR NAME"
|
||||||
|
set mbox_type = Maildir
|
||||||
|
set sendmail = "/usr/bin/msmtp -a personal"
|
||||||
|
set folder = "~/.Mail/Personal"
|
||||||
|
set spoolfile = +INBOX
|
||||||
|
set record = +INBOX.Sent
|
||||||
|
set postponed = +INBOX.Drafts
|
||||||
|
set header_cache = ~/.config/mutt/Personal/cache/headers
|
||||||
|
set message_cachedir = ~/.config/mutt/Personal/cache/bodies
|
||||||
|
set certificate_file = ~/.config/mutt/Personal/certificates
|
||||||
|
set ssl_starttls = yes
|
||||||
|
set ssl_force_tls = yes
|
||||||
|
|
||||||
|
bind index g noop
|
||||||
|
bind index gg first-entry
|
||||||
|
macro index gi "<change-folder>=INBOX<enter>" "Go to inbox"
|
||||||
|
macro index gs "<change-folder>=INBOX.Sent<enter>" "Go to sent"
|
||||||
|
macro index gd "<change-folder>=INBOX.Drafts<enter>" "Go to drafts"
|
||||||
|
macro index gj "<change-folder>=INBOX.Junk<enter>" "Go to junk"
|
||||||
|
macro index gt "<change-folder>=INBOX.Trash<enter>" "Go to trash"
|
431
.config/neofetch/config
Executable file
431
.config/neofetch/config
Executable file
|
@ -0,0 +1,431 @@
|
||||||
|
#!/usr/bin/env bash
|
||||||
|
# vim:fdm=marker
|
||||||
|
#
|
||||||
|
# Neofetch config file
|
||||||
|
# https://github.com/dylanaraps/neofetch
|
||||||
|
|
||||||
|
# Speed up script by not using unicode
|
||||||
|
export LC_ALL=C
|
||||||
|
export LANG=C
|
||||||
|
|
||||||
|
# Info Options {{{
|
||||||
|
|
||||||
|
|
||||||
|
# Info
|
||||||
|
# See this wiki page for more info:
|
||||||
|
# https://github.com/dylanaraps/neofetch/wiki/Customizing-Info
|
||||||
|
printinfo () {
|
||||||
|
info title
|
||||||
|
info underline
|
||||||
|
|
||||||
|
info "Model" model
|
||||||
|
info "OS" distro
|
||||||
|
info "Kernel" kernel
|
||||||
|
info "Uptime" uptime
|
||||||
|
info "Packages" packages
|
||||||
|
info "Shell" shell
|
||||||
|
info "Resolution" resolution
|
||||||
|
info "DE" de
|
||||||
|
info "WM" wm
|
||||||
|
info "WM Theme" wmtheme
|
||||||
|
#info "Theme" theme
|
||||||
|
#info "Icons" icons
|
||||||
|
info "Terminal" term
|
||||||
|
info "Terminal Font" termfont
|
||||||
|
info "CPU" cpu
|
||||||
|
info "GPU" gpu
|
||||||
|
info "Memory" memory
|
||||||
|
|
||||||
|
info "CPU Usage" cpu_usage
|
||||||
|
info "Disk" disk
|
||||||
|
#info "Battery" battery
|
||||||
|
#info "Font" font
|
||||||
|
#info "Song" song
|
||||||
|
# info "Local IP" localip
|
||||||
|
# info "Public IP" publicip
|
||||||
|
#info "Users" users
|
||||||
|
#info "Birthday" birthday
|
||||||
|
|
||||||
|
info linebreak
|
||||||
|
info cols
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
# Kernel
|
||||||
|
|
||||||
|
# Show more kernel info
|
||||||
|
# --kernel_shorthand on/off
|
||||||
|
kernel_shorthand="on"
|
||||||
|
|
||||||
|
|
||||||
|
# Distro
|
||||||
|
|
||||||
|
# Shorten the output of distro (tiny, on, off)
|
||||||
|
# NOTE: This is only possible on Linux
|
||||||
|
distro_shorthand="off"
|
||||||
|
|
||||||
|
# Mac OS X hide/show build version
|
||||||
|
# --osx_buildversion on/off
|
||||||
|
osx_buildversion="on"
|
||||||
|
|
||||||
|
# Mac OS X hide/show codename
|
||||||
|
# --osx_codename on/off
|
||||||
|
osx_codename="on"
|
||||||
|
|
||||||
|
# Show 'x86_64' and 'x86' in 'Distro:' output.
|
||||||
|
# --os_arch on/off
|
||||||
|
os_arch="on"
|
||||||
|
|
||||||
|
|
||||||
|
# Uptime
|
||||||
|
|
||||||
|
# Shorten the output of the uptime function
|
||||||
|
# --uptime_shorthand tiny, on, off
|
||||||
|
uptime_shorthand="off"
|
||||||
|
|
||||||
|
|
||||||
|
# Shell
|
||||||
|
|
||||||
|
# Show the path to $SHELL
|
||||||
|
# --shell_path on/off
|
||||||
|
shell_path="on"
|
||||||
|
|
||||||
|
# Show $SHELL's version
|
||||||
|
# --shell_version on/off
|
||||||
|
shell_version="off"
|
||||||
|
|
||||||
|
|
||||||
|
# CPU
|
||||||
|
|
||||||
|
# CPU speed type
|
||||||
|
# Only works on Linux with cpufreq.
|
||||||
|
# --speed_type current, min, max, bios,
|
||||||
|
# scaling_current, scaling_min, scaling_max
|
||||||
|
speed_type="max"
|
||||||
|
|
||||||
|
# CPU Shorthand
|
||||||
|
# Set shorthand setting
|
||||||
|
# --cpu_shorthand name, speed, tiny, on, off
|
||||||
|
cpu_shorthand="off"
|
||||||
|
|
||||||
|
# CPU Usage display
|
||||||
|
# Set CPU usage display setting
|
||||||
|
# --cpu_display bar, infobar, barinfo, off
|
||||||
|
cpu_display="off"
|
||||||
|
|
||||||
|
# CPU Cores
|
||||||
|
# Display CPU cores in output
|
||||||
|
# --cpu_cores on/off
|
||||||
|
cpu_cores="on"
|
||||||
|
|
||||||
|
|
||||||
|
# GPU
|
||||||
|
|
||||||
|
# Shorten output of the getgpu funcion
|
||||||
|
# --gpu_shorthand on/off/tiny
|
||||||
|
gpu_shorthand="on"
|
||||||
|
|
||||||
|
# Enable/Disable GPU Brand
|
||||||
|
# --gpu_brand on/off
|
||||||
|
gpu_brand="on"
|
||||||
|
|
||||||
|
# Resolution
|
||||||
|
|
||||||
|
# Display refresh rate next to each monitor
|
||||||
|
# Unsupported on Windows
|
||||||
|
# --refresh_rate on/off
|
||||||
|
refresh_rate="off"
|
||||||
|
|
||||||
|
|
||||||
|
# Gtk Theme / Icons
|
||||||
|
|
||||||
|
# Shorten output (Hide [GTK2] etc)
|
||||||
|
# --gtk_shorthand on/off
|
||||||
|
gtk_shorthand="off"
|
||||||
|
|
||||||
|
|
||||||
|
# Enable/Disable gtk2 theme/icons output
|
||||||
|
# --gtk2 on/off
|
||||||
|
gtk2="on"
|
||||||
|
|
||||||
|
# Enable/Disable gtk3 theme/icons output
|
||||||
|
# --gtk3 on/off
|
||||||
|
gtk3="on"
|
||||||
|
|
||||||
|
|
||||||
|
# Battery
|
||||||
|
|
||||||
|
# Which battery to display.
|
||||||
|
# By default we display all batteries.
|
||||||
|
# NOTE: Only works on Linux.
|
||||||
|
# --battery_num all, 0, 1, 2, etc
|
||||||
|
battery_num="all"
|
||||||
|
|
||||||
|
# Whether or not to print each battery on the same line.
|
||||||
|
# By default each battery gets its own line and title.
|
||||||
|
# NOTE: Only works on Linux.
|
||||||
|
# --battery_shorthand on/off
|
||||||
|
battery_shorthand="off"
|
||||||
|
|
||||||
|
|
||||||
|
# IP Address
|
||||||
|
|
||||||
|
# Website to ping for the public IP
|
||||||
|
# --ip_host url
|
||||||
|
public_ip_host="http://ident.me"
|
||||||
|
|
||||||
|
|
||||||
|
# Song
|
||||||
|
|
||||||
|
# Print the Artist and Title on seperate lines
|
||||||
|
# --song_shorthand on/off
|
||||||
|
song_shorthand="off"
|
||||||
|
|
||||||
|
|
||||||
|
# Birthday
|
||||||
|
|
||||||
|
# Whether to show a long pretty output
|
||||||
|
# or a shortened one
|
||||||
|
# NOTE: Long pretty output doesn't work on OpenBSD or NetBSD.
|
||||||
|
# --birthday_shorthand on/off
|
||||||
|
birthday_shorthand="off"
|
||||||
|
|
||||||
|
# Whether to show the time in the output
|
||||||
|
# --birthday_time on/off
|
||||||
|
birthday_time="on"
|
||||||
|
|
||||||
|
# Date format to use when printing birthday
|
||||||
|
# --birthday_format "format"
|
||||||
|
birthday_format="+%a %d %b %Y %l:%M %p"
|
||||||
|
|
||||||
|
|
||||||
|
# }}}
|
||||||
|
|
||||||
|
# Text Colors {{{
|
||||||
|
|
||||||
|
|
||||||
|
# Text Colors
|
||||||
|
# Each number represents a different part of
|
||||||
|
# the text in this order:
|
||||||
|
# title, @, underline, subtitle, colon, info
|
||||||
|
# colors=(4 6 1 8 8 6)
|
||||||
|
# You can also specify:
|
||||||
|
# fg (foreground color)
|
||||||
|
colors=(distro)
|
||||||
|
|
||||||
|
|
||||||
|
# }}}
|
||||||
|
|
||||||
|
# Text Options {{{
|
||||||
|
|
||||||
|
|
||||||
|
# Toggle bold text
|
||||||
|
# --bold on/off
|
||||||
|
bold="on"
|
||||||
|
|
||||||
|
# Enable/Disable Underline
|
||||||
|
# --underline on/off
|
||||||
|
underline_enabled="on"
|
||||||
|
|
||||||
|
# Underline character
|
||||||
|
# --underline_char char
|
||||||
|
underline_char="-"
|
||||||
|
|
||||||
|
|
||||||
|
# }}}
|
||||||
|
|
||||||
|
# Color Blocks {{{
|
||||||
|
|
||||||
|
|
||||||
|
# Color block range
|
||||||
|
# --block_range start end
|
||||||
|
start=0
|
||||||
|
end=7
|
||||||
|
|
||||||
|
# Toggle color blocks
|
||||||
|
# --color_blocks on/off
|
||||||
|
color_blocks="on"
|
||||||
|
|
||||||
|
# Color block width in spaces
|
||||||
|
# --block_width num
|
||||||
|
block_width=2
|
||||||
|
|
||||||
|
# Color block height in lines
|
||||||
|
# --block_height num
|
||||||
|
block_height=1
|
||||||
|
|
||||||
|
|
||||||
|
# }}}
|
||||||
|
|
||||||
|
# Progress Bars {{{
|
||||||
|
|
||||||
|
|
||||||
|
# Progress bar character
|
||||||
|
# --progress_char elapsed_char total_char
|
||||||
|
progress_char_elapsed="-"
|
||||||
|
progress_char_total="="
|
||||||
|
|
||||||
|
# Progress border
|
||||||
|
# --progress_border on/off
|
||||||
|
progress_border="on"
|
||||||
|
|
||||||
|
# Progress bar length in spaces
|
||||||
|
# Number of chars long to make the progress bars.
|
||||||
|
# --progress_length num
|
||||||
|
progress_length="15"
|
||||||
|
|
||||||
|
# Progress bar colors
|
||||||
|
# When set to distro, uses your distro's logo colors
|
||||||
|
# Takes: num, "distro"
|
||||||
|
# --progress_colors col col
|
||||||
|
progress_color_elapsed="distro"
|
||||||
|
progress_color_total="distro"
|
||||||
|
|
||||||
|
# Customize how the info is displayed.
|
||||||
|
# bar: Only the progress bar is displayed.
|
||||||
|
# infobar: The bar is displayed after the info.
|
||||||
|
# barinfo: The bar is displayed before the info.
|
||||||
|
# off: Only the info is displayed.
|
||||||
|
#
|
||||||
|
# --memory_display bar/infobar/barinfo/off
|
||||||
|
# --battery_display bar/infobar/barinfo/off
|
||||||
|
# --disk_display bar/infobar/barinfo/off
|
||||||
|
memory_display="off"
|
||||||
|
battery_display="off"
|
||||||
|
disk_display="off"
|
||||||
|
|
||||||
|
|
||||||
|
# }}}
|
||||||
|
|
||||||
|
# Image Options {{{
|
||||||
|
|
||||||
|
|
||||||
|
# Image Source
|
||||||
|
# --image wall, ascii, /path/to/img, /path/to/dir/, off
|
||||||
|
image="wall"
|
||||||
|
|
||||||
|
# Thumbnail directory
|
||||||
|
thumbnail_dir="$HOME/.cache/thumbnails/neofetch"
|
||||||
|
|
||||||
|
# W3m-img path
|
||||||
|
# Some systems have this in another location
|
||||||
|
w3m_img_path="/usr/lib/w3m/w3mimgdisplay"
|
||||||
|
|
||||||
|
# Image position
|
||||||
|
# Only works with the w3m backend
|
||||||
|
# --image_position left/right
|
||||||
|
image_position="left"
|
||||||
|
|
||||||
|
# Crop mode
|
||||||
|
# --crop_mode normal/fit/fill
|
||||||
|
crop_mode="normal"
|
||||||
|
|
||||||
|
# Crop offset
|
||||||
|
# Only affects normal mode.
|
||||||
|
# --crop_offset northwest/north/northeast/west/center
|
||||||
|
# east/southwest/south/southeast
|
||||||
|
crop_offset="center"
|
||||||
|
|
||||||
|
# Image size
|
||||||
|
# The image is half the terminal width by default.
|
||||||
|
# --size auto, 00px, 00%, none
|
||||||
|
image_size="auto"
|
||||||
|
|
||||||
|
# Right gap between image and text
|
||||||
|
# --gap num
|
||||||
|
gap=2
|
||||||
|
|
||||||
|
# Image offsets
|
||||||
|
# --xoffset px
|
||||||
|
# --yoffset px
|
||||||
|
yoffset=0
|
||||||
|
xoffset=0
|
||||||
|
|
||||||
|
|
||||||
|
# }}}
|
||||||
|
|
||||||
|
# Ascii Options {{{
|
||||||
|
|
||||||
|
|
||||||
|
# Default ascii image to use
|
||||||
|
# When this is set to distro it will use your
|
||||||
|
# distro's logo as the ascii.
|
||||||
|
# --ascii 'distro', path/to/ascii
|
||||||
|
ascii="distro"
|
||||||
|
|
||||||
|
# Ascii distro
|
||||||
|
# Which distro's ascii art to display.
|
||||||
|
# --ascii_distro 'auto', 'distro_name'
|
||||||
|
ascii_distro="auto"
|
||||||
|
|
||||||
|
# Ascii colors
|
||||||
|
# When this is set to distro it will use your
|
||||||
|
# ditro's colors to color the ascii.
|
||||||
|
# NOTE: You can also set this to a range of colors
|
||||||
|
# which will allow you to custom color distro logos
|
||||||
|
# --ascii_colors distro
|
||||||
|
# --ascii_colors 2 4 5 6
|
||||||
|
ascii_colors=(distro)
|
||||||
|
|
||||||
|
# Logo size
|
||||||
|
# Arch, Crux and Gentoo have a smaller logo
|
||||||
|
# variant. Changing the value below to small
|
||||||
|
# will make neofetch use the small logo.
|
||||||
|
# --ascii_logo_size small, normal
|
||||||
|
ascii_logo_size="normal"
|
||||||
|
|
||||||
|
# Bold ascii logo
|
||||||
|
# Whether or not to bold the ascii logo.
|
||||||
|
# --ascii_bold on/off
|
||||||
|
ascii_bold="off"
|
||||||
|
|
||||||
|
|
||||||
|
# }}}
|
||||||
|
|
||||||
|
# Scrot Options {{{
|
||||||
|
|
||||||
|
|
||||||
|
# Whether or not to always take a screenshot
|
||||||
|
# You can manually take a screenshot with "--scrot" or "-s"
|
||||||
|
scrot="off"
|
||||||
|
|
||||||
|
# Screenshot program to launch
|
||||||
|
# --scrot_cmd
|
||||||
|
scrot_cmd="scrot -c -d 3"
|
||||||
|
|
||||||
|
# Scrot dir
|
||||||
|
# Where to save the screenshots
|
||||||
|
# --scrot_dir /path/to/screenshot/folder
|
||||||
|
scrot_dir="$HOME/Pictures/"
|
||||||
|
|
||||||
|
# Scrot filename
|
||||||
|
# What to name the screenshots
|
||||||
|
# --scrot_name str
|
||||||
|
scrot_name="neofetch-$(date +%F-%I-%M-%S-${RANDOM}).png"
|
||||||
|
|
||||||
|
# Image upload host
|
||||||
|
# Where to upload the image.
|
||||||
|
# Possible values: imgur, teknik
|
||||||
|
image_host="imgur"
|
||||||
|
|
||||||
|
# Imgur api key
|
||||||
|
# This is an api key for neofetch, you can sign up for your own
|
||||||
|
# here: http://api.imgur.com/oauth2/addclient
|
||||||
|
imgur_client_id="0e8b44d15e9fc95"
|
||||||
|
|
||||||
|
|
||||||
|
# }}}
|
||||||
|
|
||||||
|
# Config Options {{{
|
||||||
|
|
||||||
|
|
||||||
|
# Enable/Disable config file
|
||||||
|
# --config off, none
|
||||||
|
config="on"
|
||||||
|
|
||||||
|
# Path to custom config file location
|
||||||
|
# --config path/to/config
|
||||||
|
config_file="${XDG_CONFIG_HOME:-${HOME}/.config}/neofetch/config"
|
||||||
|
|
||||||
|
|
||||||
|
# }}}
|
412
.config/polybar/config
Normal file
412
.config/polybar/config
Normal file
|
@ -0,0 +1,412 @@
|
||||||
|
; vim:ft=dosini
|
||||||
|
;=====================================================
|
||||||
|
;
|
||||||
|
; To learn more about how to configure Polybar
|
||||||
|
; go to https://github.com/jaagr/polybar
|
||||||
|
;
|
||||||
|
; The README contains alot of information
|
||||||
|
;
|
||||||
|
;=====================================================
|
||||||
|
|
||||||
|
[colors]
|
||||||
|
;background = ${xrdb:color0}
|
||||||
|
background = #00000000
|
||||||
|
background-alt = #444
|
||||||
|
foreground = ${xrdb:color7}
|
||||||
|
;foreground = #dfdfdf
|
||||||
|
foreground-alt = #555
|
||||||
|
primary = ${xrdb:color3}
|
||||||
|
;primary = ${xrdb:color3}
|
||||||
|
secondary = ${xrdb:color5}
|
||||||
|
;secondary = #e60053
|
||||||
|
alert = #bd2c40
|
||||||
|
col = #00f
|
||||||
|
;fg = ${xrdb:color7}
|
||||||
|
;bg = ${xrdb:color2}
|
||||||
|
|
||||||
|
[bar/example]
|
||||||
|
;monitor = ${env:MONITOR:HDMI-1}
|
||||||
|
;monitor = ${env:MONITOR}
|
||||||
|
monitor = ${env:MONITOR:LVDS-1}
|
||||||
|
width = 100%
|
||||||
|
height = 24
|
||||||
|
;offset-x = 1%
|
||||||
|
;offset-y = 1%
|
||||||
|
;radius = 6.0
|
||||||
|
fixed-center = false
|
||||||
|
|
||||||
|
background = ${colors.background}
|
||||||
|
foreground = ${colors.foreground}
|
||||||
|
|
||||||
|
line-size = 3
|
||||||
|
line-color = {$xrdb:color1}
|
||||||
|
|
||||||
|
border-size = 0
|
||||||
|
border-color = #00000000
|
||||||
|
|
||||||
|
padding-left = 0
|
||||||
|
padding-right = 0
|
||||||
|
|
||||||
|
module-margin-left = 1
|
||||||
|
module-margin-right = 2
|
||||||
|
|
||||||
|
font-0 = mono:pixelsize=9;1
|
||||||
|
font-1 = unifont:fontformat=truetype:size=8:antialias=false;0
|
||||||
|
font-2 = Wuncon Siji:pixelsize=9;1
|
||||||
|
|
||||||
|
#modules-left = i3
|
||||||
|
modules-left = i3 mpd
|
||||||
|
#modules-center = mpd
|
||||||
|
#modules-right = volume wlan eth battery temperature date
|
||||||
|
modules-right = home filesystem volume wlan eth battery temperature date
|
||||||
|
|
||||||
|
tray-position = right
|
||||||
|
tray-padding = 0
|
||||||
|
;tray-transparent = true
|
||||||
|
;tray-background = #0063ff
|
||||||
|
|
||||||
|
;wm-restack = bspwm
|
||||||
|
;wm-restack = i3
|
||||||
|
|
||||||
|
;override-redirect = true
|
||||||
|
|
||||||
|
;scroll-up = bspwm-desknext
|
||||||
|
;scroll-down = bspwm-deskprev
|
||||||
|
|
||||||
|
scroll-up = i3wm-wsnext
|
||||||
|
scroll-down = i3wm-wsprev
|
||||||
|
|
||||||
|
[module/xwindow]
|
||||||
|
type = internal/xwindow
|
||||||
|
label = %title:0:30:...%
|
||||||
|
|
||||||
|
[module/xkeyboard]
|
||||||
|
type = internal/xkeyboard
|
||||||
|
blacklist-0 = num lock
|
||||||
|
|
||||||
|
format-prefix = " "
|
||||||
|
format-prefix-foreground = ${colors.foreground-alt}
|
||||||
|
format-prefix-underline = ${colors.secondary}
|
||||||
|
|
||||||
|
label-layout = %layout%
|
||||||
|
label-layout-underline = ${colors.secondary}
|
||||||
|
|
||||||
|
label-indicator-padding = 2
|
||||||
|
label-indicator-margin = 1
|
||||||
|
label-indicator-background = ${colors.secondary}
|
||||||
|
label-indicator-underline = ${colors.secondary}
|
||||||
|
|
||||||
|
[module/filesystem]
|
||||||
|
type = internal/fs
|
||||||
|
interval = 25
|
||||||
|
|
||||||
|
mount-0 = /
|
||||||
|
|
||||||
|
label-mounted = %{F#0a81f5}%mountpoint%%{F-}: %percentage_used%%
|
||||||
|
label-unmounted = %mountpoint% not mounted
|
||||||
|
label-unmounted-foreground = ${colors.foreground-alt}
|
||||||
|
|
||||||
|
[module/home]
|
||||||
|
type = internal/fs
|
||||||
|
interval = 25
|
||||||
|
|
||||||
|
mount-0 = /home
|
||||||
|
|
||||||
|
label-mounted = %{F#0a81f5}~%{F-}: %percentage_used%%
|
||||||
|
label-unmounted = %mountpoint% not mounted
|
||||||
|
label-unmounted-foreground = ${colors.foreground-alt}
|
||||||
|
[module/bspwm]
|
||||||
|
type = internal/bspwm
|
||||||
|
|
||||||
|
label-focused = %index%
|
||||||
|
label-focused-background = ${colors.background-alt}
|
||||||
|
label-focused-underline= ${colors.primary}
|
||||||
|
label-focused-padding = 2
|
||||||
|
|
||||||
|
label-occupied = %index%
|
||||||
|
label-occupied-padding = 2
|
||||||
|
|
||||||
|
label-urgent = %index%!
|
||||||
|
label-urgent-background = ${colors.alert}
|
||||||
|
label-urgent-padding = 2
|
||||||
|
|
||||||
|
label-empty = %index%
|
||||||
|
label-empty-foreground = ${colors.foreground-alt}
|
||||||
|
label-empty-padding = 2
|
||||||
|
|
||||||
|
[module/i3]
|
||||||
|
type = internal/i3
|
||||||
|
format = <label-state> <label-mode>
|
||||||
|
index-sort = true
|
||||||
|
wrapping-scroll = false
|
||||||
|
|
||||||
|
; Only show workspaces on the same output as the bar
|
||||||
|
;pin-workspaces = true
|
||||||
|
|
||||||
|
label-mode-padding = 2
|
||||||
|
label-mode-foreground = #000
|
||||||
|
label-mode-background = ${colors.primary}
|
||||||
|
|
||||||
|
; focused = Active workspace on focused monitor
|
||||||
|
label-focused = %index%
|
||||||
|
label-focused-background = ${xrdb:color0}
|
||||||
|
;label-focused-background = ${module/bspwm.label-focused-background}
|
||||||
|
label-focused-underline = ${module/bspwm.label-focused-underline}
|
||||||
|
label-focused-padding = ${module/bspwm.label-focused-padding}
|
||||||
|
|
||||||
|
; unfocused = Inactive workspace on any monitor
|
||||||
|
label-unfocused = %index%
|
||||||
|
label-unfocused-padding = ${module/bspwm.label-occupied-padding}
|
||||||
|
|
||||||
|
; visible = Active workspace on unfocused monitor
|
||||||
|
label-visible = %index%
|
||||||
|
label-visible-background = ${self.label-focused-background}
|
||||||
|
label-visible-underline = ${self.label-focused-underline}
|
||||||
|
label-visible-padding = ${self.label-focused-padding}
|
||||||
|
|
||||||
|
; urgent = Workspace with urgency hint set
|
||||||
|
label-urgent = %index%
|
||||||
|
label-urgent-background = ${module/bspwm.label-urgent-background}
|
||||||
|
label-urgent-padding = ${module/bspwm.label-urgent-padding}
|
||||||
|
|
||||||
|
[module/mpd]
|
||||||
|
type = internal/mpd
|
||||||
|
format-online = <label-song> <label-time>
|
||||||
|
#<icon-prev> <toggle> <icon-next>
|
||||||
|
#<toggle>
|
||||||
|
|
||||||
|
icon-prev =
|
||||||
|
icon-stop =
|
||||||
|
icon-play =
|
||||||
|
icon-pause =
|
||||||
|
icon-next =
|
||||||
|
#icon-prev = <-
|
||||||
|
#icon-stop = X
|
||||||
|
#icon-play-prefix = #f00
|
||||||
|
#icon-play = (Paused)
|
||||||
|
#icon-pause =
|
||||||
|
#icon-next = ->
|
||||||
|
|
||||||
|
;bar-progress-width = 45
|
||||||
|
;bar-progress-indicator = |
|
||||||
|
;bar-progress-fill = -
|
||||||
|
;bar-progress-empty = -
|
||||||
|
|
||||||
|
label-song = %artist% - %title%
|
||||||
|
label-song-maxlen = 70
|
||||||
|
label-song-ellipsis = true
|
||||||
|
|
||||||
|
[module/xbacklight]
|
||||||
|
type = internal/xbacklight
|
||||||
|
|
||||||
|
format = <label> <bar>
|
||||||
|
label = BL
|
||||||
|
|
||||||
|
bar-width = 10
|
||||||
|
bar-indicator = |
|
||||||
|
bar-indicator-foreground = #ff
|
||||||
|
bar-indicator-font = 2
|
||||||
|
bar-fill = ─
|
||||||
|
bar-fill-font = 2
|
||||||
|
bar-fill-foreground = #9f78e1
|
||||||
|
bar-empty = ─
|
||||||
|
bar-empty-font = 2
|
||||||
|
bar-empty-foreground = ${colors.foreground-alt}
|
||||||
|
|
||||||
|
[module/backlight-acpi]
|
||||||
|
inherit = module/xbacklight
|
||||||
|
type = internal/backlight
|
||||||
|
card = intel_backlight
|
||||||
|
|
||||||
|
[module/cpu]
|
||||||
|
type = internal/cpu
|
||||||
|
interval = 2
|
||||||
|
format-prefix = " "
|
||||||
|
format-prefix-foreground = ${colors.foreground-alt}
|
||||||
|
format-underline = ${xrdb:color1}
|
||||||
|
label = %percentage%%
|
||||||
|
|
||||||
|
[module/memory]
|
||||||
|
type = internal/memory
|
||||||
|
interval = 2
|
||||||
|
format-prefix = " "
|
||||||
|
format-prefix-foreground = ${colors.foreground-alt}
|
||||||
|
format-underline = ${xrdb:color6}
|
||||||
|
label = %percentage_used%%
|
||||||
|
|
||||||
|
[module/wlan]
|
||||||
|
type = internal/network
|
||||||
|
interface = wlp3s0
|
||||||
|
interval = 3.0
|
||||||
|
|
||||||
|
format-connected = <ramp-signal> <label-connected>
|
||||||
|
format-connected-underline = ${xrdb:color5}
|
||||||
|
;format-connected-underline = #9f78e1
|
||||||
|
label-connected = %essid%
|
||||||
|
|
||||||
|
;format-disconnected =
|
||||||
|
format-disconnected = <label-disconnected>
|
||||||
|
format-disconnected-underline = ${self.format-connected-underline}
|
||||||
|
;label-disconnected = %ifname% disconnected
|
||||||
|
label-disconnected = no wifi
|
||||||
|
label-disconnected-foreground = ${colors.foreground-alt}
|
||||||
|
|
||||||
|
ramp-signal-0 =
|
||||||
|
ramp-signal-1 =
|
||||||
|
ramp-signal-2 =
|
||||||
|
ramp-signal-3 =
|
||||||
|
ramp-signal-4 =
|
||||||
|
ramp-signal-foreground = ${colors.foreground-alt}
|
||||||
|
|
||||||
|
[module/eth]
|
||||||
|
type = internal/network
|
||||||
|
interface = enp0s25
|
||||||
|
interval = 3.0
|
||||||
|
|
||||||
|
format-connected-underline = ${xrdb:color2}
|
||||||
|
;format-connected-underline = ${xrdb:color10}
|
||||||
|
format-connected-prefix = " "
|
||||||
|
format-connected-prefix-foreground = ${colors.foreground-alt}
|
||||||
|
label-connected = %local_ip%
|
||||||
|
|
||||||
|
;format-disconnected =
|
||||||
|
format-disconnected = <label-disconnected>
|
||||||
|
format-disconnected-underline = ${self.format-connected-underline}
|
||||||
|
;label-disconnected = %ifname% disconnected
|
||||||
|
label-disconnected = no eth
|
||||||
|
label-disconnected-foreground = ${colors.foreground-alt}
|
||||||
|
|
||||||
|
[module/date]
|
||||||
|
type = internal/date
|
||||||
|
interval = 5
|
||||||
|
|
||||||
|
date = " %a, %b %d, %Y"
|
||||||
|
;date-alt = " %a, %b %d, %Y at %I:%M%p"
|
||||||
|
;date-alt = " %Y-%m-%d"
|
||||||
|
|
||||||
|
time = " at %I:%M%p"
|
||||||
|
;time-alt = %H:%M:%S
|
||||||
|
;time-alt = %H:%M:%S
|
||||||
|
|
||||||
|
format-prefix =
|
||||||
|
format-prefix-foreground = ${colors.foreground-alt}
|
||||||
|
format-underline = ${xrdb:color12}
|
||||||
|
;format-underline = #0a6cf5
|
||||||
|
|
||||||
|
label = %date% %time%
|
||||||
|
|
||||||
|
[module/volume]
|
||||||
|
type = internal/volume
|
||||||
|
|
||||||
|
format-volume = <label-volume> <bar-volume>
|
||||||
|
label-volume = VOL
|
||||||
|
label-volume-foreground = ${root.foreground}
|
||||||
|
|
||||||
|
format-muted-prefix = " "
|
||||||
|
format-muted-foreground = ${colors.foreground-alt}
|
||||||
|
label-muted = sound muted
|
||||||
|
|
||||||
|
bar-volume-width = 10
|
||||||
|
bar-volume-foreground-0 = ${xrdb:color10}
|
||||||
|
bar-volume-foreground-1 = ${xrdb:color10}
|
||||||
|
bar-volume-foreground-2 = ${xrdb:color10}
|
||||||
|
bar-volume-foreground-3 = ${xrdb:color10}
|
||||||
|
bar-volume-foreground-4 = ${xrdb:color10}
|
||||||
|
bar-volume-foreground-5 = ${xrdb:color11}
|
||||||
|
bar-volume-foreground-6 = ${xrdb:color1}
|
||||||
|
bar-volume-gradient = false
|
||||||
|
bar-volume-indicator = |
|
||||||
|
bar-volume-indicator-font = 2
|
||||||
|
bar-volume-fill = =
|
||||||
|
bar-volume-fill-font = 2
|
||||||
|
bar-volume-empty = =
|
||||||
|
bar-volume-empty-font = 2
|
||||||
|
bar-volume-empty-foreground = ${colors.foreground-alt}
|
||||||
|
|
||||||
|
[module/battery]
|
||||||
|
type = internal/battery
|
||||||
|
battery = BAT0
|
||||||
|
adapter = ADP1
|
||||||
|
full-at = 98
|
||||||
|
|
||||||
|
;format-charging = Charging... <label-charging>
|
||||||
|
format-charging = <animation-charging> <label-charging>
|
||||||
|
format-charging-underline = ${xrdb:color3}
|
||||||
|
|
||||||
|
;format-discharging = <label-discharging>
|
||||||
|
format-discharging = <ramp-capacity> <label-discharging>
|
||||||
|
format-discharging-underline = ${self.format-charging-underline}
|
||||||
|
|
||||||
|
format-full-prefix = " "
|
||||||
|
format-full-prefix-foreground = ${colors.foreground-alt}
|
||||||
|
format-full-underline = ${self.format-charging-underline}
|
||||||
|
|
||||||
|
ramp-capacity-0 =
|
||||||
|
ramp-capacity-1 =
|
||||||
|
ramp-capacity-2 =
|
||||||
|
ramp-capacity-foreground = ${colors.foreground-alt}
|
||||||
|
|
||||||
|
animation-charging-0 =
|
||||||
|
animation-charging-1 =
|
||||||
|
animation-charging-2 =
|
||||||
|
animation-charging-foreground = ${colors.foreground-alt}
|
||||||
|
animation-charging-framerate = 750
|
||||||
|
|
||||||
|
[module/temperature]
|
||||||
|
type = internal/temperature
|
||||||
|
thermal-zone = 0
|
||||||
|
warn-temperature = 60
|
||||||
|
|
||||||
|
format = <ramp> <label>
|
||||||
|
format-underline = ${xrdb:color1}
|
||||||
|
;format-underline = #f50a4d
|
||||||
|
format-warn = <ramp> <label-warn>
|
||||||
|
format-warn-underline = ${self.format-underline}
|
||||||
|
|
||||||
|
label = %temperature%
|
||||||
|
label-warn = %temperature%
|
||||||
|
label-warn-foreground = ${colors.secondary}
|
||||||
|
|
||||||
|
ramp-0 =
|
||||||
|
ramp-1 =
|
||||||
|
ramp-2 =
|
||||||
|
ramp-foreground = ${colors.foreground-alt}
|
||||||
|
|
||||||
|
[module/powermenu]
|
||||||
|
type = custom/menu
|
||||||
|
|
||||||
|
format-spacing = 1
|
||||||
|
|
||||||
|
label-open =
|
||||||
|
label-open-foreground = ${colors.secondary}
|
||||||
|
label-close = cancel
|
||||||
|
label-close-foreground = ${colors.secondary}
|
||||||
|
label-separator = |
|
||||||
|
label-separator-foreground = ${colors.foreground-alt}
|
||||||
|
|
||||||
|
menu-0-0 = reboot
|
||||||
|
menu-0-0-exec = menu-open-1
|
||||||
|
menu-0-1 = power off
|
||||||
|
menu-0-1-exec = menu-open-2
|
||||||
|
|
||||||
|
menu-1-0 = cancel
|
||||||
|
menu-1-0-exec = menu-open-0
|
||||||
|
menu-1-1 = reboot
|
||||||
|
menu-1-1-exec = sudo reboot
|
||||||
|
|
||||||
|
menu-2-0 = power off
|
||||||
|
menu-2-0-exec = sudo poweroff
|
||||||
|
menu-2-1 = cancel
|
||||||
|
menu-2-1-exec = menu-open-0
|
||||||
|
|
||||||
|
[settings]
|
||||||
|
screenchange-reload = true
|
||||||
|
;compositing-background = xor
|
||||||
|
;compositing-background = screen
|
||||||
|
;compositing-foreground = source
|
||||||
|
;compositing-border = over
|
||||||
|
|
||||||
|
[global/wm]
|
||||||
|
margin-top = 5
|
||||||
|
margin-bottom = 5
|
||||||
|
|
16
.config/polybar/launch.sh
Executable file
16
.config/polybar/launch.sh
Executable file
|
@ -0,0 +1,16 @@
|
||||||
|
#!/bin/bash
|
||||||
|
#!/usr/bin/env sh
|
||||||
|
|
||||||
|
# Terminate already running bar instances
|
||||||
|
killall -q polybar
|
||||||
|
|
||||||
|
# Wait until the processes have been shut down
|
||||||
|
while pgrep -x polybar >/dev/null; do sleep 1; done
|
||||||
|
|
||||||
|
# Launch bar1 and bar2
|
||||||
|
#polybar example &
|
||||||
|
|
||||||
|
for i in $(polybar -m | awk -F: '{print $1}'); do MONITOR=$i polybar example -c ~/.config/polybar/config & done
|
||||||
|
feh --bg-scale ~/.config/wall.png
|
||||||
|
|
||||||
|
echo "Bars launched..."
|
1585
.config/qutebrowser/config.py
Normal file
1585
.config/qutebrowser/config.py
Normal file
File diff suppressed because it is too large
Load diff
216
.config/ranger/commands.py
Executable file
216
.config/ranger/commands.py
Executable file
|
@ -0,0 +1,216 @@
|
||||||
|
# This is a sample commands.py. You can add your own commands here.
|
||||||
|
#
|
||||||
|
# Please refer to commands_full.py for all the default commands and a complete
|
||||||
|
# documentation. Do NOT add them all here, or you may end up with defunct
|
||||||
|
# commands when upgrading ranger.
|
||||||
|
|
||||||
|
# You always need to import ranger.api.commands here to get the Command class:
|
||||||
|
from ranger.api.commands import *
|
||||||
|
|
||||||
|
# A simple command for demonstration purposes follows.
|
||||||
|
#------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
# You can import any python module as needed.
|
||||||
|
import os
|
||||||
|
|
||||||
|
# Any class that is a subclass of "Command" will be integrated into ranger as a
|
||||||
|
# command. Try typing ":my_edit<ENTER>" in ranger!
|
||||||
|
class my_edit(Command):
|
||||||
|
# The so-called doc-string of the class will be visible in the built-in
|
||||||
|
# help that is accessible by typing "?c" inside ranger.
|
||||||
|
""":my_edit <filename>
|
||||||
|
|
||||||
|
A sample command for demonstration purposes that opens a file in an editor.
|
||||||
|
"""
|
||||||
|
|
||||||
|
# The execute method is called when you run this command in ranger.
|
||||||
|
def execute(self):
|
||||||
|
# self.arg(1) is the first (space-separated) argument to the function.
|
||||||
|
# This way you can write ":my_edit somefilename<ENTER>".
|
||||||
|
if self.arg(1):
|
||||||
|
# self.rest(1) contains self.arg(1) and everything that follows
|
||||||
|
target_filename = self.rest(1)
|
||||||
|
else:
|
||||||
|
# self.fm is a ranger.core.filemanager.FileManager object and gives
|
||||||
|
# you access to internals of ranger.
|
||||||
|
# self.fm.thisfile is a ranger.container.file.File object and is a
|
||||||
|
# reference to the currently selected file.
|
||||||
|
target_filename = self.fm.thisfile.path
|
||||||
|
|
||||||
|
# This is a generic function to print text in ranger.
|
||||||
|
self.fm.notify("Let's edit the file " + target_filename + "!")
|
||||||
|
|
||||||
|
# Using bad=True in fm.notify allows you to print error messages:
|
||||||
|
if not os.path.exists(target_filename):
|
||||||
|
self.fm.notify("The given file does not exist!", bad=True)
|
||||||
|
return
|
||||||
|
|
||||||
|
# This executes a function from ranger.core.acitons, a module with a
|
||||||
|
# variety of subroutines that can help you construct commands.
|
||||||
|
# Check out the source, or run "pydoc ranger.core.actions" for a list.
|
||||||
|
self.fm.edit_file(target_filename)
|
||||||
|
|
||||||
|
# The tab method is called when you press tab, and should return a list of
|
||||||
|
# suggestions that the user will tab through.
|
||||||
|
def tab(self):
|
||||||
|
# This is a generic tab-completion function that iterates through the
|
||||||
|
# content of the current directory.
|
||||||
|
return self._tab_directory_content()
|
||||||
|
|
||||||
|
|
||||||
|
# https://github.com/ranger/ranger/wiki/Integrating-File-Search-with-fzf
|
||||||
|
# Now, simply bind this function to a key, by adding this to your ~/.config/ranger/rc.conf: map <C-f> fzf_select
|
||||||
|
class fzf_select(Command):
|
||||||
|
"""
|
||||||
|
:fzf_select
|
||||||
|
|
||||||
|
Find a file using fzf.
|
||||||
|
|
||||||
|
With a prefix argument select only directories.
|
||||||
|
|
||||||
|
See: https://github.com/junegunn/fzf
|
||||||
|
"""
|
||||||
|
def execute(self):
|
||||||
|
import subprocess
|
||||||
|
if self.quantifier:
|
||||||
|
# match only directories
|
||||||
|
command="find -L . \( -path '*/\.*' -o -fstype 'dev' -o -fstype 'proc' \) -prune \
|
||||||
|
-o -type d -print 2> /dev/null | sed 1d | cut -b3- | fzf +m"
|
||||||
|
else:
|
||||||
|
# match files and directories
|
||||||
|
command="find -L . \( -path '*/\.*' -o -fstype 'dev' -o -fstype 'proc' \) -prune \
|
||||||
|
-o -print 2> /dev/null | sed 1d | cut -b3- | fzf +m"
|
||||||
|
fzf = self.fm.execute_command(command, stdout=subprocess.PIPE)
|
||||||
|
stdout, stderr = fzf.communicate()
|
||||||
|
if fzf.returncode == 0:
|
||||||
|
fzf_file = os.path.abspath(stdout.decode('utf-8').rstrip('\n'))
|
||||||
|
if os.path.isdir(fzf_file):
|
||||||
|
self.fm.cd(fzf_file)
|
||||||
|
else:
|
||||||
|
self.fm.select_file(fzf_file)
|
||||||
|
# fzf_locate
|
||||||
|
class fzf_locate(Command):
|
||||||
|
"""
|
||||||
|
:fzf_locate
|
||||||
|
|
||||||
|
Find a file using fzf.
|
||||||
|
|
||||||
|
With a prefix argument select only directories.
|
||||||
|
|
||||||
|
See: https://github.com/junegunn/fzf
|
||||||
|
"""
|
||||||
|
def execute(self):
|
||||||
|
import subprocess
|
||||||
|
if self.quantifier:
|
||||||
|
command="locate home media | fzf -e -i"
|
||||||
|
else:
|
||||||
|
command="locate home media | fzf -e -i"
|
||||||
|
fzf = self.fm.execute_command(command, stdout=subprocess.PIPE)
|
||||||
|
stdout, stderr = fzf.communicate()
|
||||||
|
if fzf.returncode == 0:
|
||||||
|
fzf_file = os.path.abspath(stdout.decode('utf-8').rstrip('\n'))
|
||||||
|
if os.path.isdir(fzf_file):
|
||||||
|
self.fm.cd(fzf_file)
|
||||||
|
else:
|
||||||
|
self.fm.select_file(fzf_file)
|
||||||
|
|
||||||
|
class fzf_bring(Command):
|
||||||
|
"""
|
||||||
|
:fzf_bring
|
||||||
|
|
||||||
|
Find a file using fzf and bring it to the current directory.
|
||||||
|
|
||||||
|
See: https://github.com/junegunn/fzf
|
||||||
|
"""
|
||||||
|
def execute(self):
|
||||||
|
import subprocess
|
||||||
|
if self.quantifier:
|
||||||
|
# match only directories
|
||||||
|
command="find -L . \( -path '*/\.*' -o -fstype 'dev' -o -fstype 'proc' \) -prune \
|
||||||
|
-o -type d -print 2> /dev/null | sed 1d | cut -b3- | fzf +m"
|
||||||
|
else:
|
||||||
|
# match files and directories
|
||||||
|
command="find -L . \( -path '*/\.*' -o -fstype 'dev' -o -fstype 'proc' \) -prune \
|
||||||
|
-o -print 2> /dev/null | sed 1d | cut -b3- | fzf +m"
|
||||||
|
fzf = self.fm.execute_command(command, stdout=subprocess.PIPE)
|
||||||
|
stdout, stderr = fzf.communicate()
|
||||||
|
if fzf.returncode == 0:
|
||||||
|
fzf_file = os.path.abspath(stdout.decode('utf-8').rstrip('\n'))
|
||||||
|
if os.path.isdir(fzf_file):
|
||||||
|
self.fm.cd(fzf_file)
|
||||||
|
else:
|
||||||
|
self.fm.select_file(fzf_file)
|
||||||
|
|
||||||
|
|
||||||
|
import os
|
||||||
|
from ranger.core.loader import CommandLoader
|
||||||
|
|
||||||
|
class compress(Command):
|
||||||
|
def execute(self):
|
||||||
|
""" Compress marked files to current directory """
|
||||||
|
cwd = self.fm.thisdir
|
||||||
|
marked_files = cwd.get_selection()
|
||||||
|
|
||||||
|
if not marked_files:
|
||||||
|
return
|
||||||
|
|
||||||
|
def refresh(_):
|
||||||
|
cwd = self.fm.get_directory(original_path)
|
||||||
|
cwd.load_content()
|
||||||
|
|
||||||
|
original_path = cwd.path
|
||||||
|
parts = self.line.split()
|
||||||
|
au_flags = parts[1:]
|
||||||
|
|
||||||
|
descr = "compressing files in: " + os.path.basename(parts[1])
|
||||||
|
obj = CommandLoader(args=['apack'] + au_flags + \
|
||||||
|
[os.path.relpath(f.path, cwd.path) for f in marked_files], descr=descr)
|
||||||
|
|
||||||
|
obj.signal_bind('after', refresh)
|
||||||
|
self.fm.loader.add(obj)
|
||||||
|
|
||||||
|
def tab(self):
|
||||||
|
""" Complete with current folder name """
|
||||||
|
|
||||||
|
extension = ['.zip', '.tar.gz', '.rar', '.7z']
|
||||||
|
return ['compress ' + os.path.basename(self.fm.thisdir.path) + ext for ext in extension]
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
import os
|
||||||
|
from ranger.core.loader import CommandLoader
|
||||||
|
|
||||||
|
class extracthere(Command):
|
||||||
|
def execute(self):
|
||||||
|
""" Extract copied files to current directory """
|
||||||
|
copied_files = tuple(self.fm.copy_buffer)
|
||||||
|
|
||||||
|
if not copied_files:
|
||||||
|
return
|
||||||
|
|
||||||
|
def refresh(_):
|
||||||
|
cwd = self.fm.get_directory(original_path)
|
||||||
|
cwd.load_content()
|
||||||
|
|
||||||
|
one_file = copied_files[0]
|
||||||
|
cwd = self.fm.thisdir
|
||||||
|
original_path = cwd.path
|
||||||
|
au_flags = ['-X', cwd.path]
|
||||||
|
au_flags += self.line.split()[1:]
|
||||||
|
au_flags += ['-e']
|
||||||
|
|
||||||
|
self.fm.copy_buffer.clear()
|
||||||
|
self.fm.cut_buffer = False
|
||||||
|
if len(copied_files) == 1:
|
||||||
|
descr = "extracting: " + os.path.basename(one_file.path)
|
||||||
|
else:
|
||||||
|
descr = "extracting files from: " + os.path.basename(one_file.dirname)
|
||||||
|
obj = CommandLoader(args=['aunpack'] + au_flags \
|
||||||
|
+ [f.path for f in copied_files], descr=descr)
|
||||||
|
|
||||||
|
obj.signal_bind('after', refresh)
|
||||||
|
self.fm.loader.add(obj)
|
||||||
|
|
||||||
|
|
||||||
|
|
1508
.config/ranger/commands_full.py
Executable file
1508
.config/ranger/commands_full.py
Executable file
File diff suppressed because it is too large
Load diff
83
.config/ranger/luke_ranger_readme.md
Normal file
83
.config/ranger/luke_ranger_readme.md
Normal file
|
@ -0,0 +1,83 @@
|
||||||
|
# Luke's ranger setup
|
||||||
|
|
||||||
|
## Basic Ranger shortcuts
|
||||||
|
|
||||||
|
These are the basic key binds in ranger, even outside of my configs. Note that they are mostly vim-based.
|
||||||
|
|
||||||
|
+ h/j/k/l -- Move left/down/up/right (where left moves up in the directory structure, right moves into a folder)
|
||||||
|
+ Space -- select/highlight file
|
||||||
|
+ dd -- cut selected files
|
||||||
|
+ yy -- copy/yank selected files
|
||||||
|
+ pp -- paste/move cut/copied files
|
||||||
|
+ / -- search, when (n/N) next/previos result
|
||||||
|
+ zh or CTRL-h -- show hidden files
|
||||||
|
+ Renaming files:
|
||||||
|
+ cw -- rename file from scratch
|
||||||
|
+ A -- rename file adding to the end
|
||||||
|
+ aa -- rename file appending before the extension
|
||||||
|
+ I -- rename file adding at the beginning
|
||||||
|
|
||||||
|
## Shortcuts
|
||||||
|
|
||||||
|
I've added many folder-specific shortcuts; refer to rc.conf for the specifics, but here's the idea. There are for "verbs:"
|
||||||
|
|
||||||
|
+ g -- "go or cd"
|
||||||
|
+ t -- "new tab"
|
||||||
|
+ m -- "move file"
|
||||||
|
+ Y -- "yank or copy file"
|
||||||
|
|
||||||
|
These "verbs" take "nouns" or "arguments," like these:
|
||||||
|
|
||||||
|
+ d -- "~/Documents"
|
||||||
|
+ D -- "~/Downloads"
|
||||||
|
+ cf -- "~/.config"
|
||||||
|
+ And many others, including those you add!
|
||||||
|
|
||||||
|
Press any "verb" followed by any "argument" to perform a folder operation. "gd" will cd to ~/Documents, for example. "mD" will move the selected file(s) to ~/Downloads. "tcf" will create a new tab in ~/.config, etc. etc.
|
||||||
|
|
||||||
|
## Many little additions!
|
||||||
|
|
||||||
|
+ Basic additions:
|
||||||
|
+ V -- Make a new file and edit it in vim
|
||||||
|
+ cW -- rename *all* selected files, editing in your text editor
|
||||||
|
+ mkd -- Make a directory/folder
|
||||||
|
+ sc -- Makes a link/shortcut (ln -sT)
|
||||||
|
+ D -- delete selected file
|
||||||
|
+ X -- Extract a zip/rar/tar.gz, whatever. Runs a script that picks the right command for the right archive.
|
||||||
|
+ Z -- zips a folder up into a .tar.gz archive.
|
||||||
|
+ CTRL-f -- Fuzzy find a file
|
||||||
|
+ CTRL-l -- Fuzzy locate a file
|
||||||
|
+ Document manipulation:
|
||||||
|
+ p1s -- print this file on the default printer, one-sided (lpr)
|
||||||
|
+ p2s -- print this file on the default printer, double-sided (lpr)
|
||||||
|
+ MP -- convert to a .pdf with pandoc (I use this to convert markdown, etc.)
|
||||||
|
+ MX -- compile selected document in XeLaTeX
|
||||||
|
+ ML -- compile selected document in LaTeX
|
||||||
|
+ TC -- clear all non-visible TeX build files in this directory
|
||||||
|
+ Txa -- copy article template to new file
|
||||||
|
+ Txs -- copy slideshow/beamer template to new file
|
||||||
|
+ Txh -- copy handout template to new file
|
||||||
|
+ Image commands:
|
||||||
|
+ bg -- (for i3 users) makes an image your background (assuming i3 is looking at ~/.config/wall.png for your background)
|
||||||
|
+ bw -- runs Pywal on the selected image, making it your background and generating a color scheme based off of it.
|
||||||
|
+ C -- rotates an image (requires imagemagick)
|
||||||
|
+ F -- flips an image (requires imagemagick)
|
||||||
|
+ TR -- add transparency to image file
|
||||||
|
+ mpd/mpc shortcuts
|
||||||
|
+ MS -- Start mpd
|
||||||
|
+ MK -- kill mpd
|
||||||
|
+ MN -- Start playing selected song/folder now
|
||||||
|
+ Ma -- Enqueue selected song/folder
|
||||||
|
+ Mp -- Pause
|
||||||
|
+ Mn -- Next track
|
||||||
|
+ Mb -- Previous track
|
||||||
|
+ Mo -- Restart track
|
||||||
|
+ Audio tagging with eye3D:
|
||||||
|
+ Ta -- change artist name
|
||||||
|
+ TA -- change album name
|
||||||
|
+ Tb -- change album artist
|
||||||
|
+ Tt -- change title
|
||||||
|
+ Tn -- change track number
|
||||||
|
+ Downloading:
|
||||||
|
+ ytv -- Download online video (paste in url) (requires youtube-dl)
|
||||||
|
+ yta -- Download audio of online video (paste in url) (requires youtube-dl)
|
520
.config/ranger/rc.conf
Normal file
520
.config/ranger/rc.conf
Normal file
|
@ -0,0 +1,520 @@
|
||||||
|
###SETTINGS###
|
||||||
|
|
||||||
|
set column_ratios 1,3,4
|
||||||
|
#set hidden_filter ^\.|\.(?:pyc|pyo|bak|swp)$|^lost\+found$|^__(py)?cache__$
|
||||||
|
set hidden_filter ^\.|\.(?:pyc|vrb|pyo|lof|bak|swp|aux|log|nav|out|snm|toc|bcf|run\.xml|synctex\.gz|blg|bbl)$|^lost\+found$|^__(py)?cache__$
|
||||||
|
set show_hidden false
|
||||||
|
set confirm_on_delete multiple
|
||||||
|
set preview_script ~/.config/ranger/scope.sh
|
||||||
|
set use_preview_script true
|
||||||
|
set automatically_count_files true
|
||||||
|
set open_all_images true
|
||||||
|
set vcs_aware false
|
||||||
|
set vcs_backend_git enabled
|
||||||
|
set vcs_backend_hg disabled
|
||||||
|
set vcs_backend_bzr disabled
|
||||||
|
set preview_images true
|
||||||
|
set preview_images_method w3m
|
||||||
|
set unicode_ellipsis false
|
||||||
|
set show_hidden_bookmarks false
|
||||||
|
set colorscheme default
|
||||||
|
set preview_files true
|
||||||
|
set preview_directories true
|
||||||
|
set collapse_preview true
|
||||||
|
set save_console_history false
|
||||||
|
set status_bar_on_top false
|
||||||
|
set draw_progress_bar_in_status_bar true
|
||||||
|
set draw_borders false
|
||||||
|
set dirname_in_tabs false
|
||||||
|
set mouse_enabled true
|
||||||
|
set display_size_in_main_column true
|
||||||
|
set display_size_in_status_bar true
|
||||||
|
set display_tags_in_all_columns true
|
||||||
|
set update_title false
|
||||||
|
set update_tmux_title true
|
||||||
|
set shorten_title 3
|
||||||
|
set tilde_in_titlebar true
|
||||||
|
set max_history_size 20
|
||||||
|
set max_console_history_size 50
|
||||||
|
set scroll_offset 8
|
||||||
|
set flushinput true
|
||||||
|
set padding_right true
|
||||||
|
set autosave_bookmarks false
|
||||||
|
set autoupdate_cumulative_size false
|
||||||
|
set show_cursor false
|
||||||
|
set sort natural
|
||||||
|
set sort_reverse false
|
||||||
|
set sort_case_insensitive true
|
||||||
|
set sort_directories_first true
|
||||||
|
set sort_unicode false
|
||||||
|
set xterm_alt_key false
|
||||||
|
set cd_bookmarks false
|
||||||
|
set preview_max_size 0
|
||||||
|
set show_selection_in_titlebar true
|
||||||
|
set idle_delay 2000
|
||||||
|
set metadata_deep_search false
|
||||||
|
|
||||||
|
|
||||||
|
###ALIASES###
|
||||||
|
alias e edit
|
||||||
|
alias q quit
|
||||||
|
alias q! quitall
|
||||||
|
alias qa quitall
|
||||||
|
alias qall quitall
|
||||||
|
alias setl setlocal
|
||||||
|
|
||||||
|
alias filter scout -prt
|
||||||
|
alias find scout -aeit
|
||||||
|
alias mark scout -mr
|
||||||
|
alias unmark scout -Mr
|
||||||
|
alias search scout -rs
|
||||||
|
alias search_inc scout -rts
|
||||||
|
alias travel scout -aefiklst
|
||||||
|
|
||||||
|
|
||||||
|
###BASIC KEYS###
|
||||||
|
|
||||||
|
#BASIC
|
||||||
|
map Q quit!
|
||||||
|
map q quit
|
||||||
|
copymap q ZZ ZQ
|
||||||
|
|
||||||
|
#map R reload_cwd
|
||||||
|
map <C-r> reset
|
||||||
|
#map <C-l> redraw_window
|
||||||
|
map <C-c> abort
|
||||||
|
map <esc> change_mode normal
|
||||||
|
|
||||||
|
map i display_file
|
||||||
|
map ? help
|
||||||
|
#map W display_log
|
||||||
|
map w taskview_open
|
||||||
|
map S shell $SHELL
|
||||||
|
|
||||||
|
map : console
|
||||||
|
map ; console
|
||||||
|
map ! console shell%space
|
||||||
|
map @ console -p6 shell %s
|
||||||
|
map # console shell -p%space
|
||||||
|
#map s console shell%space
|
||||||
|
map r chain draw_possible_programs; console open_with%space
|
||||||
|
map f console find%space
|
||||||
|
map cd console cd%space
|
||||||
|
|
||||||
|
|
||||||
|
# Change the line mode
|
||||||
|
#map Mf linemode filename
|
||||||
|
#map Mi linemode fileinfo
|
||||||
|
#map Mp linemode permissions
|
||||||
|
#map Mt linemode metatitle
|
||||||
|
|
||||||
|
#moc
|
||||||
|
#map Mc shell mocp -c
|
||||||
|
#map Ma shell mocp -a %s
|
||||||
|
#map Ms shell mocp -p
|
||||||
|
#map MS shell mocp -S
|
||||||
|
#map Mp shell mocp -G
|
||||||
|
#map Mn shell mocp -f
|
||||||
|
#map Mb shell mocp -r
|
||||||
|
#map MN shell mocp -s && mocp -c && mocp -a %s && mocp -p
|
||||||
|
#map Mo shell mocp -j 0%%
|
||||||
|
#map MK shell killall mocp
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
# Tagging / Marking
|
||||||
|
map at tag_toggle
|
||||||
|
map ut tag_remove
|
||||||
|
map "<any> tag_toggle tag=%any
|
||||||
|
map <Space> mark_files toggle=True
|
||||||
|
map va mark_files all=True toggle=True
|
||||||
|
map uv mark_files all=True val=False
|
||||||
|
map vs toggle_visual_mode
|
||||||
|
map uV toggle_visual_mode reverse=True
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
# For the nostalgics: Midnight Commander bindings
|
||||||
|
map <F1> help
|
||||||
|
map <F3> display_file
|
||||||
|
map <F4> edit
|
||||||
|
map <F5> copy
|
||||||
|
map <F5> console shell echo "require(rmarkdown); render_site()" | R --vanilla
|
||||||
|
map <F6> cut
|
||||||
|
map <F7> console mkdir%space
|
||||||
|
map <F8> console delete
|
||||||
|
map <F10> exit
|
||||||
|
|
||||||
|
|
||||||
|
# In case you work on a keyboard with dvorak layout
|
||||||
|
map <UP> move up=1
|
||||||
|
map <DOWN> move down=1
|
||||||
|
map <LEFT> move left=1
|
||||||
|
map <RIGHT> move right=1
|
||||||
|
map <HOME> move to=0
|
||||||
|
map <END> move to=-1
|
||||||
|
map <PAGEDOWN> move down=1 pages=True
|
||||||
|
map <PAGEUP> move up=1 pages=True
|
||||||
|
map <CR> move right=1
|
||||||
|
map <DELETE> console delete
|
||||||
|
map <INSERT> console touch%space
|
||||||
|
|
||||||
|
|
||||||
|
# VIM-like
|
||||||
|
copymap <UP> k
|
||||||
|
copymap <DOWN> j
|
||||||
|
copymap <LEFT> h
|
||||||
|
copymap <RIGHT> l
|
||||||
|
copymap <HOME> gg
|
||||||
|
copymap <END> G
|
||||||
|
copymap <PAGEDOWN> <C-F>
|
||||||
|
copymap <PAGEUP> <C-B>
|
||||||
|
|
||||||
|
map J move down=0.5 pages=True
|
||||||
|
map K move up=0.5 pages=True
|
||||||
|
copymap J <C-D>
|
||||||
|
copymap K <C-U>
|
||||||
|
|
||||||
|
|
||||||
|
# Jumping around
|
||||||
|
map H history_go -1
|
||||||
|
map L history_go 1
|
||||||
|
map ] move_parent 1
|
||||||
|
map [ move_parent -1
|
||||||
|
map } traverse
|
||||||
|
|
||||||
|
#DEFAULT MOVEMENT
|
||||||
|
map ge cd /etc
|
||||||
|
map gu cd /usr
|
||||||
|
#map gl cd -r .
|
||||||
|
map gL cd -r %f
|
||||||
|
#map gv cd /var
|
||||||
|
map gM cd /mnt
|
||||||
|
map gr cd /
|
||||||
|
map gR eval fm.cd(ranger.RANGERDIR)
|
||||||
|
map g? cd /usr/share/doc/ranger
|
||||||
|
|
||||||
|
# Tabs
|
||||||
|
map <C-n> tab_new ~
|
||||||
|
map <C-w> tab_close
|
||||||
|
map <TAB> tab_move 1
|
||||||
|
map <S-TAB> tab_move -1
|
||||||
|
map <A-Right> tab_move 1
|
||||||
|
map <A-Left> tab_move -1
|
||||||
|
#map gt tab_move 1
|
||||||
|
#map gT tab_move -1
|
||||||
|
map gn tab_new ~
|
||||||
|
#map gc tab_close
|
||||||
|
map tt tab_close
|
||||||
|
map uq tab_restore
|
||||||
|
map <a-1> tab_open 1
|
||||||
|
map <a-2> tab_open 2
|
||||||
|
map <a-3> tab_open 3
|
||||||
|
map <a-4> tab_open 4
|
||||||
|
map <a-5> tab_open 5
|
||||||
|
map <a-6> tab_open 6
|
||||||
|
map <a-7> tab_open 7
|
||||||
|
map <a-8> tab_open 8
|
||||||
|
map <a-9> tab_open 9
|
||||||
|
|
||||||
|
|
||||||
|
# External Programs
|
||||||
|
map E edit
|
||||||
|
map du shell -p du --max-depth=1 -h --apparent-size
|
||||||
|
map dU shell -p du --max-depth=1 -h --apparent-size | sort -rh
|
||||||
|
map yp shell -f echo -n %%d/%%f | xsel -i; xsel -o | xsel -i -b
|
||||||
|
map yd shell -f echo -n %%d | xsel -i; xsel -o | xsel -i -b
|
||||||
|
map yn shell -f echo -n %%f | xsel -i; xsel -o | xsel -i -b
|
||||||
|
|
||||||
|
|
||||||
|
# Filesystem Operations
|
||||||
|
map = chmod
|
||||||
|
map cw console rename%space
|
||||||
|
map aa rename_append
|
||||||
|
map A eval fm.open_console('rename ' + fm.thisfile.relative_path)
|
||||||
|
map I eval fm.open_console('rename ' + fm.thisfile.relative_path, position=7)
|
||||||
|
map pp paste
|
||||||
|
map po paste overwrite=True
|
||||||
|
map pP paste append=True
|
||||||
|
map pO paste overwrite=True append=True
|
||||||
|
map pl paste_symlink relative=False
|
||||||
|
map pL paste_symlink relative=True
|
||||||
|
map phl paste_hardlink
|
||||||
|
map pht paste_hardlinked_subtree
|
||||||
|
|
||||||
|
map dD console delete
|
||||||
|
|
||||||
|
map dd cut
|
||||||
|
map ud uncut
|
||||||
|
map da cut mode=add
|
||||||
|
map dr cut mode=remove
|
||||||
|
|
||||||
|
map yy copy
|
||||||
|
map uy uncut
|
||||||
|
map ya copy mode=add
|
||||||
|
map yr copy mode=remove
|
||||||
|
|
||||||
|
|
||||||
|
# Temporary workarounds
|
||||||
|
map dgg eval fm.cut(dirarg=dict(to=0), narg=quantifier)
|
||||||
|
map dG eval fm.cut(dirarg=dict(to=-1), narg=quantifier)
|
||||||
|
map dj eval fm.cut(dirarg=dict(down=1), narg=quantifier)
|
||||||
|
map dk eval fm.cut(dirarg=dict(up=1), narg=quantifier)
|
||||||
|
map ygg eval fm.copy(dirarg=dict(to=0), narg=quantifier)
|
||||||
|
map yG eval fm.copy(dirarg=dict(to=-1), narg=quantifier)
|
||||||
|
map yj eval fm.copy(dirarg=dict(down=1), narg=quantifier)
|
||||||
|
map yk eval fm.copy(dirarg=dict(up=1), narg=quantifier)
|
||||||
|
|
||||||
|
|
||||||
|
# Searching
|
||||||
|
map / console search%space
|
||||||
|
map n search_next
|
||||||
|
map N search_next forward=False
|
||||||
|
map ct search_next order=tag
|
||||||
|
map cs search_next order=size
|
||||||
|
map ci search_next order=mimetype
|
||||||
|
map cc search_next order=ctime
|
||||||
|
map cm search_next order=mtime
|
||||||
|
map ca search_next order=atime
|
||||||
|
|
||||||
|
|
||||||
|
# Sorting
|
||||||
|
map or toggle_option sort_reverse
|
||||||
|
map oz set sort=random
|
||||||
|
map os chain set sort=size; set sort_reverse=False
|
||||||
|
map ob chain set sort=basename; set sort_reverse=False
|
||||||
|
map on chain set sort=natural; set sort_reverse=False
|
||||||
|
map om chain set sort=mtime; set sort_reverse=False
|
||||||
|
map oc chain set sort=ctime; set sort_reverse=False
|
||||||
|
map oa chain set sort=atime; set sort_reverse=False
|
||||||
|
map ot chain set sort=type; set sort_reverse=False
|
||||||
|
map oe chain set sort=extension; set sort_reverse=False
|
||||||
|
|
||||||
|
map oS chain set sort=size; set sort_reverse=True
|
||||||
|
map oB chain set sort=basename; set sort_reverse=True
|
||||||
|
map oN chain set sort=natural; set sort_reverse=True
|
||||||
|
map oM chain set sort=mtime; set sort_reverse=True
|
||||||
|
map oC chain set sort=ctime; set sort_reverse=True
|
||||||
|
map oA chain set sort=atime; set sort_reverse=True
|
||||||
|
map oT chain set sort=type; set sort_reverse=True
|
||||||
|
map oE chain set sort=extension; set sort_reverse=True
|
||||||
|
|
||||||
|
map dc get_cumulative_size
|
||||||
|
|
||||||
|
|
||||||
|
# Settings
|
||||||
|
map zc toggle_option collapse_preview
|
||||||
|
map zd toggle_option sort_directories_first
|
||||||
|
map zh toggle_option show_hidden
|
||||||
|
map <C-h> toggle_option show_hidden
|
||||||
|
map zi toggle_option flushinput
|
||||||
|
map zm toggle_option mouse_enabled
|
||||||
|
map zp toggle_option preview_files
|
||||||
|
map zP toggle_option preview_directories
|
||||||
|
map zs toggle_option sort_case_insensitive
|
||||||
|
map zu toggle_option autoupdate_cumulative_size
|
||||||
|
map zv toggle_option use_preview_script
|
||||||
|
map zf console filter%space
|
||||||
|
|
||||||
|
|
||||||
|
# Bookmarks
|
||||||
|
#map `<any> enter_bookmark %any
|
||||||
|
#map '<any> enter_bookmark %any
|
||||||
|
#map mm<any> set_bookmark %any
|
||||||
|
#map um<any> unset_bookmark %any
|
||||||
|
|
||||||
|
#map m<bg> draw_bookmarks
|
||||||
|
#copymap m<bg> um<bg> `<bg> '<bg>
|
||||||
|
|
||||||
|
|
||||||
|
# Generate all the chmod bindings with some python help:
|
||||||
|
eval for arg in "rwxXst": cmd("map +u{0} shell -f chmod u+{0} %s".format(arg))
|
||||||
|
eval for arg in "rwxXst": cmd("map +g{0} shell -f chmod g+{0} %s".format(arg))
|
||||||
|
eval for arg in "rwxXst": cmd("map +o{0} shell -f chmod o+{0} %s".format(arg))
|
||||||
|
eval for arg in "rwxXst": cmd("map +a{0} shell -f chmod a+{0} %s".format(arg))
|
||||||
|
eval for arg in "rwxXst": cmd("map +{0} shell -f chmod u+{0} %s".format(arg))
|
||||||
|
|
||||||
|
eval for arg in "rwxXst": cmd("map -u{0} shell -f chmod u-{0} %s".format(arg))
|
||||||
|
eval for arg in "rwxXst": cmd("map -g{0} shell -f chmod g-{0} %s".format(arg))
|
||||||
|
eval for arg in "rwxXst": cmd("map -o{0} shell -f chmod o-{0} %s".format(arg))
|
||||||
|
eval for arg in "rwxXst": cmd("map -a{0} shell -f chmod a-{0} %s".format(arg))
|
||||||
|
eval for arg in "rwxXst": cmd("map -{0} shell -f chmod u-{0} %s".format(arg))
|
||||||
|
|
||||||
|
|
||||||
|
###CONSOLE KEYS###
|
||||||
|
# Basic
|
||||||
|
cmap <tab> eval fm.ui.console.tab()
|
||||||
|
cmap <s-tab> eval fm.ui.console.tab(-1)
|
||||||
|
cmap <ESC> eval fm.ui.console.close()
|
||||||
|
cmap <CR> eval fm.ui.console.execute()
|
||||||
|
#cmap <C-l> redraw_window
|
||||||
|
|
||||||
|
copycmap <ESC> <C-c>
|
||||||
|
copycmap <CR> <C-j>
|
||||||
|
|
||||||
|
|
||||||
|
# Move around
|
||||||
|
cmap <up> eval fm.ui.console.history_move(-1)
|
||||||
|
cmap <down> eval fm.ui.console.history_move(1)
|
||||||
|
cmap <left> eval fm.ui.console.move(left=1)
|
||||||
|
cmap <right> eval fm.ui.console.move(right=1)
|
||||||
|
cmap <home> eval fm.ui.console.move(right=0, absolute=True)
|
||||||
|
cmap <end> eval fm.ui.console.move(right=-1, absolute=True)
|
||||||
|
|
||||||
|
|
||||||
|
# Line Editing
|
||||||
|
cmap <backspace> eval fm.ui.console.delete(-1)
|
||||||
|
cmap <delete> eval fm.ui.console.delete(0)
|
||||||
|
cmap <C-w> eval fm.ui.console.delete_word()
|
||||||
|
cmap <A-d> eval fm.ui.console.delete_word(backward=False)
|
||||||
|
cmap <C-k> eval fm.ui.console.delete_rest(1)
|
||||||
|
cmap <C-u> eval fm.ui.console.delete_rest(-1)
|
||||||
|
cmap <C-y> eval fm.ui.console.paste()
|
||||||
|
|
||||||
|
# And of course the emacs way
|
||||||
|
#copycmap <up> <C-p>
|
||||||
|
#copycmap <down> <C-n>
|
||||||
|
#copycmap <left> <C-b>
|
||||||
|
#copycmap <right> <C-f>
|
||||||
|
#copycmap <home> <C-a>
|
||||||
|
#copycmap <end> <C-e>
|
||||||
|
#copycmap <delete> <C-d>
|
||||||
|
#copycmap <backspace> <C-h>
|
||||||
|
|
||||||
|
|
||||||
|
# Note: There are multiple ways to express backspaces. <backspace> (code 263)
|
||||||
|
# and <backspace2> (code 127). To be sure, use both.
|
||||||
|
copycmap <backspace> <backspace2>
|
||||||
|
|
||||||
|
# This special expression allows typing in numerals:
|
||||||
|
cmap <allow_quantifiers> false
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
###PAGER KEYS###
|
||||||
|
# Movement
|
||||||
|
pmap <down> pager_move down=1
|
||||||
|
pmap <up> pager_move up=1
|
||||||
|
pmap <left> pager_move left=4
|
||||||
|
pmap <right> pager_move right=4
|
||||||
|
pmap <home> pager_move to=0
|
||||||
|
pmap <end> pager_move to=-1
|
||||||
|
pmap <pagedown> pager_move down=1.0 pages=True
|
||||||
|
pmap <pageup> pager_move up=1.0 pages=True
|
||||||
|
pmap <C-d> pager_move down=0.5 pages=True
|
||||||
|
pmap <C-u> pager_move up=0.5 pages=True
|
||||||
|
|
||||||
|
copypmap <UP> k <C-p>
|
||||||
|
copypmap <DOWN> j <C-n> <CR>
|
||||||
|
copypmap <LEFT> h
|
||||||
|
copypmap <RIGHT> l
|
||||||
|
copypmap <HOME> g
|
||||||
|
copypmap <END> G
|
||||||
|
copypmap <C-d> d
|
||||||
|
copypmap <C-u> u
|
||||||
|
copypmap <PAGEDOWN> n f <C-F> <Space>
|
||||||
|
copypmap <PAGEUP> p b <C-B>
|
||||||
|
|
||||||
|
|
||||||
|
# Basic
|
||||||
|
#pmap <C-l> redraw_window
|
||||||
|
pmap <ESC> pager_close
|
||||||
|
copypmap <ESC> q Q i <F3>
|
||||||
|
pmap E edit_file
|
||||||
|
|
||||||
|
# ===================================================================
|
||||||
|
# == Taskview Keybindings
|
||||||
|
# ===================================================================
|
||||||
|
|
||||||
|
# Movement
|
||||||
|
tmap <up> taskview_move up=1
|
||||||
|
tmap <down> taskview_move down=1
|
||||||
|
tmap <home> taskview_move to=0
|
||||||
|
tmap <end> taskview_move to=-1
|
||||||
|
tmap <pagedown> taskview_move down=1.0 pages=True
|
||||||
|
tmap <pageup> taskview_move up=1.0 pages=True
|
||||||
|
tmap <C-d> taskview_move down=0.5 pages=True
|
||||||
|
tmap <C-u> taskview_move up=0.5 pages=True
|
||||||
|
|
||||||
|
copytmap <UP> k <C-p>
|
||||||
|
copytmap <DOWN> j <C-n> <CR>
|
||||||
|
copytmap <HOME> g
|
||||||
|
copytmap <END> G
|
||||||
|
copytmap <C-u> u
|
||||||
|
copytmap <PAGEDOWN> n f <C-F> <Space>
|
||||||
|
copytmap <PAGEUP> p b <C-B>
|
||||||
|
|
||||||
|
# Changing priority and deleting tasks
|
||||||
|
tmap J eval -q fm.ui.taskview.task_move(-1)
|
||||||
|
tmap K eval -q fm.ui.taskview.task_move(0)
|
||||||
|
tmap dd eval -q fm.ui.taskview.task_remove()
|
||||||
|
tmap <pagedown> eval -q fm.ui.taskview.task_move(-1)
|
||||||
|
tmap <pageup> eval -q fm.ui.taskview.task_move(0)
|
||||||
|
tmap <delete> eval -q fm.ui.taskview.task_remove()
|
||||||
|
|
||||||
|
# Basic
|
||||||
|
#tmap <C-l> redraw_window
|
||||||
|
tmap <ESC> taskview_close
|
||||||
|
copytmap <ESC> q Q w <C-c>
|
||||||
|
|
||||||
|
|
||||||
|
map sp console shell bash ~/.config/Scripts/speedvid.sh %f%space
|
||||||
|
map x shell chmod -x %s
|
||||||
|
|
||||||
|
#General
|
||||||
|
map V console shell vim%space
|
||||||
|
map cW bulkrename %s
|
||||||
|
map mkd console mkdir%space
|
||||||
|
map sc console shell ln -sT%space
|
||||||
|
map D console delete
|
||||||
|
map X shell ~/.config/Scripts/extract %f
|
||||||
|
map Z shell tar -cvzf %f.tar.gz %f
|
||||||
|
map <C-f> fzf_select
|
||||||
|
map <C-l> fzf_locate
|
||||||
|
|
||||||
|
#Document Manipulation
|
||||||
|
map p1s shell lpr -o sides=one-sided %f
|
||||||
|
map p2s shell lpr -o sides=two-sided-long-edge %f
|
||||||
|
map MP shell pandoc %f -o %f.pdf
|
||||||
|
map MX shell xelatex %f
|
||||||
|
map ML shell latex %f
|
||||||
|
map TC shell ~/.config/Scripts/texclear
|
||||||
|
map Txa console shell cp ~/Documents/LaTeX/article.tex%space
|
||||||
|
map Txs console shell cp ~/Documents/LaTeX/beamer.tex%space
|
||||||
|
map Txh console shell cp ~/Documents/LaTeX/handout.tex%space
|
||||||
|
|
||||||
|
#Image commands
|
||||||
|
map bg shell cp %f ~/.config/wall.png && feh --bg-scale %f
|
||||||
|
map bw shell wal -c -i %f && cp %f ~/.config/wall.png
|
||||||
|
map C shell killall w3mimgdisplay && convert -rotate 90 %s %s
|
||||||
|
map F shell killall w3mimgdisplay && convert -flop %s %s
|
||||||
|
map bl shell killall w3mimgdisplay && convert %s -resize 1440x1080\> bl_%s
|
||||||
|
map TR shell convert %s -transparent white %s
|
||||||
|
|
||||||
|
#Music (mpd) shortcuts
|
||||||
|
map MS shell mpd
|
||||||
|
map MK shell killall mpd
|
||||||
|
map Ma shell mpc add "%s"
|
||||||
|
map Ms shell mpc play
|
||||||
|
map Mp shell mpc toggle
|
||||||
|
map Mn shell mpc next
|
||||||
|
map Mb shell mpc prev
|
||||||
|
map MN shell mpc stop && mpc clear && mpc add "%s"
|
||||||
|
map Mo shell mpc seek 0%
|
||||||
|
|
||||||
|
#Audio tagging (Requires eyeD3)
|
||||||
|
map Ta eval fm.open_console('shell eyeD3 -a ' + fm.thisfile.relative_path, position=15)
|
||||||
|
#Artist
|
||||||
|
map TA eval fm.open_console('shell eyeD3 -A ' + fm.thisfile.relative_path, position=15)
|
||||||
|
#Album
|
||||||
|
map Tb eval fm.open_console('shell eyeD3 -b ' + fm.thisfile.relative_path, position=15)
|
||||||
|
#Album artist
|
||||||
|
map Tt eval fm.open_console('shell eyeD3 -t "" ' + fm.thisfile.relative_path, position=16)
|
||||||
|
map Tn eval fm.open_console('shell eyeD3 -n "" ' + fm.thisfile.relative_path, position=16)
|
||||||
|
|
||||||
|
#Downloading
|
||||||
|
map ytv console shell youtube-dl -ic%space
|
||||||
|
map yta console shell youtube-dl -xic%space
|
||||||
|
|
||||||
|
# Shortcuts
|
||||||
|
source ~/.config/ranger/shortcuts.conf
|
221
.config/ranger/rifle.conf
Normal file
221
.config/ranger/rifle.conf
Normal file
|
@ -0,0 +1,221 @@
|
||||||
|
# vim: ft=cfg
|
||||||
|
#
|
||||||
|
# This is the configuration file of "rifle", ranger's file executor/opener.
|
||||||
|
# Each line consists of conditions and a command. For each line the conditions
|
||||||
|
# are checked and if they are met, the respective command is run.
|
||||||
|
#
|
||||||
|
# Syntax:
|
||||||
|
# <condition1> , <condition2> , ... = command
|
||||||
|
#
|
||||||
|
# The command can contain these environment variables:
|
||||||
|
# $1-$9 | The n-th selected file
|
||||||
|
# $@ | All selected files
|
||||||
|
#
|
||||||
|
# If you use the special command "ask", rifle will ask you what program to run.
|
||||||
|
#
|
||||||
|
# Prefixing a condition with "!" will negate its result.
|
||||||
|
# These conditions are currently supported:
|
||||||
|
# match <regexp> | The regexp matches $1
|
||||||
|
# ext <regexp> | The regexp matches the extension of $1
|
||||||
|
# mime <regexp> | The regexp matches the mime type of $1
|
||||||
|
# name <regexp> | The regexp matches the basename of $1
|
||||||
|
# path <regexp> | The regexp matches the absolute path of $1
|
||||||
|
# has <program> | The program is installed (i.e. located in $PATH)
|
||||||
|
# env <variable> | The environment variable "variable" is non-empty
|
||||||
|
# file | $1 is a file
|
||||||
|
# directory | $1 is a directory
|
||||||
|
# number <n> | change the number of this command to n
|
||||||
|
# terminal | stdin, stderr and stdout are connected to a terminal
|
||||||
|
# X | $DISPLAY is not empty (i.e. Xorg runs)
|
||||||
|
#
|
||||||
|
# There are also pseudo-conditions which have a "side effect":
|
||||||
|
# flag <flags> | Change how the program is run. See below.
|
||||||
|
# label <label> | Assign a label or name to the command so it can
|
||||||
|
# | be started with :open_with <label> in ranger
|
||||||
|
# | or `rifle -p <label>` in the standalone executable.
|
||||||
|
# else | Always true.
|
||||||
|
#
|
||||||
|
# Flags are single characters which slightly transform the command:
|
||||||
|
# f | Fork the program, make it run in the background.
|
||||||
|
# | New command = setsid $command >& /dev/null &
|
||||||
|
# r | Execute the command with root permissions
|
||||||
|
# | New command = sudo $command
|
||||||
|
# t | Run the program in a new terminal. If $TERMCMD is not defined,
|
||||||
|
# | rifle will attempt to extract it from $TERM.
|
||||||
|
# | New command = $TERMCMD -e $command
|
||||||
|
# Note: The "New command" serves only as an illustration, the exact
|
||||||
|
# implementation may differ.
|
||||||
|
# Note: When using rifle in ranger, there is an additional flag "c" for
|
||||||
|
# only running the current file even if you have marked multiple files.
|
||||||
|
|
||||||
|
#-------------------------------------------
|
||||||
|
# Websites
|
||||||
|
#-------------------------------------------
|
||||||
|
# Rarely installed browsers get higher priority; It is assumed that if you
|
||||||
|
# install a rare browser, you probably use it. Firefox/konqueror/w3m on the
|
||||||
|
# other hand are often only installed as fallback browsers.
|
||||||
|
|
||||||
|
ext x?html?, has surf, X, flag f = surf -- file://"$1"
|
||||||
|
ext x?html?, has vimprobable, X, flag f = vimprobable -- "$@"
|
||||||
|
ext x?html?, has vimprobable2, X, flag f = vimprobable2 -- "$@"
|
||||||
|
ext x?html?, has qutebrowser, X, flag f = qutebrowser -- "$@"
|
||||||
|
ext x?html?, has dwb, X, flag f = dwb -- "$@"
|
||||||
|
ext x?html?, has jumanji, X, flag f = jumanji -- "$@"
|
||||||
|
ext x?html?, has luakit, X, flag f = luakit -- "$@"
|
||||||
|
ext x?html?, has uzbl, X, flag f = uzbl -- "$@"
|
||||||
|
ext x?html?, has uzbl-tabbed, X, flag f = uzbl-tabbed -- "$@"
|
||||||
|
ext x?html?, has uzbl-browser, X, flag f = uzbl-browser -- "$@"
|
||||||
|
ext x?html?, has uzbl-core, X, flag f = uzbl-core -- "$@"
|
||||||
|
ext x?html?, has midori, X, flag f = midori -- "$@"
|
||||||
|
ext x?html?, has chromium, X, flag f = chromium -- "$@"
|
||||||
|
ext x?html?, has opera, X, flag f = opera -- "$@"
|
||||||
|
ext x?html?, has firefox, X, flag f = firefox -- "$@"
|
||||||
|
ext x?html?, has seamonkey, X, flag f = seamonkey -- "$@"
|
||||||
|
ext x?html?, has iceweasel, X, flag f = iceweasel -- "$@"
|
||||||
|
ext x?html?, has epiphany, X, flag f = epiphany -- "$@"
|
||||||
|
ext x?html?, has konqueror, X, flag f = konqueror -- "$@"
|
||||||
|
ext x?html?, has elinks, terminal = elinks "$@"
|
||||||
|
ext x?html?, has links2, terminal = links2 "$@"
|
||||||
|
ext x?html?, has links, terminal = links "$@"
|
||||||
|
ext x?html?, has lynx, terminal = lynx -- "$@"
|
||||||
|
ext x?html?, has w3m, terminal = w3m "$@"
|
||||||
|
|
||||||
|
#-------------------------------------------
|
||||||
|
# Misc
|
||||||
|
#-------------------------------------------
|
||||||
|
# Define the "editor" for text files as first action
|
||||||
|
mime ^text, label editor = $EDITOR -- "$@"
|
||||||
|
mime ^text, label pager = "$PAGER" -- "$@"
|
||||||
|
!mime ^text, label editor, ext xml|json|csv|tex|py|pl|rb|js|sh|php = $EDITOR -- "$@"
|
||||||
|
!mime ^text, label pager, ext xml|json|csv|tex|py|pl|rb|js|sh|php = "$PAGER" -- "$@"
|
||||||
|
|
||||||
|
ext 1 = man "$1"
|
||||||
|
ext s[wmf]c, has zsnes, X = zsnes "$1"
|
||||||
|
ext s[wmf]c, has snes9x-gtk,X = snes9x-gtk "$1"
|
||||||
|
ext nes, has fceux, X = fceux "$1"
|
||||||
|
ext exe = wine "$1"
|
||||||
|
name ^[mM]akefile$ = make
|
||||||
|
|
||||||
|
#--------------------------------------------
|
||||||
|
# Code
|
||||||
|
#-------------------------------------------
|
||||||
|
ext py = python -- "$1"
|
||||||
|
ext pl = perl -- "$1"
|
||||||
|
ext rb = ruby -- "$1"
|
||||||
|
ext js = node -- "$1"
|
||||||
|
ext sh = sh -- "$1"
|
||||||
|
ext php = php -- "$1"
|
||||||
|
|
||||||
|
#--------------------------------------------
|
||||||
|
# Audio without X
|
||||||
|
#-------------------------------------------
|
||||||
|
mime ^audio|ogg$, terminal, has mplayer = mplayer -- "$@"
|
||||||
|
mime ^audio|ogg$, terminal, has mplayer2 = mplayer2 -- "$@"
|
||||||
|
mime ^audio|ogg$, terminal, has mpv = mpv --no-audio-display -- "$@"
|
||||||
|
mime ^audio|ogg$, terminal, has mpv = mpv -- "$@"
|
||||||
|
ext midi?, terminal, has wildmidi = wildmidi -- "$@"
|
||||||
|
|
||||||
|
#--------------------------------------------
|
||||||
|
# Video/Audio with a GUI
|
||||||
|
#-------------------------------------------
|
||||||
|
mime ^video|audio, has gmplayer, X, flag f = gmplayer -- "$@"
|
||||||
|
mime ^video|audio, has smplayer, X, flag f = smplayer "$@"
|
||||||
|
mime ^video, has mpv, X, flag f = mpv -- "$@"
|
||||||
|
mime ^video, has mpv, X, flag f = mpv --fs -- "$@"
|
||||||
|
mime ^video, has mpv, X, flag f = mpv --loop -- "$@"
|
||||||
|
mime ^video, has mplayer2, X, flag f = mplayer2 -- "$@"
|
||||||
|
mime ^video, has mplayer2, X, flag f = mplayer2 -fs -- "$@"
|
||||||
|
mime ^video, has mplayer, X, flag f = mplayer -- "$@"
|
||||||
|
mime ^video, has mplayer, X, flag f = mplayer -fs -- "$@"
|
||||||
|
mime ^video|audio, has vlc, X, flag f = vlc -- "$@"
|
||||||
|
mime ^video|audio, has totem, X, flag f = totem -- "$@"
|
||||||
|
mime ^video|audio, has totem, X, flag f = totem --fullscreen -- "$@"
|
||||||
|
|
||||||
|
#--------------------------------------------
|
||||||
|
# Video without X:
|
||||||
|
#-------------------------------------------
|
||||||
|
mime ^video, terminal, !X, has mpv = mpv -- "$@"
|
||||||
|
mime ^video, terminal, !X, has mplayer2 = mplayer2 -- "$@"
|
||||||
|
mime ^video, terminal, !X, has mplayer = mplayer -- "$@"
|
||||||
|
|
||||||
|
#-------------------------------------------
|
||||||
|
# Documents
|
||||||
|
#-------------------------------------------
|
||||||
|
ext pdf, has llpp, X, flag f = llpp "$@"
|
||||||
|
ext pdf, has zathura, X, flag f = zathura -- "$@"
|
||||||
|
ext pdf, has mupdf, X, flag f = mupdf "$@"
|
||||||
|
ext pdf, has mupdf-x11,X, flag f = mupdf-x11 "$@"
|
||||||
|
ext pdf, has apvlv, X, flag f = apvlv -- "$@"
|
||||||
|
ext pdf, has xpdf, X, flag f = xpdf -- "$@"
|
||||||
|
ext pdf, has evince, X, flag f = evince -- "$@"
|
||||||
|
ext pdf, has atril, X, flag f = atril -- "$@"
|
||||||
|
ext pdf, has okular, X, flag f = okular -- "$@"
|
||||||
|
ext pdf, has epdfview, X, flag f = epdfview -- "$@"
|
||||||
|
ext pdf, has qpdfview, X, flag f = qpdfview "$@"
|
||||||
|
|
||||||
|
ext epub, has mupdf, X, flag f = mupdf "$@"
|
||||||
|
|
||||||
|
ext docx, has abiword, X, flag f = abiword "$@"
|
||||||
|
|
||||||
|
ext docx?, has catdoc, terminal = catdoc -- "$@" | "$PAGER"
|
||||||
|
|
||||||
|
ext sxc|xlsx?|xlt|xlw|gnm|gnumeric, has gnumeric, X, flag f = gnumeric -- "$@"
|
||||||
|
ext sxc|xlsx?|xlt|xlw|gnm|gnumeric, has kspread, X, flag f = kspread -- "$@"
|
||||||
|
ext pptx?|od[dfgpst]|docx?|sxc|xlsx?|xlt|xlw|gnm|gnumeric, has libreoffice, X, flag f = libreoffice "$@"
|
||||||
|
ext pptx?|od[dfgpst]|docx?|sxc|xlsx?|xlt|xlw|gnm|gnumeric, has soffice, X, flag f = soffice "$@"
|
||||||
|
ext pptx?|od[dfgpst]|docx?|sxc|xlsx?|xlt|xlw|gnm|gnumeric, has ooffice, X, flag f = ooffice "$@"
|
||||||
|
|
||||||
|
ext djvu, has zathura,X, flag f = zathura -- "$@"
|
||||||
|
ext djvu, has evince, X, flag f = evince -- "$@"
|
||||||
|
ext djvu, has atril, X, flag f = atril -- "$@"
|
||||||
|
|
||||||
|
#-------------------------------------------
|
||||||
|
# Image Viewing:
|
||||||
|
#-------------------------------------------
|
||||||
|
mime ^image/svg, has inkscape, X, flag f = inkscape -- "$@"
|
||||||
|
mime ^image/svg, has display, X, flag f = display -- "$@"
|
||||||
|
mime ^image/gif, has mpv, X, flag f = mpv --loop -- "$@"
|
||||||
|
mime ^image/gif, has viewnior, X, flag f = viewnior -- "$@"
|
||||||
|
mime ^image/gif, has qutebrowser, X, flag f = qutebrowser -- "$@"
|
||||||
|
|
||||||
|
mime ^image, has sxiv, X, flag f = sxiv -- "$@"
|
||||||
|
mime ^image, has feh, X, flag f = feh --scale-down --auto-zoom -- "$@"
|
||||||
|
mime ^image, has mirage, X, flag f = mirage -- "$@"
|
||||||
|
mime ^image, has ristretto, X, flag f = ristretto "$@"
|
||||||
|
mime ^image, has eog, X, flag f = eog -- "$@"
|
||||||
|
mime ^image, has eom, X, flag f = eom -- "$@"
|
||||||
|
mime ^image, has gimp, X, flag f = gimp -- "$@"
|
||||||
|
mime ^image, has pinta, X, flag f = pinta -- "$@"
|
||||||
|
mime ^image, has mypaint, X, flag f = mypaint -- "$@"
|
||||||
|
mime ^image, has kolourpaint, X, flag f = kolourpaint -- "$@"
|
||||||
|
ext xcf, X, flag f = gimp -- "$@"
|
||||||
|
|
||||||
|
#-------------------------------------------
|
||||||
|
# Archives
|
||||||
|
#-------------------------------------------
|
||||||
|
# This requires atool
|
||||||
|
ext jar = java -jar "$@"
|
||||||
|
|
||||||
|
ext 7z|ace|ar|arc|bz2?|cab|cpio|cpt|deb|dgc|dmg|gz, has als = als -- "$@" | "$PAGER"
|
||||||
|
ext iso|jar|msi|pkg|rar|shar|tar|tgz|xar|xpi|xz|zip, has als = als -- "$@" | "$PAGER"
|
||||||
|
ext 7z|ace|ar|arc|bz2?|cab|cpio|cpt|deb|dgc|dmg|gz, has aunpack = aunpack -- "$@"
|
||||||
|
ext iso|jar|msi|pkg|rar|shar|tar|tgz|xar|xpi|xz|zip, has aunpack = aunpack -- "$@"
|
||||||
|
|
||||||
|
# Fallback:
|
||||||
|
ext tar|gz, has tar = tar vvtf "$@" | "$PAGER"
|
||||||
|
ext tar|gz, has tar = tar vvxf "$@"
|
||||||
|
|
||||||
|
#-------------------------------------------
|
||||||
|
# Misc
|
||||||
|
#-------------------------------------------
|
||||||
|
label wallpaper, number 11, mime ^image, has feh, X = feh --bg-scale "$1"
|
||||||
|
label wallpaper, number 12, mime ^image, has feh, X = feh --bg-tile "$1"
|
||||||
|
label wallpaper, number 13, mime ^image, has feh, X = feh --bg-center "$1"
|
||||||
|
label wallpaper, number 14, mime ^image, has feh, X = feh --bg-fill "$1"
|
||||||
|
|
||||||
|
# Define the editor for non-text files + pager as last action
|
||||||
|
!mime ^text, !ext xml|json|csv|tex|py|pl|rb|js|sh|php = ask
|
||||||
|
label editor, !mime ^text, !ext xml|json|csv|tex|py|pl|rb|js|sh|php = $EDITOR -- "$@"
|
||||||
|
label pager, !mime ^text, !ext xml|json|csv|tex|py|pl|rb|js|sh|php = "$PAGER" -- "$@"
|
||||||
|
|
||||||
|
ext blend, has blender, X, flag f = blender -- "$@"
|
121
.config/ranger/scope.sh
Executable file
121
.config/ranger/scope.sh
Executable file
|
@ -0,0 +1,121 @@
|
||||||
|
#!/usr/bin/env sh
|
||||||
|
# ranger supports enhanced previews. If the option "use_preview_script"
|
||||||
|
# is set to True and this file exists, this script will be called and its
|
||||||
|
# output is displayed in ranger. ANSI color codes are supported.
|
||||||
|
|
||||||
|
# NOTES: This script is considered a configuration file. If you upgrade
|
||||||
|
# ranger, it will be left untouched. (You must update it yourself.)
|
||||||
|
# Also, ranger disables STDIN here, so interactive scripts won't work properly
|
||||||
|
|
||||||
|
# Meanings of exit codes:
|
||||||
|
# code | meaning | action of ranger
|
||||||
|
# -----+------------+-------------------------------------------
|
||||||
|
# 0 | success | success. display stdout as preview
|
||||||
|
# 1 | no preview | failure. display no preview at all
|
||||||
|
# 2 | plain text | display the plain content of the file
|
||||||
|
# 3 | fix width | success. Don't reload when width changes
|
||||||
|
# 4 | fix height | success. Don't reload when height changes
|
||||||
|
# 5 | fix both | success. Don't ever reload
|
||||||
|
# 6 | image | success. display the image $cached points to as an image preview
|
||||||
|
# 7 | image | success. display the file directly as an image
|
||||||
|
|
||||||
|
# Meaningful aliases for arguments:
|
||||||
|
path="$1" # Full path of the selected file
|
||||||
|
width="$2" # Width of the preview pane (number of fitting characters)
|
||||||
|
height="$3" # Height of the preview pane (number of fitting characters)
|
||||||
|
cached="$4" # Path that should be used to cache image previews
|
||||||
|
preview_images="$5" # "True" if image previews are enabled, "False" otherwise.
|
||||||
|
|
||||||
|
maxln=200 # Stop after $maxln lines. Can be used like ls | head -n $maxln
|
||||||
|
|
||||||
|
# Find out something about the file:
|
||||||
|
mimetype=$(file --mime-type -Lb "$path")
|
||||||
|
extension=$(/bin/echo "${path##*.}" | awk '{print tolower($0)}')
|
||||||
|
|
||||||
|
# Functions:
|
||||||
|
# runs a command and saves its output into $output. Useful if you need
|
||||||
|
# the return value AND want to use the output in a pipe
|
||||||
|
try() { output=$(eval '"$@"'); }
|
||||||
|
|
||||||
|
# writes the output of the previously used "try" command
|
||||||
|
dump() { /bin/echo "$output"; }
|
||||||
|
|
||||||
|
# a common post-processing function used after most commands
|
||||||
|
trim() { head -n "$maxln"; }
|
||||||
|
|
||||||
|
# wraps highlight to treat exit code 141 (killed by SIGPIPE) as success
|
||||||
|
safepipe() { "$@"; test $? = 0 -o $? = 141; }
|
||||||
|
|
||||||
|
# Image previews, if enabled in ranger.
|
||||||
|
if [ "$preview_images" = "True" ]; then
|
||||||
|
case "$mimetype" in
|
||||||
|
# Image previews for SVG files, disabled by default.
|
||||||
|
###image/svg+xml)
|
||||||
|
### convert "$path" "$cached" && exit 6 || exit 1;;
|
||||||
|
# Image previews for image files. w3mimgdisplay will be called for all
|
||||||
|
# image files (unless overriden as above), but might fail for
|
||||||
|
# unsupported types.
|
||||||
|
image/*)
|
||||||
|
exit 7;;
|
||||||
|
# Image preview for video, disabled by default.:
|
||||||
|
###video/*)
|
||||||
|
### ffmpegthumbnailer -i "$path" -o "$cached" -s 0 && exit 6 || exit 1;;
|
||||||
|
esac
|
||||||
|
fi
|
||||||
|
|
||||||
|
case "$extension" in
|
||||||
|
# Archive extensions:
|
||||||
|
a|ace|alz|arc|arj|bz|bz2|cab|cpio|deb|gz|jar|lha|lz|lzh|lzma|lzo|\
|
||||||
|
rpm|rz|t7z|tar|tbz|tbz2|tgz|tlz|txz|tZ|tzo|war|xpi|xz|Z|zip)
|
||||||
|
try als "$path" && { dump | trim; exit 0; }
|
||||||
|
try acat "$path" && { dump | trim; exit 3; }
|
||||||
|
try bsdtar -lf "$path" && { dump | trim; exit 0; }
|
||||||
|
exit 1;;
|
||||||
|
rar)
|
||||||
|
# avoid password prompt by providing empty password
|
||||||
|
try unrar -p- lt "$path" && { dump | trim; exit 0; } || exit 1;;
|
||||||
|
7z)
|
||||||
|
# avoid password prompt by providing empty password
|
||||||
|
try 7z -p l "$path" && { dump | trim; exit 0; } || exit 1;;
|
||||||
|
# PDF documents:
|
||||||
|
pdf)
|
||||||
|
try pdftotext -l 10 -nopgbrk -q "$path" - && \
|
||||||
|
{ dump | trim | fmt -s -w $width; exit 0; } || exit 1;;
|
||||||
|
# BitTorrent Files
|
||||||
|
torrent)
|
||||||
|
try transmission-show "$path" && { dump | trim; exit 5; } || exit 1;;
|
||||||
|
# ODT Files
|
||||||
|
odt|ods|odp|sxw)
|
||||||
|
try odt2txt "$path" && { dump | trim; exit 5; } || exit 1;;
|
||||||
|
# HTML Pages:
|
||||||
|
htm|html|xhtml)
|
||||||
|
try w3m -dump "$path" && { dump | trim | fmt -s -w $width; exit 4; }
|
||||||
|
try lynx -dump "$path" && { dump | trim | fmt -s -w $width; exit 4; }
|
||||||
|
try elinks -dump "$path" && { dump | trim | fmt -s -w $width; exit 4; }
|
||||||
|
;; # fall back to highlight/cat if the text browsers fail
|
||||||
|
esac
|
||||||
|
|
||||||
|
case "$mimetype" in
|
||||||
|
# Syntax highlight for text files:
|
||||||
|
text/* | */xml)
|
||||||
|
if [ "$(tput colors)" -ge 256 ]; then
|
||||||
|
pygmentize_format=terminal256
|
||||||
|
highlight_format=xterm256
|
||||||
|
else
|
||||||
|
pygmentize_format=terminal
|
||||||
|
highlight_format=ansi
|
||||||
|
fi
|
||||||
|
try safepipe highlight --out-format=${highlight_format} "$path" && { dump | trim; exit 5; }
|
||||||
|
try safepipe pygmentize -f ${pygmentize_format} "$path" && { dump | trim; exit 5; }
|
||||||
|
exit 2;;
|
||||||
|
# Ascii-previews of images:
|
||||||
|
image/*)
|
||||||
|
img2txt --gamma=0.6 --width="$width" "$path" && exit 4 || exit 1;;
|
||||||
|
# Display information about media files:
|
||||||
|
video/* | audio/*)
|
||||||
|
exiftool "$path" && exit 5
|
||||||
|
# Use sed to remove spaces so the output fits into the narrow window
|
||||||
|
try mediainfo "$path" && { dump | trim | sed 's/ \+:/: /;'; exit 5; } || exit 1;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
exit 1
|
1
.config/user-dirs.dirs
Executable file
1
.config/user-dirs.dirs
Executable file
|
@ -0,0 +1 @@
|
||||||
|
XDG_DESKTOP_DIR="$HOME/"
|
BIN
.config/wall.png
Normal file
BIN
.config/wall.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 213 KiB |
19
.gtkrc-2.0
Normal file
19
.gtkrc-2.0
Normal file
|
@ -0,0 +1,19 @@
|
||||||
|
# DO NOT EDIT! This file will be overwritten by LXAppearance.
|
||||||
|
# Any customization should be done in ~/.gtkrc-2.0.mine instead.
|
||||||
|
|
||||||
|
include "/home/luke/.gtkrc-2.0.mine"
|
||||||
|
gtk-theme-name="Blackbird"
|
||||||
|
gtk-icon-theme-name="Adwaita"
|
||||||
|
gtk-font-name="Sans 10"
|
||||||
|
gtk-cursor-theme-name="Adwaita"
|
||||||
|
gtk-cursor-theme-size=0
|
||||||
|
gtk-toolbar-style=GTK_TOOLBAR_TEXT
|
||||||
|
gtk-toolbar-icon-size=GTK_ICON_SIZE_LARGE_TOOLBAR
|
||||||
|
gtk-button-images=0
|
||||||
|
gtk-menu-images=1
|
||||||
|
gtk-enable-event-sounds=1
|
||||||
|
gtk-enable-input-feedback-sounds=1
|
||||||
|
gtk-xft-antialias=1
|
||||||
|
gtk-xft-hinting=1
|
||||||
|
gtk-xft-hintstyle="hintfull"
|
||||||
|
gtk-xft-rgba="rgb"
|
12
.inputrc
Normal file
12
.inputrc
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
$include /etc/inputrc
|
||||||
|
set editing-mode vi
|
||||||
|
$if mode=vi
|
||||||
|
|
||||||
|
set keymap vi-command
|
||||||
|
# these are for vi-command mode
|
||||||
|
Control-l: clear-screen
|
||||||
|
|
||||||
|
set keymap vi-insert
|
||||||
|
# these are for vi-insert mode
|
||||||
|
Control-l: clear-screen
|
||||||
|
$endif
|
25
.msmtprc
Normal file
25
.msmtprc
Normal file
|
@ -0,0 +1,25 @@
|
||||||
|
# vim: filetype=config
|
||||||
|
#These are settings for all accounts.
|
||||||
|
account default
|
||||||
|
protocol smtp
|
||||||
|
auth on
|
||||||
|
tls on
|
||||||
|
tls_nocertcheck
|
||||||
|
|
||||||
|
#Below are example accounts. Comment out what you don't use.
|
||||||
|
|
||||||
|
#Here is an example gmail account.
|
||||||
|
account gmail
|
||||||
|
from YOURNAME@gmail.com
|
||||||
|
user YOURNAME@gmail.com
|
||||||
|
password "PASSWORD"
|
||||||
|
host smtp.gmail.com
|
||||||
|
port 587
|
||||||
|
|
||||||
|
#Here is another example account. Search for your email host's SMTP server and add the information here.
|
||||||
|
account personal
|
||||||
|
from USER@DOMMAIN.COM
|
||||||
|
user USER@DOMMAIN.COM
|
||||||
|
password "PASSWORD"
|
||||||
|
host HOST-SERVER
|
||||||
|
port XXX
|
612
.ncmpcpp/bindings
Normal file
612
.ncmpcpp/bindings
Normal file
|
@ -0,0 +1,612 @@
|
||||||
|
##############################################################
|
||||||
|
## This is the example bindings file. Copy it to ##
|
||||||
|
## ~/.ncmpcpp/bindings or $XDG_CONFIG_HOME/ncmpcpp/bindings ##
|
||||||
|
## and set up your preferences ##
|
||||||
|
##############################################################
|
||||||
|
##
|
||||||
|
##### General rules #####
|
||||||
|
##
|
||||||
|
## 1) Because each action has runtime checks whether it's
|
||||||
|
## ok to run it, a few actions can be bound to one key.
|
||||||
|
## Actions will be bound in order given in configuration
|
||||||
|
## file. When a key is pressed, first action in order
|
||||||
|
## will test itself whether it's possible to run it. If
|
||||||
|
## test succeeds, action is executed and other actions
|
||||||
|
## bound to this key are ignored. If it doesn't, next
|
||||||
|
## action in order tests itself etc.
|
||||||
|
##
|
||||||
|
## 2) It's possible to bind more that one action at once
|
||||||
|
## to a key. It can be done using the following syntax:
|
||||||
|
##
|
||||||
|
## def_key "key"
|
||||||
|
## action1
|
||||||
|
## action2
|
||||||
|
## ...
|
||||||
|
##
|
||||||
|
## This creates a chain of actions. When such chain is
|
||||||
|
## executed, each action in chain is run until the end of
|
||||||
|
## chain is reached or one of its actions fails to execute
|
||||||
|
## due to its requirements not being met. If multiple actions
|
||||||
|
## and/or chains are bound to the same key, they will be
|
||||||
|
## consecutively run until one of them gets fully executed.
|
||||||
|
##
|
||||||
|
## 3) When ncmpcpp starts, bindings configuration file is
|
||||||
|
## parsed and then ncmpcpp provides "missing pieces"
|
||||||
|
## of default keybindings. If you want to disable some
|
||||||
|
## bindings, there is a special action called 'dummy'
|
||||||
|
## for that purpose. Eg. if you want to disable ability
|
||||||
|
## to crop playlists, you need to put the following
|
||||||
|
## into configuration file:
|
||||||
|
##
|
||||||
|
## def_key "C"
|
||||||
|
## dummy
|
||||||
|
##
|
||||||
|
## After that ncmpcpp will not bind any default action
|
||||||
|
## to this key.
|
||||||
|
##
|
||||||
|
## 4) To let you write simple macros, the following special
|
||||||
|
## actions are provided:
|
||||||
|
##
|
||||||
|
## - push_character "character" - pushes given special
|
||||||
|
## character into input queue, so it will be immediately
|
||||||
|
## picked by ncmpcpp upon next call to readKey function.
|
||||||
|
## Accepted values: mouse, up, down, page_up, page_down,
|
||||||
|
## home, end, space, enter, insert, delete, left, right,
|
||||||
|
## tab, ctrl-a, ctrl-b, ..., ctrl-z, ctrl-[, ctrl-\\,
|
||||||
|
## ctrl-], ctrl-^, ctrl-_, f1, f2, ..., f12, backspace.
|
||||||
|
## In addition, most of these names can be prefixed with
|
||||||
|
## alt-/ctrl-/shift- to be recognized with the appropriate
|
||||||
|
## modifier key(s).
|
||||||
|
##
|
||||||
|
## - push_characters "string" - pushes given string into
|
||||||
|
## input queue.
|
||||||
|
##
|
||||||
|
## - require_runnable "action" - checks whether given action
|
||||||
|
## is runnable and fails if it isn't. This is especially
|
||||||
|
## useful when mixed with previous two functions. Consider
|
||||||
|
## the following macro definition:
|
||||||
|
##
|
||||||
|
## def_key "key"
|
||||||
|
## push_characters "custom_filter"
|
||||||
|
## apply_filter
|
||||||
|
##
|
||||||
|
## If apply_filter can't be currently run, we end up with
|
||||||
|
## sequence of characters in input queue which will be
|
||||||
|
## treated just as we typed them. This may lead to unexpected
|
||||||
|
## results (in this case 'c' will most likely clear current
|
||||||
|
## playlist, 'u' will trigger database update, 's' will stop
|
||||||
|
## playback etc.). To prevent such thing from happening, we
|
||||||
|
## need to change above definition to this one:
|
||||||
|
##
|
||||||
|
## def_key "key"
|
||||||
|
## require_runnable "apply_filter"
|
||||||
|
## push_characters "custom_filter"
|
||||||
|
## apply_filter
|
||||||
|
##
|
||||||
|
## Here, first we test whether apply_filter can be actually run
|
||||||
|
## before we stuff characters into input queue, so if condition
|
||||||
|
## is not met, whole chain is aborted and we're fine.
|
||||||
|
##
|
||||||
|
## - require_screen "screen" - checks whether given screen is
|
||||||
|
## currently active. accepted values: browser, clock, help,
|
||||||
|
## media_library, outputs, playlist, playlist_editor,
|
||||||
|
## search_engine, tag_editor, visualizer, last_fm, lyrics,
|
||||||
|
## selected_items_adder, server_info, song_info,
|
||||||
|
## sort_playlist_dialog, tiny_tag_editor.
|
||||||
|
##
|
||||||
|
## - run_external_command "command" - runs given command using
|
||||||
|
## system() function.
|
||||||
|
##
|
||||||
|
## 5) In addition to binding to a key, you can also bind actions
|
||||||
|
## or chains of actions to a command. If it comes to commands,
|
||||||
|
## syntax is very similar to defining keys. Here goes example
|
||||||
|
## definition of a command:
|
||||||
|
##
|
||||||
|
## def_command "quit" [deferred]
|
||||||
|
## stop
|
||||||
|
## quit
|
||||||
|
##
|
||||||
|
## If you execute the above command (which can be done by
|
||||||
|
## invoking action execute_command, typing 'quit' and pressing
|
||||||
|
## enter), ncmpcpp will stop the player and then quit. Note the
|
||||||
|
## presence of word 'deferred' enclosed in square brackets. It
|
||||||
|
## tells ncmpcpp to wait for confirmation (ie. pressing enter)
|
||||||
|
## after you typed quit. Instead of 'deferred', 'immediate'
|
||||||
|
## could be used. Then ncmpcpp will not wait for confirmation
|
||||||
|
## (enter) and will execute the command the moment it sees it.
|
||||||
|
##
|
||||||
|
## Note: while command chains are executed, internal environment
|
||||||
|
## update (which includes current window refresh and mpd status
|
||||||
|
## update) is not performed for performance reasons. However, it
|
||||||
|
## may be desirable to do so in some situration. Therefore it's
|
||||||
|
## possible to invoke by hand by performing 'update enviroment'
|
||||||
|
## action.
|
||||||
|
##
|
||||||
|
## Note: There is a difference between:
|
||||||
|
##
|
||||||
|
## def_key "key"
|
||||||
|
## action1
|
||||||
|
##
|
||||||
|
## def_key "key"
|
||||||
|
## action2
|
||||||
|
##
|
||||||
|
## and
|
||||||
|
##
|
||||||
|
## def_key "key"
|
||||||
|
## action1
|
||||||
|
## action2
|
||||||
|
##
|
||||||
|
## First one binds two single actions to the same key whilst
|
||||||
|
## second one defines a chain of actions. The behavior of
|
||||||
|
## these two is different and is described in (1) and (2).
|
||||||
|
##
|
||||||
|
## Note: Function def_key accepts non-ascii characters.
|
||||||
|
##
|
||||||
|
##### List of unbound actions #####
|
||||||
|
##
|
||||||
|
## The following actions are not bound to any key/command:
|
||||||
|
##
|
||||||
|
## - set_volume
|
||||||
|
##
|
||||||
|
#
|
||||||
|
#def_key "mouse"
|
||||||
|
# mouse_event
|
||||||
|
#
|
||||||
|
#def_key "up"
|
||||||
|
# scroll_up
|
||||||
|
#
|
||||||
|
#def_key "shift-up"
|
||||||
|
# select_item
|
||||||
|
# scroll_up
|
||||||
|
#
|
||||||
|
#def_key "down"
|
||||||
|
# scroll_down
|
||||||
|
#
|
||||||
|
#def_key "shift-down"
|
||||||
|
# select_item
|
||||||
|
# scroll_down
|
||||||
|
#
|
||||||
|
#def_key "["
|
||||||
|
# scroll_up_album
|
||||||
|
#
|
||||||
|
#def_key "]"
|
||||||
|
# scroll_down_album
|
||||||
|
#
|
||||||
|
#def_key "{"
|
||||||
|
# scroll_up_artist
|
||||||
|
#
|
||||||
|
#def_key "}"
|
||||||
|
# scroll_down_artist
|
||||||
|
#
|
||||||
|
#def_key "page_up"
|
||||||
|
# page_up
|
||||||
|
#
|
||||||
|
#def_key "page_down"
|
||||||
|
# page_down
|
||||||
|
#
|
||||||
|
#def_key "home"
|
||||||
|
# move_home
|
||||||
|
#
|
||||||
|
#def_key "end"
|
||||||
|
# move_end
|
||||||
|
#
|
||||||
|
#def_key "insert"
|
||||||
|
# select_item
|
||||||
|
#
|
||||||
|
#def_key "enter"
|
||||||
|
# enter_directory
|
||||||
|
#
|
||||||
|
#def_key "enter"
|
||||||
|
# toggle_output
|
||||||
|
#
|
||||||
|
#def_key "enter"
|
||||||
|
# run_action
|
||||||
|
#
|
||||||
|
#def_key "enter"
|
||||||
|
# play_item
|
||||||
|
#
|
||||||
|
#def_key "space"
|
||||||
|
# add_item_to_playlist
|
||||||
|
#
|
||||||
|
#def_key "space"
|
||||||
|
# toggle_lyrics_update_on_song_change
|
||||||
|
#
|
||||||
|
#def_key "space"
|
||||||
|
# toggle_visualization_type
|
||||||
|
#
|
||||||
|
#def_key "delete"
|
||||||
|
# delete_playlist_items
|
||||||
|
#
|
||||||
|
#def_key "delete"
|
||||||
|
# delete_browser_items
|
||||||
|
#
|
||||||
|
#def_key "delete"
|
||||||
|
# delete_stored_playlist
|
||||||
|
#
|
||||||
|
#def_key "right"
|
||||||
|
# next_column
|
||||||
|
#
|
||||||
|
#def_key "right"
|
||||||
|
# slave_screen
|
||||||
|
#
|
||||||
|
#def_key "right"
|
||||||
|
# volume_up
|
||||||
|
#
|
||||||
|
#def_key "+"
|
||||||
|
# volume_up
|
||||||
|
#
|
||||||
|
#def_key "left"
|
||||||
|
# previous_column
|
||||||
|
#
|
||||||
|
#def_key "left"
|
||||||
|
# master_screen
|
||||||
|
#
|
||||||
|
#def_key "left"
|
||||||
|
# volume_down
|
||||||
|
#
|
||||||
|
#def_key "-"
|
||||||
|
# volume_down
|
||||||
|
#
|
||||||
|
#def_key ":"
|
||||||
|
# execute_command
|
||||||
|
#
|
||||||
|
#def_key "tab"
|
||||||
|
# next_screen
|
||||||
|
#
|
||||||
|
#def_key "shift-tab"
|
||||||
|
# previous_screen
|
||||||
|
#
|
||||||
|
#def_key "f1"
|
||||||
|
# show_help
|
||||||
|
#
|
||||||
|
#def_key "1"
|
||||||
|
# show_playlist
|
||||||
|
#
|
||||||
|
#def_key "2"
|
||||||
|
# show_browser
|
||||||
|
#
|
||||||
|
#def_key "2"
|
||||||
|
# change_browse_mode
|
||||||
|
#
|
||||||
|
#def_key "3"
|
||||||
|
# show_search_engine
|
||||||
|
#
|
||||||
|
#def_key "3"
|
||||||
|
# reset_search_engine
|
||||||
|
#
|
||||||
|
#def_key "4"
|
||||||
|
# show_media_library
|
||||||
|
#
|
||||||
|
#def_key "4"
|
||||||
|
# toggle_media_library_columns_mode
|
||||||
|
#
|
||||||
|
#def_key "5"
|
||||||
|
# show_playlist_editor
|
||||||
|
#
|
||||||
|
#def_key "6"
|
||||||
|
# show_tag_editor
|
||||||
|
#
|
||||||
|
#def_key "7"
|
||||||
|
# show_outputs
|
||||||
|
#
|
||||||
|
#def_key "8"
|
||||||
|
# show_visualizer
|
||||||
|
#
|
||||||
|
#def_key "="
|
||||||
|
# show_clock
|
||||||
|
#
|
||||||
|
#def_key "@"
|
||||||
|
# show_server_info
|
||||||
|
#
|
||||||
|
#def_key "s"
|
||||||
|
# stop
|
||||||
|
#
|
||||||
|
#def_key "p"
|
||||||
|
# pause
|
||||||
|
#
|
||||||
|
#def_key ">"
|
||||||
|
# next
|
||||||
|
#
|
||||||
|
#def_key "<"
|
||||||
|
# previous
|
||||||
|
#
|
||||||
|
#def_key "ctrl-h"
|
||||||
|
# jump_to_parent_directory
|
||||||
|
#
|
||||||
|
#def_key "ctrl-h"
|
||||||
|
# replay_song
|
||||||
|
#
|
||||||
|
#def_key "backspace"
|
||||||
|
# jump_to_parent_directory
|
||||||
|
#
|
||||||
|
#def_key "backspace"
|
||||||
|
# replay_song
|
||||||
|
#
|
||||||
|
#def_key "f"
|
||||||
|
# seek_forward
|
||||||
|
#
|
||||||
|
#def_key "b"
|
||||||
|
# seek_backward
|
||||||
|
#
|
||||||
|
#def_key "r"
|
||||||
|
# toggle_repeat
|
||||||
|
#
|
||||||
|
#def_key "z"
|
||||||
|
# toggle_random
|
||||||
|
#
|
||||||
|
#def_key "y"
|
||||||
|
# save_tag_changes
|
||||||
|
#
|
||||||
|
#def_key "y"
|
||||||
|
# start_searching
|
||||||
|
#
|
||||||
|
#def_key "y"
|
||||||
|
# toggle_single
|
||||||
|
#
|
||||||
|
#def_key "R"
|
||||||
|
# toggle_consume
|
||||||
|
#
|
||||||
|
#def_key "Y"
|
||||||
|
# toggle_replay_gain_mode
|
||||||
|
#
|
||||||
|
#def_key "T"
|
||||||
|
# toggle_add_mode
|
||||||
|
#
|
||||||
|
#def_key "|"
|
||||||
|
# toggle_mouse
|
||||||
|
#
|
||||||
|
#def_key "#"
|
||||||
|
# toggle_bitrate_visibility
|
||||||
|
#
|
||||||
|
#def_key "Z"
|
||||||
|
# shuffle
|
||||||
|
#
|
||||||
|
#def_key "x"
|
||||||
|
# toggle_crossfade
|
||||||
|
#
|
||||||
|
#def_key "X"
|
||||||
|
# set_crossfade
|
||||||
|
#
|
||||||
|
#def_key "u"
|
||||||
|
# update_database
|
||||||
|
#
|
||||||
|
#def_key "ctrl-s"
|
||||||
|
# sort_playlist
|
||||||
|
#
|
||||||
|
#def_key "ctrl-s"
|
||||||
|
# toggle_browser_sort_mode
|
||||||
|
#
|
||||||
|
#def_key "ctrl-s"
|
||||||
|
# toggle_media_library_sort_mode
|
||||||
|
#
|
||||||
|
#def_key "ctrl-r"
|
||||||
|
# reverse_playlist
|
||||||
|
#
|
||||||
|
#def_key "ctrl-f"
|
||||||
|
# apply_filter
|
||||||
|
#
|
||||||
|
#def_key "ctrl-_"
|
||||||
|
# select_found_items
|
||||||
|
#
|
||||||
|
#def_key "/"
|
||||||
|
# find
|
||||||
|
#
|
||||||
|
#def_key "/"
|
||||||
|
# find_item_forward
|
||||||
|
#
|
||||||
|
#def_key "?"
|
||||||
|
# find
|
||||||
|
#
|
||||||
|
#def_key "?"
|
||||||
|
# find_item_backward
|
||||||
|
#
|
||||||
|
#def_key "."
|
||||||
|
# next_found_item
|
||||||
|
#
|
||||||
|
#def_key ","
|
||||||
|
# previous_found_item
|
||||||
|
#
|
||||||
|
#def_key "w"
|
||||||
|
# toggle_find_mode
|
||||||
|
#
|
||||||
|
#def_key "e"
|
||||||
|
# edit_song
|
||||||
|
#
|
||||||
|
#def_key "e"
|
||||||
|
# edit_library_tag
|
||||||
|
#
|
||||||
|
#def_key "e"
|
||||||
|
# edit_library_album
|
||||||
|
#
|
||||||
|
#def_key "e"
|
||||||
|
# edit_directory_name
|
||||||
|
#
|
||||||
|
#def_key "e"
|
||||||
|
# edit_playlist_name
|
||||||
|
#
|
||||||
|
#def_key "e"
|
||||||
|
# edit_lyrics
|
||||||
|
#
|
||||||
|
#def_key "i"
|
||||||
|
# show_song_info
|
||||||
|
#
|
||||||
|
#def_key "I"
|
||||||
|
# show_artist_info
|
||||||
|
#
|
||||||
|
#def_key "g"
|
||||||
|
# jump_to_position_in_song
|
||||||
|
#
|
||||||
|
#def_key "l"
|
||||||
|
# show_lyrics
|
||||||
|
#
|
||||||
|
#def_key "ctrl-v"
|
||||||
|
# select_range
|
||||||
|
#
|
||||||
|
#def_key "v"
|
||||||
|
# reverse_selection
|
||||||
|
#
|
||||||
|
#def_key "V"
|
||||||
|
# remove_selection
|
||||||
|
#
|
||||||
|
#def_key "B"
|
||||||
|
# select_album
|
||||||
|
#
|
||||||
|
#def_key "a"
|
||||||
|
# add_selected_items
|
||||||
|
#
|
||||||
|
#def_key "c"
|
||||||
|
# clear_playlist
|
||||||
|
#
|
||||||
|
#def_key "c"
|
||||||
|
# clear_main_playlist
|
||||||
|
#
|
||||||
|
#def_key "C"
|
||||||
|
# crop_playlist
|
||||||
|
#
|
||||||
|
#def_key "C"
|
||||||
|
# crop_main_playlist
|
||||||
|
#
|
||||||
|
#def_key "m"
|
||||||
|
# move_sort_order_up
|
||||||
|
#
|
||||||
|
#def_key "m"
|
||||||
|
# move_selected_items_up
|
||||||
|
#
|
||||||
|
#def_key "n"
|
||||||
|
# move_sort_order_down
|
||||||
|
#
|
||||||
|
#def_key "n"
|
||||||
|
# move_selected_items_down
|
||||||
|
#
|
||||||
|
#def_key "M"
|
||||||
|
# move_selected_items_to
|
||||||
|
#
|
||||||
|
#def_key "A"
|
||||||
|
# add
|
||||||
|
#
|
||||||
|
#def_key "S"
|
||||||
|
# save_playlist
|
||||||
|
#
|
||||||
|
#def_key "o"
|
||||||
|
# jump_to_playing_song
|
||||||
|
#
|
||||||
|
#def_key "G"
|
||||||
|
# jump_to_browser
|
||||||
|
#
|
||||||
|
#def_key "G"
|
||||||
|
# jump_to_playlist_editor
|
||||||
|
#
|
||||||
|
#def_key "~"
|
||||||
|
# jump_to_media_library
|
||||||
|
#
|
||||||
|
#def_key "E"
|
||||||
|
# jump_to_tag_editor
|
||||||
|
#
|
||||||
|
#def_key "U"
|
||||||
|
# toggle_playing_song_centering
|
||||||
|
#
|
||||||
|
#def_key "P"
|
||||||
|
# toggle_display_mode
|
||||||
|
#
|
||||||
|
#def_key "\\"
|
||||||
|
# toggle_interface
|
||||||
|
#
|
||||||
|
#def_key "!"
|
||||||
|
# toggle_separators_between_albums
|
||||||
|
#
|
||||||
|
#def_key "L"
|
||||||
|
# toggle_lyrics_fetcher
|
||||||
|
#
|
||||||
|
#def_key "F"
|
||||||
|
# fetch_lyrics_in_background
|
||||||
|
#
|
||||||
|
#def_key "alt-l"
|
||||||
|
# toggle_fetching_lyrics_in_background
|
||||||
|
#
|
||||||
|
#def_key "ctrl-l"
|
||||||
|
# toggle_screen_lock
|
||||||
|
#
|
||||||
|
#def_key "`"
|
||||||
|
# toggle_library_tag_type
|
||||||
|
#
|
||||||
|
#def_key "`"
|
||||||
|
# refetch_lyrics
|
||||||
|
#
|
||||||
|
#def_key "`"
|
||||||
|
# add_random_items
|
||||||
|
#
|
||||||
|
#def_key "ctrl-p"
|
||||||
|
# set_selected_items_priority
|
||||||
|
#
|
||||||
|
#def_key "q"
|
||||||
|
# quit
|
||||||
|
#
|
||||||
|
#
|
||||||
|
def_key "f"
|
||||||
|
find
|
||||||
|
def_key "f"
|
||||||
|
find_item_forward
|
||||||
|
|
||||||
|
def_key "+"
|
||||||
|
show_clock
|
||||||
|
def_key "="
|
||||||
|
volume_up
|
||||||
|
|
||||||
|
def_key "j"
|
||||||
|
scroll_down
|
||||||
|
def_key "k"
|
||||||
|
scroll_up
|
||||||
|
|
||||||
|
def_key "ctrl-u"
|
||||||
|
page_up
|
||||||
|
#push_characters "kkkkkkkkkkkkkkk"
|
||||||
|
def_key "ctrl-d"
|
||||||
|
page_down
|
||||||
|
#push_characters "jjjjjjjjjjjjjjj"
|
||||||
|
def_key "u"
|
||||||
|
page_up
|
||||||
|
#push_characters "kkkkkkkkkkkkkkk"
|
||||||
|
def_key "d"
|
||||||
|
page_down
|
||||||
|
#push_characters "jjjjjjjjjjjjjjj"
|
||||||
|
def_key "h"
|
||||||
|
previous_column
|
||||||
|
def_key "l"
|
||||||
|
next_column
|
||||||
|
|
||||||
|
def_key "."
|
||||||
|
show_lyrics
|
||||||
|
|
||||||
|
def_key "n"
|
||||||
|
next_found_item
|
||||||
|
def_key "N"
|
||||||
|
previous_found_item
|
||||||
|
|
||||||
|
# not used but bound
|
||||||
|
def_key "J"
|
||||||
|
move_sort_order_down
|
||||||
|
def_key "K"
|
||||||
|
move_sort_order_up
|
||||||
|
def_key "h"
|
||||||
|
jump_to_parent_directory
|
||||||
|
def_key "l"
|
||||||
|
enter_directory
|
||||||
|
def_key "l"
|
||||||
|
run_action
|
||||||
|
def_key "l"
|
||||||
|
play_item
|
||||||
|
def_key "m"
|
||||||
|
show_media_library
|
||||||
|
def_key "m"
|
||||||
|
toggle_media_library_columns_mode
|
||||||
|
def_key "t"
|
||||||
|
show_tag_editor
|
||||||
|
def_key "v"
|
||||||
|
show_visualizer
|
||||||
|
def_key "G"
|
||||||
|
move_end
|
||||||
|
def_key "g"
|
||||||
|
move_home
|
||||||
|
#jump_to_position_in_song
|
||||||
|
def_key "U"
|
||||||
|
update_database
|
545
.ncmpcpp/config
Normal file
545
.ncmpcpp/config
Normal file
|
@ -0,0 +1,545 @@
|
||||||
|
##############################################################################
|
||||||
|
## This is the example configuration file. Copy it to $HOME/.ncmpcpp/config ##
|
||||||
|
## or $XDG_CONFIG_HOME/ncmpcpp/config and set up your preferences. ##
|
||||||
|
##############################################################################
|
||||||
|
#
|
||||||
|
##### directories ######
|
||||||
|
##
|
||||||
|
## Directory for storing ncmpcpp related files. Changing it is useful if you
|
||||||
|
## want to store everything somewhere else and provide command line setting for
|
||||||
|
## alternative location to config file which defines that while launching
|
||||||
|
## ncmpcpp.
|
||||||
|
##
|
||||||
|
#
|
||||||
|
#ncmpcpp_directory = ~/.ncmpcpp
|
||||||
|
#
|
||||||
|
##
|
||||||
|
## Directory for storing downloaded lyrics. It defaults to ~/.lyrics since other
|
||||||
|
## MPD clients (eg. ncmpc) also use that location.
|
||||||
|
##
|
||||||
|
#
|
||||||
|
#lyrics_directory = ~/.lyrics
|
||||||
|
#
|
||||||
|
##### connection settings #####
|
||||||
|
#
|
||||||
|
#mpd_host = localhost
|
||||||
|
#
|
||||||
|
#mpd_port = 6600
|
||||||
|
#
|
||||||
|
#mpd_connection_timeout = 5
|
||||||
|
#
|
||||||
|
## Needed for tag editor and file operations to work.
|
||||||
|
##
|
||||||
|
mpd_music_dir = "~/Music"
|
||||||
|
#
|
||||||
|
#mpd_crossfade_time = 5
|
||||||
|
#
|
||||||
|
##### music visualizer #####
|
||||||
|
##
|
||||||
|
## Note: In order to make music visualizer work you'll need to use mpd fifo
|
||||||
|
## output, whose format parameter has to be set to 44100:16:1 for mono
|
||||||
|
## visualization or 44100:16:2 for stereo visualization. Example configuration
|
||||||
|
## (it has to be put into mpd.conf):
|
||||||
|
##
|
||||||
|
## audio_output {
|
||||||
|
## type "fifo"
|
||||||
|
## name "Visualizer feed"
|
||||||
|
## path "/tmp/mpd.fifo"
|
||||||
|
## format "44100:16:2"
|
||||||
|
## }
|
||||||
|
##
|
||||||
|
#
|
||||||
|
#visualizer_fifo_path = /tmp/mpd.fifo
|
||||||
|
#
|
||||||
|
##
|
||||||
|
## Note: Below parameter is needed for ncmpcpp to determine which output
|
||||||
|
## provides data for visualizer and thus allow syncing between visualization and
|
||||||
|
## sound as currently there are some problems with it.
|
||||||
|
##
|
||||||
|
#
|
||||||
|
#visualizer_output_name = Visualizer feed
|
||||||
|
#
|
||||||
|
##
|
||||||
|
## If you set format to 44100:16:2, make it 'yes'.
|
||||||
|
##
|
||||||
|
#visualizer_in_stereo = yes
|
||||||
|
#
|
||||||
|
##
|
||||||
|
## Note: Below parameter defines how often ncmpcpp has to "synchronize"
|
||||||
|
## visualizer and audio outputs. 30 seconds is optimal value, but if you
|
||||||
|
## experience synchronization problems, set it to lower value. Keep in mind
|
||||||
|
## that sane values start with >=10.
|
||||||
|
##
|
||||||
|
#
|
||||||
|
#visualizer_sync_interval = 30
|
||||||
|
#
|
||||||
|
##
|
||||||
|
## Note: To enable spectrum frequency visualization you need to compile ncmpcpp
|
||||||
|
## with fftw3 support.
|
||||||
|
##
|
||||||
|
#
|
||||||
|
## Available values: spectrum, wave, wave_filled, ellipse.
|
||||||
|
##
|
||||||
|
visualizer_type = spectrum
|
||||||
|
#
|
||||||
|
#visualizer_look = ●卐
|
||||||
|
#visualizer_look = 卐
|
||||||
|
#
|
||||||
|
#visualizer_color = blue, cyan, green, yellow, magenta, red
|
||||||
|
#
|
||||||
|
## Alternative subset of 256 colors for terminals that support it.
|
||||||
|
##
|
||||||
|
#visualizer_color = 41, 83, 119, 155, 185, 215, 209, 203, 197, 161
|
||||||
|
#
|
||||||
|
##### system encoding #####
|
||||||
|
##
|
||||||
|
## ncmpcpp should detect your charset encoding but if it failed to do so, you
|
||||||
|
## can specify charset encoding you are using here.
|
||||||
|
##
|
||||||
|
## Note: You can see whether your ncmpcpp build supports charset detection by
|
||||||
|
## checking output of `ncmpcpp --version`.
|
||||||
|
##
|
||||||
|
## Note: Since MPD uses UTF-8 by default, setting this option makes sense only
|
||||||
|
## if your encoding is different.
|
||||||
|
##
|
||||||
|
#
|
||||||
|
#system_encoding = ""
|
||||||
|
#
|
||||||
|
##### delays #####
|
||||||
|
#
|
||||||
|
## Time of inactivity (in seconds) after playlist highlighting will be disabled
|
||||||
|
## (0 = always on).
|
||||||
|
##
|
||||||
|
#playlist_disable_highlight_delay = 5
|
||||||
|
#
|
||||||
|
## Defines how long messages are supposed to be visible.
|
||||||
|
##
|
||||||
|
message_delay_time = 1
|
||||||
|
#
|
||||||
|
##### song format #####
|
||||||
|
##
|
||||||
|
## For a song format you can use:
|
||||||
|
##
|
||||||
|
## %l - length
|
||||||
|
## %f - filename
|
||||||
|
## %D - directory
|
||||||
|
## %a - artist
|
||||||
|
## %A - album artist
|
||||||
|
## %t - title
|
||||||
|
## %b - album
|
||||||
|
## %y - date
|
||||||
|
## %n - track number (01/12 -> 01)
|
||||||
|
## %N - full track info (01/12 -> 01/12)
|
||||||
|
## %g - genre
|
||||||
|
## %c - composer
|
||||||
|
## %p - performer
|
||||||
|
## %d - disc
|
||||||
|
## %C - comment
|
||||||
|
## %P - priority
|
||||||
|
## $R - begin right alignment
|
||||||
|
##
|
||||||
|
## If you want to make sure that a part of the format is displayed only when
|
||||||
|
## certain tags are present, you can archieve it by grouping them with brackets,
|
||||||
|
## e.g. '{%a - %t}' will be evaluated to 'ARTIST - TITLE' if both tags are
|
||||||
|
## present or '' otherwise. It is also possible to define a list of
|
||||||
|
## alternatives by providing several groups and separating them with '|',
|
||||||
|
## e.g. '{%t}|{%f}' will be evaluated to 'TITLE' or 'FILENAME' if the former is
|
||||||
|
## not present.
|
||||||
|
##
|
||||||
|
## Note: If you want to set limit on maximal length of a tag, just put the
|
||||||
|
## appropriate number between % and character that defines tag type, e.g. to
|
||||||
|
## make album take max. 20 terminal cells, use '%20b'.
|
||||||
|
##
|
||||||
|
## In addition, formats support markers used for text attributes. They are
|
||||||
|
## followed by character '$'. After that you can put:
|
||||||
|
##
|
||||||
|
## - 0 - default window color (discards all other colors)
|
||||||
|
## - 1 - black
|
||||||
|
## - 2 - red
|
||||||
|
## - 3 - green
|
||||||
|
## - 4 - yellow
|
||||||
|
## - 5 - blue
|
||||||
|
## - 6 - magenta
|
||||||
|
## - 7 - cyan
|
||||||
|
## - 8 - white
|
||||||
|
## - 9 - end of current color
|
||||||
|
## - b - bold text
|
||||||
|
## - u - underline text
|
||||||
|
## - r - reverse colors
|
||||||
|
## - a - use alternative character set
|
||||||
|
##
|
||||||
|
## If you don't want to use a non-color attribute anymore, just put it again,
|
||||||
|
## but this time insert character '/' between '$' and attribute character,
|
||||||
|
## e.g. {$b%t$/b}|{$r%f$/r} will display bolded title tag or filename with
|
||||||
|
## reversed colors.
|
||||||
|
##
|
||||||
|
## If you want to use 256 colors and/or background colors in formats (the naming
|
||||||
|
## scheme is described below in section about color definitions), it can be done
|
||||||
|
## with the syntax $(COLOR), e.g. to set the artist tag to one of the
|
||||||
|
## non-standard colors and make it have yellow background, you need to write
|
||||||
|
## $(197_yellow)%a$(end). Note that for standard colors this is interchangable
|
||||||
|
## with attributes listed above.
|
||||||
|
##
|
||||||
|
## Note: colors can be nested.
|
||||||
|
##
|
||||||
|
#
|
||||||
|
song_list_format = {$4%a - }{%t}|{$8%f$9}$R{$3(%l)$9}
|
||||||
|
#
|
||||||
|
song_status_format = $b{{$8"%t"}} $3by {$4%a{ $3in $7%b{ (%y)}} $3}|{$8%f}
|
||||||
|
#
|
||||||
|
song_library_format = {%n - }{%t}|{%f}
|
||||||
|
#
|
||||||
|
alternative_header_first_line_format = $b$1$aqqu$/a$9 {%t}|{%f} $1$atqq$/a$9$/b
|
||||||
|
#
|
||||||
|
alternative_header_second_line_format = {{$4$b%a$/b$9}{ - $7%b$9}{ ($4%y$9)}}|{%D}
|
||||||
|
#
|
||||||
|
current_item_prefix = $(cyan)$r$b
|
||||||
|
#
|
||||||
|
current_item_suffix = $/r$(end)$/b
|
||||||
|
#
|
||||||
|
current_item_inactive_column_prefix = $(magenta)$r
|
||||||
|
#
|
||||||
|
current_item_inactive_column_suffix = $/r$(end)
|
||||||
|
#
|
||||||
|
#now_playing_prefix = $b
|
||||||
|
#
|
||||||
|
#now_playing_suffix = $/b
|
||||||
|
#
|
||||||
|
#browser_playlist_prefix = "$2playlist$9 "
|
||||||
|
#
|
||||||
|
#selected_item_prefix = $6
|
||||||
|
#
|
||||||
|
#selected_item_suffix = $9
|
||||||
|
#
|
||||||
|
#modified_item_prefix = $3> $9
|
||||||
|
#
|
||||||
|
##
|
||||||
|
## Note: attributes are not supported for the following variables.
|
||||||
|
##
|
||||||
|
#song_window_title_format = {%a - }{%t}|{%f}
|
||||||
|
##
|
||||||
|
## Note: Below variables are used for sorting songs in browser. The sort mode
|
||||||
|
## determines how songs are sorted, and can be used in combination with a sort
|
||||||
|
## format to specify a custom sorting format. Available values for
|
||||||
|
## browser_sort_mode are "name", "mtime", "format" and "noop".
|
||||||
|
##
|
||||||
|
#
|
||||||
|
#browser_sort_mode = name
|
||||||
|
#
|
||||||
|
#browser_sort_format = {%a - }{%t}|{%f} {(%l)}
|
||||||
|
#
|
||||||
|
##### columns settings #####
|
||||||
|
##
|
||||||
|
## syntax of song columns list format is "column column etc."
|
||||||
|
##
|
||||||
|
## - syntax for each column is:
|
||||||
|
##
|
||||||
|
## (width of the column)[color of the column]{displayed tag}
|
||||||
|
##
|
||||||
|
## Note: Width is by default in %, if you want a column to have fixed size, add
|
||||||
|
## 'f' after the value, e.g. (10)[white]{a} will be the column that take 10% of
|
||||||
|
## screen (so the real width will depend on actual screen size), whereas
|
||||||
|
## (10f)[white]{a} will take 10 terminal cells, no matter how wide the screen
|
||||||
|
## is.
|
||||||
|
##
|
||||||
|
## - color is optional (if you want the default one, leave the field empty).
|
||||||
|
##
|
||||||
|
## Note: You can give a column additional attributes by putting appropriate
|
||||||
|
## character after displayed tag character. Available attributes are:
|
||||||
|
##
|
||||||
|
## - r - column will be right aligned
|
||||||
|
## - E - if tag is empty, empty tag marker won't be displayed
|
||||||
|
##
|
||||||
|
## You can also:
|
||||||
|
##
|
||||||
|
## - give a column custom name by putting it after attributes, separated with
|
||||||
|
## character ':', e.g. {lr:Length} gives you right aligned column of lengths
|
||||||
|
## named "Length".
|
||||||
|
##
|
||||||
|
## - define sequence of tags, that have to be displayed in case predecessor is
|
||||||
|
## empty in a way similar to the one in classic song format, i.e. using '|'
|
||||||
|
## character, e.g. {a|c|p:Owner} creates column named "Owner" that tries to
|
||||||
|
## display artist tag and then composer and performer if previous ones are not
|
||||||
|
## available.
|
||||||
|
##
|
||||||
|
#
|
||||||
|
#song_columns_list_format = (20)[]{a} (6f)[green]{NE} (50)[white]{t|f:Title} (20)[cyan]{b} (7f)[magenta]{l}
|
||||||
|
#
|
||||||
|
##### various settings #####
|
||||||
|
#
|
||||||
|
##
|
||||||
|
## Note: Custom command that will be executed each time song changes. Useful for
|
||||||
|
## notifications etc.
|
||||||
|
##
|
||||||
|
#execute_on_song_change = ""
|
||||||
|
#
|
||||||
|
##
|
||||||
|
## Note: Custom command that will be executed each time player state
|
||||||
|
## changes. The environment variable MPD_PLAYER_STATE is set to the current
|
||||||
|
## state (either unknown, play, pause, or stop) for its duration.
|
||||||
|
##
|
||||||
|
#
|
||||||
|
#execute_on_player_state_change = ""
|
||||||
|
#
|
||||||
|
#playlist_show_mpd_host = no
|
||||||
|
#
|
||||||
|
#playlist_show_remaining_time = no
|
||||||
|
#
|
||||||
|
#playlist_shorten_total_times = no
|
||||||
|
#
|
||||||
|
#playlist_separate_albums = no
|
||||||
|
#
|
||||||
|
##
|
||||||
|
## Note: Possible display modes: classic, columns.
|
||||||
|
##
|
||||||
|
#playlist_display_mode = columns
|
||||||
|
#
|
||||||
|
browser_display_mode = columns
|
||||||
|
#
|
||||||
|
#search_engine_display_mode = classic
|
||||||
|
#
|
||||||
|
#playlist_editor_display_mode = classic
|
||||||
|
#
|
||||||
|
#discard_colors_if_item_is_selected = yes
|
||||||
|
#
|
||||||
|
#show_duplicate_tags = true
|
||||||
|
#
|
||||||
|
#incremental_seeking = yes
|
||||||
|
#
|
||||||
|
#seek_time = 1
|
||||||
|
#
|
||||||
|
#volume_change_step = 2
|
||||||
|
#
|
||||||
|
#autocenter_mode = no
|
||||||
|
#
|
||||||
|
#centered_cursor = no
|
||||||
|
#
|
||||||
|
##
|
||||||
|
## Note: You can specify third character which will be used to build 'empty'
|
||||||
|
## part of progressbar.
|
||||||
|
##
|
||||||
|
progressbar_look = ->
|
||||||
|
#
|
||||||
|
## Available values: database, playlist.
|
||||||
|
##
|
||||||
|
#default_place_to_search_in = database
|
||||||
|
#
|
||||||
|
## Available values: classic, alternative.
|
||||||
|
##
|
||||||
|
#user_interface = classic
|
||||||
|
#
|
||||||
|
#data_fetching_delay = yes
|
||||||
|
#
|
||||||
|
## Available values: artist, album_artist, date, genre, composer, performer.
|
||||||
|
##
|
||||||
|
media_library_primary_tag = album_artist
|
||||||
|
#
|
||||||
|
media_library_albums_split_by_date = no
|
||||||
|
#
|
||||||
|
## Available values: wrapped, normal.
|
||||||
|
##
|
||||||
|
#default_find_mode = wrapped
|
||||||
|
#
|
||||||
|
#default_tag_editor_pattern = %n - %t
|
||||||
|
#
|
||||||
|
#header_visibility = yes
|
||||||
|
#
|
||||||
|
#statusbar_visibility = yes
|
||||||
|
#
|
||||||
|
#titles_visibility = yes
|
||||||
|
#
|
||||||
|
#header_text_scrolling = yes
|
||||||
|
#
|
||||||
|
#cyclic_scrolling = no
|
||||||
|
#
|
||||||
|
#lines_scrolled = 2
|
||||||
|
#
|
||||||
|
#lyrics_fetchers = lyricwiki, azlyrics, genius, sing365, lyricsmania, metrolyrics, justsomelyrics, jahlyrics, plyrics, tekstowo, internet
|
||||||
|
#
|
||||||
|
#follow_now_playing_lyrics = no
|
||||||
|
#
|
||||||
|
#fetch_lyrics_for_current_song_in_background = no
|
||||||
|
#
|
||||||
|
#store_lyrics_in_song_dir = no
|
||||||
|
#
|
||||||
|
#generate_win32_compatible_filenames = yes
|
||||||
|
#
|
||||||
|
#allow_for_physical_item_deletion = no
|
||||||
|
#
|
||||||
|
##
|
||||||
|
## Note: If you set this variable, ncmpcpp will try to get info from last.fm in
|
||||||
|
## language you set and if it fails, it will fall back to english. Otherwise it
|
||||||
|
## will use english the first time.
|
||||||
|
##
|
||||||
|
## Note: Language has to be expressed as an ISO 639 alpha-2 code.
|
||||||
|
##
|
||||||
|
#lastfm_preferred_language = en
|
||||||
|
#
|
||||||
|
#space_add_mode = add_remove
|
||||||
|
#
|
||||||
|
#show_hidden_files_in_local_browser = no
|
||||||
|
#
|
||||||
|
##
|
||||||
|
## How shall screen switcher work?
|
||||||
|
##
|
||||||
|
## - "previous" - switch between the current and previous screen.
|
||||||
|
## - "screen1,...,screenN" - switch between given sequence of screens.
|
||||||
|
##
|
||||||
|
## Screens available for use: help, playlist, browser, search_engine,
|
||||||
|
## media_library, playlist_editor, tag_editor, outputs, visualizer, clock,
|
||||||
|
## lyrics, last_fm.
|
||||||
|
##
|
||||||
|
#screen_switcher_mode = playlist, browser
|
||||||
|
#
|
||||||
|
##
|
||||||
|
## Note: You can define startup screen by choosing screen from the list above.
|
||||||
|
##
|
||||||
|
startup_screen = media_library
|
||||||
|
#
|
||||||
|
##
|
||||||
|
## Note: You can define startup slave screen by choosing screen from the list
|
||||||
|
## above or an empty value for no slave screen.
|
||||||
|
##
|
||||||
|
#startup_slave_screen = ""
|
||||||
|
#
|
||||||
|
#startup_slave_screen_focus = no
|
||||||
|
#
|
||||||
|
##
|
||||||
|
## Default width of locked screen (in %). Acceptable values are from 20 to 80.
|
||||||
|
##
|
||||||
|
#
|
||||||
|
#locked_screen_width_part = 50
|
||||||
|
#
|
||||||
|
#ask_for_locked_screen_width_part = yes
|
||||||
|
#
|
||||||
|
#jump_to_now_playing_song_at_start = yes
|
||||||
|
#
|
||||||
|
#ask_before_clearing_playlists = yes
|
||||||
|
#
|
||||||
|
#clock_display_seconds = no
|
||||||
|
#
|
||||||
|
display_volume_level = no
|
||||||
|
#
|
||||||
|
#display_bitrate = no
|
||||||
|
#
|
||||||
|
#display_remaining_time = no
|
||||||
|
#
|
||||||
|
## Available values: none, basic, extended, perl.
|
||||||
|
##
|
||||||
|
#regular_expressions = perl
|
||||||
|
#
|
||||||
|
##
|
||||||
|
## Note: if below is enabled, ncmpcpp will ignore leading "The" word while
|
||||||
|
## sorting items in browser, tags in media library, etc.
|
||||||
|
##
|
||||||
|
ignore_leading_the = yes
|
||||||
|
#
|
||||||
|
##
|
||||||
|
## Note: if below is enabled, ncmpcpp will ignore diacritics while searching and
|
||||||
|
## filtering lists. This takes an effect only if boost was compiled with ICU
|
||||||
|
## support.
|
||||||
|
##
|
||||||
|
#ignore_diacritics = no
|
||||||
|
#
|
||||||
|
#block_search_constraints_change_if_items_found = yes
|
||||||
|
#
|
||||||
|
#mouse_support = yes
|
||||||
|
#
|
||||||
|
#mouse_list_scroll_whole_page = yes
|
||||||
|
#
|
||||||
|
#empty_tag_marker = <empty>
|
||||||
|
#
|
||||||
|
#tags_separator = " | "
|
||||||
|
#
|
||||||
|
#tag_editor_extended_numeration = no
|
||||||
|
#
|
||||||
|
#media_library_sort_by_mtime = no
|
||||||
|
#
|
||||||
|
#enable_window_title = yes
|
||||||
|
#
|
||||||
|
##
|
||||||
|
## Note: You can choose default search mode for search engine. Available modes
|
||||||
|
## are:
|
||||||
|
##
|
||||||
|
## - 1 - use mpd built-in searching (no regexes, pattern matching)
|
||||||
|
##
|
||||||
|
## - 2 - use ncmpcpp searching (pattern matching with support for regexes, but
|
||||||
|
## if your mpd is on a remote machine, downloading big database to process
|
||||||
|
## it can take a while
|
||||||
|
##
|
||||||
|
## - 3 - match only exact values (this mode uses mpd function for searching in
|
||||||
|
## database and local one for searching in current playlist)
|
||||||
|
##
|
||||||
|
#
|
||||||
|
#search_engine_default_search_mode = 1
|
||||||
|
#
|
||||||
|
external_editor = vim
|
||||||
|
#
|
||||||
|
## Note: set to yes if external editor is a console application.
|
||||||
|
##
|
||||||
|
use_console_editor = yes
|
||||||
|
#
|
||||||
|
##### colors definitions #####
|
||||||
|
##
|
||||||
|
## It is possible to set a background color by setting a color value
|
||||||
|
## "<foreground>_<background>", e.g. red_black will set foregound color to red
|
||||||
|
## and background color to black.
|
||||||
|
##
|
||||||
|
## In addition, for terminals that support 256 colors it is possible to set one
|
||||||
|
## of them by using a number in range [1, 256] instead of color name,
|
||||||
|
## e.g. numerical value corresponding to red_black is 2_1. To find out if the
|
||||||
|
## terminal supports 256 colors, run ncmpcpp and check out the bottom of the
|
||||||
|
## help screen for list of available colors and their numerical values.
|
||||||
|
##
|
||||||
|
## What is more, there are two special values for the background color:
|
||||||
|
## "transparent" and "current". The first one explicitly sets the background to
|
||||||
|
## be transparent, while the second one allows you to preserve current
|
||||||
|
## background color and change only the foreground one. It's used implicitly
|
||||||
|
## when background color is not specified.
|
||||||
|
##
|
||||||
|
## Moreover, it is possible to attach format information to selected color
|
||||||
|
## variables by appending to their end a colon followed by one or more format
|
||||||
|
## flags, e.g. black:b or red:ur. The following variables support this syntax:
|
||||||
|
## visualizer_color, color1, color2, empty_tag_color, volume_color,
|
||||||
|
## state_line_color, state_flags_color, progressbar_color,
|
||||||
|
## progressbar_elapsed_color, player_state_color, statusbar_time_color,
|
||||||
|
## alternative_ui_separator_color.
|
||||||
|
##
|
||||||
|
## Note: due to technical limitations of older ncurses version, if 256 colors
|
||||||
|
## are used there is a possibility that you'll be able to use only colors with
|
||||||
|
## transparent background.
|
||||||
|
#
|
||||||
|
#colors_enabled = yes
|
||||||
|
#
|
||||||
|
empty_tag_color = magenta
|
||||||
|
#
|
||||||
|
#header_window_color = magenta
|
||||||
|
#
|
||||||
|
#volume_color = default
|
||||||
|
#
|
||||||
|
#state_line_color = default
|
||||||
|
#
|
||||||
|
#state_flags_color = default:b
|
||||||
|
#
|
||||||
|
#main_window_color = white
|
||||||
|
#
|
||||||
|
#color1 = white
|
||||||
|
#
|
||||||
|
#color2 = green
|
||||||
|
#
|
||||||
|
progressbar_color = black:b
|
||||||
|
#
|
||||||
|
progressbar_elapsed_color = blue:b
|
||||||
|
#
|
||||||
|
statusbar_color = red
|
||||||
|
#
|
||||||
|
statusbar_time_color = cyan:b
|
||||||
|
#
|
||||||
|
#player_state_color = default:b
|
||||||
|
#
|
||||||
|
#alternative_ui_separator_color = black:b
|
||||||
|
#
|
||||||
|
#window_border_color = green
|
||||||
|
#
|
||||||
|
#active_window_border = red
|
||||||
|
#
|
32
.newsboat/config
Normal file
32
.newsboat/config
Normal file
|
@ -0,0 +1,32 @@
|
||||||
|
auto-reload yes
|
||||||
|
|
||||||
|
external-url-viewer "urlview"
|
||||||
|
|
||||||
|
bind-key j down
|
||||||
|
bind-key k up
|
||||||
|
bind-key j next articlelist
|
||||||
|
bind-key k prev articlelist
|
||||||
|
bind-key J next-feed articlelist
|
||||||
|
bind-key K prev-feed articlelist
|
||||||
|
bind-key G end
|
||||||
|
bind-key g home
|
||||||
|
bind-key d pagedown
|
||||||
|
bind-key u pageup
|
||||||
|
bind-key l open
|
||||||
|
bind-key h quit
|
||||||
|
bind-key n next-unread
|
||||||
|
bind-key N prev-unread
|
||||||
|
bind-key D pb-download
|
||||||
|
bind-key U show-urls
|
||||||
|
|
||||||
|
color listnormal cyan default
|
||||||
|
color listfocus black yellow standout bold
|
||||||
|
color listnormal_unread blue default
|
||||||
|
color listfocus_unread yellow default bold
|
||||||
|
color info red black bold
|
||||||
|
color article cyan default
|
||||||
|
|
||||||
|
|
||||||
|
browser webview
|
||||||
|
macro w open-in-browser
|
||||||
|
macro v set browser "i3 exec mpv"; open-in-browser ; set browser $BROWSER
|
1
.newsboat/urls
Normal file
1
.newsboat/urls
Normal file
|
@ -0,0 +1 @@
|
||||||
|
http://lukesmith.xyz/rss.xml
|
43
.offlineimaprc
Normal file
43
.offlineimaprc
Normal file
|
@ -0,0 +1,43 @@
|
||||||
|
# vim filetype=config
|
||||||
|
# Here are settings for all accounts.
|
||||||
|
[general]
|
||||||
|
accounts = gmail, personal
|
||||||
|
starttls = yes
|
||||||
|
ssl = yes
|
||||||
|
autorefresh = 1
|
||||||
|
|
||||||
|
|
||||||
|
# Here's an example Gmail account, just add in a username and password to use your own.
|
||||||
|
[Account gmail]
|
||||||
|
|
||||||
|
localrepository = gmail-local
|
||||||
|
remoterepository = gmail-remote
|
||||||
|
|
||||||
|
[Repository gmail-remote]
|
||||||
|
type = Gmail
|
||||||
|
remoteuser = YOURNAME@gmail.com
|
||||||
|
remotepass = $PASSWORD
|
||||||
|
#Note that the line below will not sync Gmail's redundant "All Mail" box. You can add other inboxes here you don't want to sync.
|
||||||
|
folderfilter = lambda foldername: foldername not in ['[Gmail]/All Mail']
|
||||||
|
sslcacertfile = /etc/ssl/certs/ca-certificates.crt
|
||||||
|
|
||||||
|
[Repository gmail-local]
|
||||||
|
type = Maildir
|
||||||
|
localfolders = ~/.Mail/Gmail
|
||||||
|
|
||||||
|
# Here's an other more general example. Add your username, password and IMAP server information, which you can look this up on your email host's website.
|
||||||
|
[Account personal]
|
||||||
|
|
||||||
|
localrepository = personal-local
|
||||||
|
remoterepository = personal-remote
|
||||||
|
|
||||||
|
[Repository personal-remote]
|
||||||
|
type = IMAP
|
||||||
|
remoteuser = USER@DOMAIN.COM
|
||||||
|
remotepass = $PASSWORD
|
||||||
|
remotehost = SERVER-ADDRESS
|
||||||
|
sslcacertfile = /etc/ssl/certs/ca-certificates.crt
|
||||||
|
|
||||||
|
[Repository personal-local]
|
||||||
|
type = Maildir
|
||||||
|
localfolders = ~/.Mail/Personal
|
177
.tmux.conf
Normal file
177
.tmux.conf
Normal file
|
@ -0,0 +1,177 @@
|
||||||
|
##############################
|
||||||
|
# _
|
||||||
|
# | |_ _ __ ___ _ ___ __
|
||||||
|
# | __| '_ ` _ \| | | \ \/ /
|
||||||
|
# | |_| | | | | | |_| |> <
|
||||||
|
# \__|_| |_| |_|\__,_/_/\_\
|
||||||
|
#
|
||||||
|
#############################
|
||||||
|
#
|
||||||
|
# COPY AND PASTE
|
||||||
|
# http://robots.thoughtbot.com/tmux-copy-paste-on-os-x-a-better-future
|
||||||
|
#
|
||||||
|
# Use vim keybindings in copy mode
|
||||||
|
setw -g mode-keys vi
|
||||||
|
|
||||||
|
# Setup 'v' to begin selection as in Vim
|
||||||
|
#bind-key -t vi-copy v begin-selection
|
||||||
|
#bind-key -t vi-copy y copy-pipe "reattach-to-user-namespace pbcopy"
|
||||||
|
|
||||||
|
# Update default binding of `Enter` to also use copy-pipe
|
||||||
|
# unbind -t vi-copy Enter
|
||||||
|
# bind-key -t vi-copy Enter copy-pipe "reattach-to-user-namespace pbcopy"
|
||||||
|
#
|
||||||
|
############################################################################
|
||||||
|
############################################################################
|
||||||
|
# Reset Prefix
|
||||||
|
############################################################################
|
||||||
|
set -g prefix C-a
|
||||||
|
bind-key a send-prefix # for nested tmux sessions
|
||||||
|
|
||||||
|
############################################################################
|
||||||
|
# Global options
|
||||||
|
############################################################################
|
||||||
|
# large history
|
||||||
|
set-option -g history-limit 10000
|
||||||
|
|
||||||
|
# colors
|
||||||
|
setw -g mode-bg black
|
||||||
|
set-option -g default-terminal "screen-256color" #"xterm-256color" # "screen-256color"
|
||||||
|
set-option -g pane-active-border-fg green
|
||||||
|
|
||||||
|
# utf8 support
|
||||||
|
#set-window-option -g utf8 on
|
||||||
|
|
||||||
|
|
||||||
|
# basic settings
|
||||||
|
set-window-option -g xterm-keys on # for vim
|
||||||
|
set-window-option -g mode-keys vi # vi key
|
||||||
|
set-window-option -g monitor-activity on
|
||||||
|
set-window-option -g window-status-current-fg white
|
||||||
|
setw -g window-status-current-attr reverse
|
||||||
|
|
||||||
|
# Automatically set window title
|
||||||
|
setw -g automatic-rename
|
||||||
|
|
||||||
|
# use mouse # More on mouse support http://floriancrouzat.net/2010/07/run-tmux-with-mouse-support-in-mac-os-x-terminal-app/
|
||||||
|
#setw -g mode-mouse on
|
||||||
|
#setw -g mouse-resize-pane on
|
||||||
|
#set -g mouse-select-window on
|
||||||
|
#set -g mouse-select-pane on
|
||||||
|
set -g mouse on
|
||||||
|
set -g history-limit 30000
|
||||||
|
set -g terminal-overrides 'xterm*:smcup@:rmcup@'
|
||||||
|
|
||||||
|
# vi movement keys
|
||||||
|
# set-option -g status-keys vi
|
||||||
|
|
||||||
|
############################################################################
|
||||||
|
# Status Bar
|
||||||
|
############################################################################
|
||||||
|
#set-option -g status-utf8 on
|
||||||
|
set-option -g status-justify right
|
||||||
|
set-option -g status-bg black # colour213 # pink
|
||||||
|
set-option -g status-fg cyan
|
||||||
|
set-option -g status-interval 5
|
||||||
|
set-option -g status-left-length 30
|
||||||
|
set-option -g status-left '#[fg=magenta]» #[fg=blue,bold]#T#[default]'
|
||||||
|
set-option -g status-right '#[fg=red,bold][[ #(git branch) branch ]] #[fg=cyan]»» #[fg=blue,bold]###S #[fg=magenta]%R %m-%d#(acpi | cut -d ',' -f 2)#[default]'
|
||||||
|
set-option -g visual-activity on
|
||||||
|
|
||||||
|
# Titles (window number, program name, active (or not)
|
||||||
|
set-option -g set-titles on
|
||||||
|
set-option -g set-titles-string '#H:#S.#I.#P #W #T'
|
||||||
|
|
||||||
|
|
||||||
|
############################################################################
|
||||||
|
# Unbindings
|
||||||
|
############################################################################
|
||||||
|
#unbind [ # copy mode bound to escape key
|
||||||
|
unbind j
|
||||||
|
unbind C-b # unbind default leader key
|
||||||
|
unbind '"' # unbind horizontal split
|
||||||
|
unbind % # unbind vertical split
|
||||||
|
|
||||||
|
|
||||||
|
############################################################################
|
||||||
|
# Bindings
|
||||||
|
############################################################################
|
||||||
|
# reload tmux conf
|
||||||
|
bind-key r source-file ~/.tmux.conf
|
||||||
|
|
||||||
|
#bind Escape copy-mode
|
||||||
|
|
||||||
|
# new split in current pane (horizontal / vertical)
|
||||||
|
bind-key c split-window -v # split pane horizontally
|
||||||
|
bind-key v split-window -h # split pane vertically
|
||||||
|
|
||||||
|
# list panes
|
||||||
|
bind-key Space list-panes
|
||||||
|
|
||||||
|
# break-pane
|
||||||
|
bind-key Enter break-pane
|
||||||
|
|
||||||
|
# join-pane [-dhv] [-l size | -p percentage] [-s src-pane]
|
||||||
|
# [-t:dst-window.dst-pane] (destination window (dot) destination pane
|
||||||
|
# (alias: joinp)
|
||||||
|
#
|
||||||
|
#bind C-j command-prompt "joinp"
|
||||||
|
#bind C-j command-prompt "join-pane"
|
||||||
|
#bind-key j command-prompt "join-pane -s '%%'"
|
||||||
|
#bind-key j command-prompt "joinp -t:0"
|
||||||
|
bind-key Space command-prompt "joinp -t:%%" # %% = prompt for window.pane [-V|H] # vert|hor split
|
||||||
|
|
||||||
|
#previous pane
|
||||||
|
bind-key -n C-up prev
|
||||||
|
bind-key -n C-left prev
|
||||||
|
|
||||||
|
#next pane
|
||||||
|
bind-key -n C-right next
|
||||||
|
bind-key -n C-down next
|
||||||
|
|
||||||
|
############################################################################
|
||||||
|
# windows
|
||||||
|
############################################################################
|
||||||
|
set-window-option -g window-status-current-bg red
|
||||||
|
bind C-j previous-window
|
||||||
|
bind C-k next-window
|
||||||
|
bind-key C-a last-window # C-a C-a for last active window
|
||||||
|
bind A command-prompt "rename-window %%"
|
||||||
|
# By default, all windows in a session are constrained to the size of the
|
||||||
|
# smallest client connected to that session,
|
||||||
|
# even if both clients are looking at different windows.
|
||||||
|
# It seems that in this particular case, Screen has the better default
|
||||||
|
# where a window is only constrained in size if a smaller client
|
||||||
|
# is actively looking at it.
|
||||||
|
setw -g aggressive-resize on
|
||||||
|
|
||||||
|
############################################################################
|
||||||
|
# panes
|
||||||
|
############################################################################
|
||||||
|
# Navigation ---------------------------------------------------------------
|
||||||
|
# use the vim motion keys to move between panes
|
||||||
|
bind-key h select-pane -L
|
||||||
|
bind-key j select-pane -D
|
||||||
|
bind-key k select-pane -U
|
||||||
|
bind-key l select-pane -R
|
||||||
|
|
||||||
|
# Resizing ---------------------------------------------------------------
|
||||||
|
bind-key C-h resize-pane -L
|
||||||
|
bind-key C-j resize-pane -D
|
||||||
|
bind-key C-k resize-pane -U
|
||||||
|
bind-key C-l resize-pane -R
|
||||||
|
|
||||||
|
# use vim motion keys while in copy mode
|
||||||
|
setw -g mode-keys vi
|
||||||
|
|
||||||
|
############################################################################
|
||||||
|
# layouts
|
||||||
|
############################################################################
|
||||||
|
bind o select-layout "active-only"
|
||||||
|
bind M-- select-layout "even-vertical"
|
||||||
|
bind M-| select-layout "even-horizontal"
|
||||||
|
bind M-r rotate-window
|
||||||
|
|
||||||
|
|
||||||
|
# focus on first window
|
||||||
|
# select-window -t 0
|
29
.urlview
Normal file
29
.urlview
Normal file
|
@ -0,0 +1,29 @@
|
||||||
|
###############################################################################
|
||||||
|
# Urlview configuration file.
|
||||||
|
# man urlview <Man page>
|
||||||
|
#
|
||||||
|
# Put this file in: $HOME/.urlview
|
||||||
|
# Put url_handler.sh in: /usr/bin
|
||||||
|
#
|
||||||
|
# You can call 'urlview' while in 'mutt' by pressing the Ctrl b keys.
|
||||||
|
# Put these macros in your $HOME/.muttrc file.
|
||||||
|
#
|
||||||
|
# macro index \cb |urlview\n
|
||||||
|
# macro pager \cb |urlview\n
|
||||||
|
#
|
||||||
|
# You can call 'urlview' while in 'tin' by pressing | then a for article,
|
||||||
|
# put urlview as the pipe command.
|
||||||
|
#
|
||||||
|
# Regular expression to use to match URLs.
|
||||||
|
|
||||||
|
#REGEXP (((http|https|ftp|gopher)|mailto):(//)?[^ >"\t]*|www\.[-a-z0-9.]+)[^ .,;\t>">\):]
|
||||||
|
REGEXP (((http|https|ftp|gopher)|mailto)[.:][^ >"\t]*|www\.[-a-z0-9.]+)[^ .,;\t>">\):]
|
||||||
|
|
||||||
|
# Command to invoke for selected URL. Use lynx, netscape, or url_handler.sh
|
||||||
|
# shell script. Alternatively, you can leave COMMAND unset and set the BROWSER
|
||||||
|
# environment variable instead.
|
||||||
|
|
||||||
|
#COMMAND lynx %s
|
||||||
|
#COMMAND netscape -remote 'openURL(%s)'
|
||||||
|
COMMAND webview
|
||||||
|
|
235
.vimrc
Normal file
235
.vimrc
Normal file
|
@ -0,0 +1,235 @@
|
||||||
|
" Load Pathogen for plugins:
|
||||||
|
execute pathogen#infect()
|
||||||
|
execute pathogen#helptags()
|
||||||
|
|
||||||
|
" Some basics:
|
||||||
|
set nocompatible
|
||||||
|
filetype plugin on
|
||||||
|
"colorscheme wal
|
||||||
|
syntax on
|
||||||
|
set encoding=utf-8
|
||||||
|
set number
|
||||||
|
set relativenumber
|
||||||
|
|
||||||
|
"au BufWinLeave * mkview
|
||||||
|
"au BufWinEnter * silent loadview
|
||||||
|
let g:instant_markdown_autostart = 0
|
||||||
|
|
||||||
|
let g:vimwiki_ext2syntax = {'.Rmd': 'markdown', '.rmd': 'markdown','.md': 'markdown', '.markdown': 'markdown', '.mdown': 'markdown'} "Interpret .md files, etc. as .markdown
|
||||||
|
|
||||||
|
"Make calcurse notes markdown compatible:
|
||||||
|
autocmd BufRead,BufNewFile /tmp/calcurse*,~/.calcurse/notes/* set filetype=markdown
|
||||||
|
|
||||||
|
"Spell-check set to F6:
|
||||||
|
map <F6> :setlocal spell! spelllang=en_us,es<CR>
|
||||||
|
|
||||||
|
"Toggle DeadKeys set to F7 (for accent marks):
|
||||||
|
so ~/.vim/luke/deadkeys.vim
|
||||||
|
nm <F7> :call ToggleDeadKeys()<CR>
|
||||||
|
|
||||||
|
"Goyo plugin makes text more readable when writing prose:
|
||||||
|
map <F10> :Goyo<CR>
|
||||||
|
inoremap <F10> <esc>:Goyo<CR>a
|
||||||
|
|
||||||
|
"Enable Goyo by default for mutt writting
|
||||||
|
autocmd BufRead,BufNewFile /tmp/neomutt* let g:goyo_width=72
|
||||||
|
autocmd BufRead,BufNewFile /tmp/neomutt* :Goyo
|
||||||
|
|
||||||
|
"Enable autocompletion:
|
||||||
|
set wildmode=longest,list,full
|
||||||
|
set wildmenu
|
||||||
|
|
||||||
|
"Automatically deletes all tralling whitespace on save.
|
||||||
|
autocmd BufWritePre * %s/\s\+$//e
|
||||||
|
|
||||||
|
"When shortcut files are updated, renew bash and ranger configs with new
|
||||||
|
"material:
|
||||||
|
autocmd BufWritePost ~/.config/Scripts/folders,~/.config/Scripts/configs !bash ~/.config/Scripts/shortcuts.sh
|
||||||
|
|
||||||
|
" Runs a script that cleans out tex build files whenever I close out of a .tex file.
|
||||||
|
autocmd VimLeave *.tex !texclear
|
||||||
|
|
||||||
|
" Use urlview to choose and open a url:
|
||||||
|
:noremap <leader>u :w<Home>silent <End> !urlview<CR>
|
||||||
|
|
||||||
|
"Copy selected text to system clipboard (requires gvim installed):
|
||||||
|
vnoremap <C-c> "+y
|
||||||
|
|
||||||
|
"C-T for new tab
|
||||||
|
nnoremap <C-t> :tabnew<cr>
|
||||||
|
|
||||||
|
"""BASIC TOOLS
|
||||||
|
"Navigating with guides
|
||||||
|
inoremap <Space><Tab> <Esc>/<++><Enter>"_c4l
|
||||||
|
vnoremap <Space><Tab> <Esc>/<++><Enter>"_c4l
|
||||||
|
map <Space><Tab> <Esc>/<++><Enter>"_c4l
|
||||||
|
inoremap ;gui <++>
|
||||||
|
"For normal mode when in terminals (in X I have caps mapped to esc, this replaces it when I don't have X)
|
||||||
|
inoremap jw <Esc>
|
||||||
|
inoremap wj <Esc>
|
||||||
|
"Shortcutting split navigation, saving a keypress:
|
||||||
|
map <C-h> <C-w>h
|
||||||
|
map <C-j> <C-w>j
|
||||||
|
map <C-k> <C-w>k
|
||||||
|
map <C-l> <C-w>l
|
||||||
|
|
||||||
|
"Replace all is aliased to S. Visual mode shortcut doesn't work yet for some
|
||||||
|
"reason...
|
||||||
|
nnoremap S :%s//g<Left><Left>
|
||||||
|
vnoremap S noop
|
||||||
|
vnoremap S :s//g<Left><Left>
|
||||||
|
|
||||||
|
"""LATEX
|
||||||
|
" Word count:
|
||||||
|
autocmd FileType tex map <F3> :w !detex \| wc -w<CR>
|
||||||
|
autocmd FileType tex inoremap <F3> <Esc>:w !detex \| wc -w<CR>
|
||||||
|
" Compile document using xelatex:
|
||||||
|
autocmd FileType tex inoremap <F5> <Esc>:!xelatex<spacE><c-r>%<Enter>a
|
||||||
|
autocmd FileType tex nnoremap <F5> :!xelatex<spacE><c-r>%<Enter>
|
||||||
|
" Code snippets
|
||||||
|
autocmd FileType tex inoremap ;fr \begin{frame}<Enter>\frametitle{}<Enter><Enter><++><Enter><Enter>\end{frame}<Enter><Enter><++><Esc>6kf}i
|
||||||
|
autocmd FileType tex inoremap ;fi \begin{fitch}<Enter><Enter>\end{fitch}<Enter><Enter><++><Esc>3kA
|
||||||
|
autocmd FileType tex inoremap ;exe \begin{exe}<Enter>\ex<Space><Enter>\end{exe}<Enter><Enter><++><Esc>3kA
|
||||||
|
autocmd FileType tex inoremap ;em \emph{}<++><Esc>T{i
|
||||||
|
autocmd FileType tex inoremap ;bf \textbf{}<++><Esc>T{i
|
||||||
|
autocmd FileType tex vnoremap ; <ESC>`<i\{<ESC>`>2la}<ESC>?\\{<Enter>a
|
||||||
|
"autocmd FileType tex vnoremap : <ESC>`<i{\<ESC>`>2la}<ESC>?{\\<Enter>la
|
||||||
|
autocmd FileType tex inoremap {{ <Esc>F{i
|
||||||
|
autocmd FileType tex inoremap }} <Esc>f}a
|
||||||
|
autocmd FileType tex inoremap ;it \textit{}<++><Esc>T{i
|
||||||
|
autocmd FileType tex inoremap ;ct \textcite{}<++><Esc>T{i
|
||||||
|
autocmd FileType tex inoremap ;cp \parencite{}<++><Esc>T{i
|
||||||
|
autocmd FileType tex inoremap ;glos {\gll<Space><++><Space>\\<Enter><++><Space>\\<Enter>\trans{``<++>''}}<Esc>2k2bcw
|
||||||
|
autocmd FileType tex inoremap ;x \begin{xlist}<Enter>\ex<Space><Enter>\end{xlist}<Esc>kA<Space>
|
||||||
|
autocmd FileType tex inoremap ;ol \begin{enumerate}<Enter><Enter>\end{enumerate}<Enter><Enter><++><Esc>3kA\item<Space>
|
||||||
|
autocmd FileType tex inoremap ;ul \begin{itemize}<Enter><Enter>\end{itemize}<Enter><Enter><++><Esc>3kA\item<Space>
|
||||||
|
autocmd FileType tex inoremap ;li <Enter>\item<Space>
|
||||||
|
autocmd FileType tex inoremap ;ref \ref{}<Space><++><Esc>T{i
|
||||||
|
autocmd FileType tex inoremap ;tab \begin{tabular}<Enter><++><Enter>\end{tabular}<Enter><Enter><++><Esc>4kA{}<Esc>i
|
||||||
|
autocmd FileType tex inoremap ;ot \begin{tableau}<Enter>\inp{<++>}<Tab>\const{<++>}<Tab><++><Enter><++><Enter>\end{tableau}<Enter><Enter><++><Esc>5kA{}<Esc>i
|
||||||
|
autocmd FileType tex inoremap ;can \cand{}<Tab><++><Esc>T{i
|
||||||
|
autocmd FileType tex inoremap ;con \const{}<Tab><++><Esc>T{i
|
||||||
|
autocmd FileType tex inoremap ;v \vio{}<Tab><++><Esc>T{i
|
||||||
|
autocmd FileType tex inoremap ;a \href{}{<++>}<Space><++><Esc>2T{i
|
||||||
|
autocmd FileType tex inoremap ;sc \textsc{}<Space><++><Esc>T{i
|
||||||
|
autocmd FileType tex inoremap ;chap \chapter{}<Enter><Enter><++><Esc>2kf}i
|
||||||
|
autocmd FileType tex inoremap ;sec \section{}<Enter><Enter><++><Esc>2kf}i
|
||||||
|
autocmd FileType tex inoremap ;ssec \subsection{}<Enter><Enter><++><Esc>2kf}i
|
||||||
|
autocmd FileType tex inoremap ;sssec \subsubsection{}<Enter><Enter><++><Esc>2kf}i
|
||||||
|
autocmd FileType tex inoremap ;st <Esc>F{i*<Esc>f}i
|
||||||
|
autocmd FileType tex inoremap ;beg \begin{DELRN}<Enter><++><Enter>\end{DELRN}<Enter><Enter><++><Esc>4k0fR:MultipleCursorsFind<Space>DELRN<Enter>c
|
||||||
|
autocmd FileType tex inoremap ;up <Esc>/usepackage<Enter>o\usepackage{}<Esc>i
|
||||||
|
autocmd FileType tex nnoremap ;up /usepackage<Enter>o\usepackage{}<Esc>i
|
||||||
|
autocmd FileType tex inoremap ;tt \texttt{}<Space><++><Esc>T{i
|
||||||
|
autocmd FileType tex inoremap ;bt {\blindtext}
|
||||||
|
autocmd FileType tex inoremap ;nu $\varnothing$
|
||||||
|
autocmd FileType tex inoremap ;col \begin{columns}[T]<Enter>\begin{column}{.5\textwidth}<Enter><Enter>\end{column}<Enter>\begin{column}{.5\textwidth}<Enter><++><Enter>\end{column}<Enter>\end{columns}<Esc>5kA
|
||||||
|
autocmd FileType tex inoremap ;rn (\ref{})<++><Esc>F}i
|
||||||
|
|
||||||
|
"""LATEX Logical symbols
|
||||||
|
autocmd FileType tex inoremap ;m $$<Space><++><Esc>2T$i
|
||||||
|
autocmd FileType tex inoremap ;M $$$$<Enter><Enter><++><Esc>2k$hi
|
||||||
|
autocmd FileType tex inoremap ;neg {\neg}
|
||||||
|
autocmd FileType tex inoremap ;V {\vee}
|
||||||
|
autocmd FileType tex inoremap ;or {\vee}
|
||||||
|
autocmd FileType tex inoremap ;L {\wedge}
|
||||||
|
autocmd FileType tex inoremap ;and {\wedge}
|
||||||
|
autocmd FileType tex inoremap ;ra {\rightarrow}
|
||||||
|
autocmd FileType tex inoremap ;la {\leftarrow}
|
||||||
|
autocmd FileType tex inoremap ;lra {\leftrightarrow}
|
||||||
|
autocmd FileType tex inoremap ;fa {\forall}
|
||||||
|
autocmd FileType tex inoremap ;ex {\exists}
|
||||||
|
autocmd FileType tex inoremap ;dia {\Diamond}
|
||||||
|
autocmd FileType tex inoremap ;box {\Box}
|
||||||
|
autocmd FileType tex inoremap ;gt {\textgreater}
|
||||||
|
autocmd FileType tex inoremap ;lt {\textless}
|
||||||
|
"""LaTeX Linguistics Shortcuts
|
||||||
|
autocmd Filetype tex inoremap ;nom {\textsc{nom}}
|
||||||
|
autocmd FileType tex inoremap ;acc {\textsc{acc}}
|
||||||
|
autocmd FileType tex inoremap ;dat {\textsc{dat}}
|
||||||
|
autocmd FileType tex inoremap ;gen {\textsc{gen}}
|
||||||
|
autocmd FileType tex inoremap ;abl {\textsc{abl}}
|
||||||
|
autocmd FileType tex inoremap ;voc {\textsc{voc}}
|
||||||
|
autocmd FileType tex inoremap ;loc {\textsc{loc}}
|
||||||
|
autocmd Filetype tex inoremap ;inst {\textsc{inst}}
|
||||||
|
autocmd FileType tex inoremap ;tipa \textipa{}<Space><++><Esc>T{i
|
||||||
|
|
||||||
|
"For Indo-European
|
||||||
|
"autocmd FileType tex inoremap ;dh d\textsuperscript{h}
|
||||||
|
"autocmd FileType tex inoremap ;bh b\textsuperscript{h}
|
||||||
|
"autocmd FileType tex inoremap ;gh g\textsuperscript{h}
|
||||||
|
"autocmd FileType tex inoremap ;gwh g\textsuperscript{hw}
|
||||||
|
"autocmd FileType tex inoremap ;kw k\textsuperscript{w}
|
||||||
|
"autocmd FileType tex inoremap ;gw g\textsuperscript{w}
|
||||||
|
"autocmd FileType tex inoremap ;h1 {h\textsubscript{1}}
|
||||||
|
"autocmd FileType tex inoremap ;h2 {h\textsubscript{2}}
|
||||||
|
"autocmd FileType tex inoremap ;h3 {h\textsubscript{3}}
|
||||||
|
"autocmd FileType tex inoremap ;h4 {h\textsubscript{4}}
|
||||||
|
|
||||||
|
|
||||||
|
"""PHP
|
||||||
|
autocmd FileType php,html inoremap ;b <b></b><Space><++><Esc>FbT>i
|
||||||
|
autocmd FileType php,html inoremap ;i <em></em><Space><++><Esc>FeT>i
|
||||||
|
autocmd FileType php,html inoremap ;h1 <h1></h1><Enter><Enter><++><Esc>2kf<i
|
||||||
|
autocmd FileType php,html inoremap ;h2 <h2></h2><Enter><Enter><++><Esc>2kf<i
|
||||||
|
autocmd FileType php,html inoremap ;h3 <h3></h3><Enter><Enter><++><Esc>2kf<i
|
||||||
|
autocmd FileType php,html inoremap ;p <p></p><Enter><Enter><++><Esc>02kf>a
|
||||||
|
autocmd FileType php,html inoremap ;a <a<Space>href=""><++></a><Space><++><Esc>14hi
|
||||||
|
autocmd FileType php,html inoremap ;e <a<Space>target="_blank"<Space>href=""><++></a><Space><++><Esc>14hi
|
||||||
|
autocmd FileType php,html inoremap ;ul <ul><Enter><li></li><Enter></ul><Enter><Enter><++><Esc>03kf<i
|
||||||
|
autocmd FileType php,html inoremap ;li <Esc>o<li></li><Esc>F>a
|
||||||
|
autocmd FileType php,html inoremap ;ol <ol><Enter><li></li><Enter></ol><Enter><Enter><++><Esc>03kf<i
|
||||||
|
autocmd FileType php,html inoremap ;im <table<Space>class="image"><Enter><caption align="bottom"></caption><Enter><tr><td><a<space>href="pix/<++>"><img<Space>src="pix/<++>"<Space>width="<++>"></a></td></tr><Enter></table><Enter><Enter><++><Esc>4kf>a
|
||||||
|
autocmd FileType php,html inoremap ;td <td></td><++><Esc>Fdcit
|
||||||
|
autocmd FileType php,html inoremap ;tr <tr></tr><Enter><++><Esc>kf<i
|
||||||
|
autocmd FileType php,html inoremap ;th <th></th><++><Esc>Fhcit
|
||||||
|
autocmd FileType php,html inoremap ;tab <table><Enter></table><Esc>O
|
||||||
|
autocmd FileType php,html inoremap ;gr <font color="green"></font><Esc>F>a
|
||||||
|
autocmd FileType php,html inoremap ;rd <font color="red"></font><Esc>F>a
|
||||||
|
autocmd FileType php,html inoremap ;yl <font color="yellow"></font><Esc>F>a
|
||||||
|
autocmd FileType php,html inoremap ;dt <dt></dt><Enter><dd><++></dd><Enter><++><esc>2kcit
|
||||||
|
autocmd FileType php,html inoremap ;dl <dl><Enter><Enter></dl><enter><enter><++><esc>3kcc
|
||||||
|
"autocmd FileType php,html inoremap -- –
|
||||||
|
"autocmd FileType php,html inoremap --- —
|
||||||
|
|
||||||
|
|
||||||
|
""".bib
|
||||||
|
autocmd FileType bib inoremap ;a @article{<Enter>author<Space>=<Space>"<++>",<Enter>year<Space>=<Space>"<++>",<Enter>title<Space>=<Space>"<++>",<Enter>journal<Space>=<Space>"<++>",<Enter>volume<Space>=<Space>"<++>",<Enter>pages<Space>=<Space>"<++>",<Enter>}<Enter><++><Esc>8kA,<Esc>i
|
||||||
|
autocmd FileType bib inoremap ;b @book{<Enter>author<Space>=<Space>"<++>",<Enter>year<Space>=<Space>"<++>",<Enter>title<Space>=<Space>"<++>",<Enter>publisher<Space>=<Space>"<++>",<Enter>}<Enter><++><Esc>6kA,<Esc>i
|
||||||
|
autocmd FileType bib inoremap ;c @incollection{<Enter>author<Space>=<Space>"<++>",<Enter>title<Space>=<Space>"<++>",<Enter>booktitle<Space>=<Space>"<++>",<Enter>editor<Space>=<Space>"<++>",<Enter>year<Space>=<Space>"<++>",<Enter>publisher<Space>=<Space>"<++>",<Enter>}<Enter><++><Esc>8kA,<Esc>i
|
||||||
|
|
||||||
|
"MARKDOWN
|
||||||
|
autocmd Filetype markdown,rmd inoremap ;n ---<Enter><Enter>
|
||||||
|
autocmd Filetype markdown,rmd inoremap ;b ****<++><Esc>F*hi
|
||||||
|
autocmd Filetype markdown,rmd inoremap ;s ~~~~<++><Esc>F~hi
|
||||||
|
autocmd Filetype markdown,rmd inoremap ;e **<++><Esc>F*i
|
||||||
|
autocmd Filetype markdown,rmd inoremap ;h ====<Space><++><Esc>F=hi
|
||||||
|
autocmd Filetype markdown,rmd inoremap ;i ![](<++>)<++><Esc>F[a
|
||||||
|
autocmd Filetype markdown,rmd inoremap ;a [](<++>)<++><Esc>F[a
|
||||||
|
autocmd Filetype markdown,rmd inoremap ;1 #<Space><Enter><++><Esc>kA
|
||||||
|
autocmd Filetype markdown,rmd inoremap ;2 ##<Space><Enter><++><Esc>kA
|
||||||
|
autocmd Filetype markdown,rmd inoremap ;3 ###<Space><Enter><++><Esc>kA
|
||||||
|
autocmd Filetype markdown,rmd inoremap ;l --------<Enter>
|
||||||
|
autocmd Filetype markdown map <F5> :!pandoc<space><C-r>%<space>-o<space><C-r>%.pdf<Enter><Enter>
|
||||||
|
autocmd Filetype rmd map <F5> :!echo<space>"require(rmarkdown);<space>render('<c-r>%')"<space>\|<space>R<space>--vanilla<enter>
|
||||||
|
autocmd Filetype rmd inoremap ;r ```{r,<space>echo=TRUE}<CR>```<CR><CR><esc>2kO
|
||||||
|
|
||||||
|
""".xml
|
||||||
|
"autocmd FileType xml inoremap ;e <item><Enter><title><++></title><Enter><pubDate><Esc>:put<Space>=strftime('%c')<Enter>A</pubDate><Enter><link><++></link><Enter><description><++></description><Enter></item>
|
||||||
|
autocmd FileType xml inoremap ;e <item><Enter><title><++></title><Enter><pubDate><Esc>:put<Space>=strftime('%c')<Enter>A</pubDate><Enter><link><++></link><Enter><description><![CDATA[<++>]]></description><Enter></item><Esc>5kcit
|
||||||
|
autocmd FileType xml inoremap ;a <a href="<++>"><++></a><++><Esc>F"ci"
|
||||||
|
|
||||||
|
"Insert the time:
|
||||||
|
noremap ;time :put<Space>=strftime('%c')<Enter>
|
||||||
|
inoremap ;time <esc>:put<Space>=strftime('%c')<Enter>
|
||||||
|
|
||||||
|
|
||||||
|
vmap <expr> ++ VMATH_YankAndAnalyse()
|
||||||
|
nmap ++ vip++
|
||||||
|
|
||||||
|
vnoremap K xkP`[V`]
|
||||||
|
vnoremap J xp`[V`]
|
||||||
|
vnoremap L >gv
|
||||||
|
vnoremap H <gv
|
||||||
|
|
||||||
|
so ~/.vim/luke/ipa.vim
|
1
.xinitrc
Normal file
1
.xinitrc
Normal file
|
@ -0,0 +1 @@
|
||||||
|
exec i3
|
3
LICENSE.md
Normal file
3
LICENSE.md
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
# License
|
||||||
|
|
||||||
|
GPLv3
|
54
README.md
54
README.md
|
@ -1,2 +1,52 @@
|
||||||
# voidrice
|
# Luke's GNU/Linux Rice
|
||||||
My dotfiles for my Void Linux rice
|
|
||||||
|
![pic](pic.jpg)
|
||||||
|
|
||||||
|
There are my dotfiles! The name of the repo, "voidrice", came from the fact they were originally on my Void Linux machine, but these files are distro-independent. In fact, I now push changes from my X200 running Parabola or my X220 running Arch.
|
||||||
|
|
||||||
|
## Programs whose configs can be found here
|
||||||
|
|
||||||
|
+ i3 (i3-gaps)
|
||||||
|
+ urxvt (rxvt-unicode) (although these files us [my st build](https://github.com/lukesmithxyz/st) as the default terminal)
|
||||||
|
+ vim
|
||||||
|
+ bash
|
||||||
|
+ ranger
|
||||||
|
+ qutebrowser
|
||||||
|
+ mutt/msmtp/offlineimap (For offline syncing of email, with configs easy to change to a gmail account)
|
||||||
|
+ calcurse
|
||||||
|
+ ncmpcpp and mpd (my main music player)
|
||||||
|
+ Music on Console (moc and mocp as an alternative music player)
|
||||||
|
+ mpv
|
||||||
|
+ neofetch
|
||||||
|
+ compton (For transparency and to stop screen tearing)
|
||||||
|
+ And many little scripts I use
|
||||||
|
|
||||||
|
## More documentation
|
||||||
|
|
||||||
|
Check other config folders for more specific documentation. For example [config contains documentation on how to set up mutt with your email account.
|
||||||
|
|
||||||
|
[i3 guide and config](.config/i3/i3_guide.md)
|
||||||
|
|
||||||
|
[Email configuration](.config/mutt/email.md)
|
||||||
|
|
||||||
|
[ranger configuration](.config/ranger/luke_ranger_readme.md)
|
||||||
|
|
||||||
|
## Dynamic Configuration Files
|
||||||
|
|
||||||
|
Store your favorite or high-traffic folders in `~/.config/Scripts/folders` or your most important config files in `~/.config/Scripts/configs` with keyboard shortcuts. When you add things to theses files my vimrc will automatically run `~/.config/Scripts/shortcuts.sh` which will dynamically generate shortcuts for these in bash, ranger and qutebrowser!
|
||||||
|
|
||||||
|
Check out more info at the main repo for this: [shortcut-sync](https://github.com/lukesmithxyz/shortcut-sync). You will really want to take advantage of this for an extremely efficient setup!
|
||||||
|
|
||||||
|
## Like my rice?
|
||||||
|
|
||||||
|
Feel free to add other suggestions and I may implement them.
|
||||||
|
|
||||||
|
I have a job, but every penny I get from followers or subscribers is more incentive to perfect what I'm doing. You can donate to me at [https://paypal.me/LukeMSmith](https://paypal.me/LukeMSmith). Donations are earmarked for whatever the donator wants, usually to go to funds for buying new equipment for the [YouTube channel](https://youtube.com/c/LukeSmithxyz).
|
||||||
|
|
||||||
|
# Programs Used
|
||||||
|
|
||||||
|
+ i3-gaps, NetworkManager,compton
|
||||||
|
+ Terminal apps -- ranger, ncmpcpp, mpd, htop, weechat, neomutt, calcurse, newsbeuter, transmission-remote-cli, w3m, youtube-dl, ffmpeg, scrot
|
||||||
|
+ Background stuff -- mpd, transmission
|
||||||
|
+ Lightweight non-terminal apps -- mupdf, feh, rofi, network manager applet, arandr, mpv
|
||||||
|
+ Big business programs -- qutebrowser, GIMP, Blender
|
||||||
|
|
BIN
pic.jpg
Normal file
BIN
pic.jpg
Normal file
Binary file not shown.
After Width: | Height: | Size: 416 KiB |
Loading…
Reference in a new issue