@@ -0,0 +1,18 @@ | |||||
if(interactive()) | |||||
{ | |||||
library(colorout) | |||||
library(setwidth) | |||||
options(blogdown.ext = ".md", | |||||
blogdown.author = "maximewack", | |||||
menu.graphics = F, | |||||
scipen = 999, | |||||
tibble.print_min = 10, | |||||
tibble.print_max = 40) | |||||
.View <- function(x) | |||||
{ | |||||
x %>% | |||||
dplyr::mutate_if(is.character, factor) %>% | |||||
DT::datatable(filter = "top", options = list(paging = F, fixedHeader = T)) | |||||
} | |||||
} |
@@ -0,0 +1,29 @@ | |||||
*background: #202020 | |||||
*foreground: #CCCCCC | |||||
!BLK | |||||
*color0: #666666 | |||||
*color8: #999999 | |||||
!RED | |||||
*color1: #CC6699 | |||||
*color9: #FF99CC | |||||
!GRN | |||||
*color2: #99CC66 | |||||
*color10: #CCFF99 | |||||
!YEL | |||||
*color3: #CC9966 | |||||
*color11: #FFCC99 | |||||
!BLU | |||||
*color4: #6699CC | |||||
*color12: #99CCFF | |||||
!MAG | |||||
*color5: #9966CC | |||||
*color13: #CC99FF | |||||
!CYN | |||||
*color6: #66CC99 | |||||
*color14: #99FFCC | |||||
!WHT | |||||
*color7: #CCCCCC | |||||
*color15: #FFFFFF | |||||
Xcursor.theme: Obsidian |
@@ -0,0 +1,65 @@ | |||||
#!/bin/bash | |||||
# | |||||
# bspwm-session | |||||
# | |||||
# This script is a session launcher for bspwm. | |||||
# It is based on similar scripts included with Openbox. | |||||
if [ -n "$1" ]; then | |||||
echo "Usage: bspwm-session" | |||||
echo | |||||
exit 1 | |||||
fi | |||||
# Multi-user support: | |||||
state_prefix=${XDG_CACHE_HOME:-"$HOME/.cache"} | |||||
mkdir -p "${state_prefix}" | |||||
if [ ! -d "${state_prefix}" ]; then | |||||
echo "bspwm-session: cache directory ‘${state_prefix}‘ is missing." | |||||
echo | |||||
exit 1 | |||||
elif [ ! -w "${state_prefix}" ]; then | |||||
echo "bspwm-session: cache directory ‘${state_prefix}‘ is not writable." | |||||
echo | |||||
exit 1 | |||||
fi | |||||
state_path=$(mktemp -d "${state_prefix}/bspwm-session.XXXXXX") | |||||
if [ $? -ne 0 ]; then | |||||
echo "bspwm-session: failed to create state directory ‘${state_path}‘." | |||||
echo | |||||
exit 1 | |||||
fi | |||||
export BSPWM_SOCKET=${state_path}/bspwm-socket | |||||
# Trap: make sure everything started in ~/.config/bspwm/autostart is | |||||
# signalled when this script exits or dies. Also clean up $state_path. | |||||
function on_exit { | |||||
for child in $(jobs -p); do | |||||
jobs -p | grep -q $child && kill $child | |||||
done | |||||
# Extra paranoia | |||||
[[ -d "${state_path}" && -w "${state_path}" ]] && rm -rf -- "${state_path}" | |||||
} | |||||
trap on_exit EXIT SIGHUP SIGINT SIGTERM | |||||
# Environment and autostart: | |||||
source_these=( | |||||
"/etc/profile" | |||||
"${HOME}/.profile" | |||||
"${XDG_CONFIG_HOME:-"$HOME/.config"}/bspwm/autostart" | |||||
) | |||||
for file in "${source_these[@]}"; do | |||||
[ -r "${file}" ] && . "${file}" | |||||
done | |||||
# Launch sxhkd: | |||||
sxhkd & | |||||
# Launch bspwm: | |||||
bspwm |
@@ -0,0 +1,38 @@ | |||||
#!/bin/bash | |||||
last=`cat /tmp/lastdesk` | |||||
namelast=$last | |||||
namecurrent=`bspc query -d focused -D --names` | |||||
wincurrent=`bspc query -d focused -N` | |||||
if [[ "$last" -gt "1" ]]; then | |||||
del_desks=0 | |||||
for desk in `seq 1 $last`; do | |||||
if [[ -z `bspc query -N -d "$desk"` ]]; then | |||||
let "del_desks += 1" | |||||
bspc desktop "$desk" -r | |||||
else | |||||
let "newname = desk - del_desks" | |||||
bspc desktop "$desk" -n "$newname" | |||||
fi | |||||
done | |||||
let "last = last - del_desks" | |||||
echo "$last" | |||||
# Always keep desktop 1 existing, even if empty | |||||
if [[ "$last" -eq "0" ]]; then | |||||
bspc monitor -a 1 | |||||
bspc desktop -f 1 | |||||
last=1 | |||||
# Allow for an additional empty desktop | |||||
elif [[ "$namecurrent" -eq "$namelast" && -z "$wincurrent" ]]; then | |||||
let "last=$last + 1" | |||||
bspc monitor -a "$last" | |||||
bspc desktop -f "$last" | |||||
fi | |||||
fi | |||||
echo "$last" > /tmp/lastdesk |
@@ -0,0 +1,3 @@ | |||||
#!/bin/bash | |||||
curl -s wttr.in | sed -n 3,7p > /tmp/meteo |
@@ -0,0 +1,2 @@ | |||||
#!/bin/bash | |||||
curl -s wttr.in | sed -n 8,37p |
@@ -0,0 +1,43 @@ | |||||
#!/bin/zsh | |||||
PANEL_FIFO=/tmp/panel-fifo | |||||
if [ $(pgrep -cx panel) -gt 1 ] ; then | |||||
printf "%s\n" "The panel is already running." >&2 | |||||
exit 1 | |||||
fi | |||||
trap 'trap - TERM; kill 0' INT TERM QUIT EXIT | |||||
[ -e "$PANEL_FIFO" ] && rm "$PANEL_FIFO" | |||||
mkfifo "$PANEL_FIFO" | |||||
bspc subscribe > "$PANEL_FIFO" & | |||||
xtitle -sf 'T%s\n' > "$PANEL_FIFO" & | |||||
if [ "$HOST" = "laptop" ];then | |||||
battery -sf 'BI%i' > "$PANEL_FIFO" & | |||||
fi | |||||
clock -sf 'CD%a %d %b' > "$PANEL_FIFO" & | |||||
clock -sf 'CT%H:%M' > "$PANEL_FIFO" & | |||||
if [ "$HOST" = "hegp" ];then | |||||
width=1660 | |||||
volume -sf 'VS%s' -d hw:1 > "$PANEL_FIFO" & | |||||
volume -sf 'VI%i' -d hw:1 > "$PANEL_FIFO" & | |||||
else | |||||
width=1900 | |||||
volume -sf 'VS%s' > "$PANEL_FIFO" & | |||||
volume -sf 'VI%i' > "$PANEL_FIFO" & | |||||
fi | |||||
cat "$PANEL_FIFO" \ | |||||
| panel_bar \ | |||||
| lemonbar -g "$width"x24+10+0 \ | |||||
-f "monofur\ for\ Powerline:size=10" \ | |||||
-f "FontAwesome:size=10" \ | |||||
-u 0 \ | |||||
-B '#00AAAAAA' \ | |||||
-F '#FF202020' & | |||||
wait |
@@ -0,0 +1,119 @@ | |||||
#!/bin/bash | |||||
COLOR_FOCUSED='#FF202020' | |||||
COLOR_FREE='#FFCCCCCC' | |||||
COLOR_OCCUPIED='#FF666666' | |||||
num_mon=$(bspc query -M | wc -l) | |||||
while read -r line ; do | |||||
case $line in | |||||
VS*) | |||||
# volume state | |||||
if [ ${line#??} == "on" ] | |||||
then | |||||
volume_state=`echo -e "%{T2}\uf028"` | |||||
else | |||||
volume_state=`echo -e "%{T2}\uf026"` | |||||
fi | |||||
;; | |||||
VI*) | |||||
# volume output | |||||
volume="%{T1}${line#??}" | |||||
;; | |||||
BS*) | |||||
# battery state | |||||
if [ ${line#??} == "Charging" ] | |||||
then | |||||
batt_state=`echo -e "%{T2}\uf0e7"` | |||||
elif [ ${line#??} == "Full" ] | |||||
then | |||||
batt_state=`echo -e "%{T2}\uf0e7"` | |||||
else | |||||
batt_state="" | |||||
fi | |||||
;; | |||||
BI*) | |||||
# battery output | |||||
charge="${line#??}" | |||||
if [ $charge -lt "12" ] | |||||
then | |||||
batt=`echo -e "%{T2}\uf244"` | |||||
elif [ $charge -lt "37" ] | |||||
then | |||||
batt=`echo -e "%{T2}\uf243"` | |||||
elif [ $charge -lt "62" ] | |||||
then | |||||
batt=`echo -e "%{T2}\uf242"` | |||||
elif [ $charge -lt "87" ] | |||||
then | |||||
batt=`echo -e "%{T2}\uf241"` | |||||
else | |||||
batt=`echo -e "%{T2}\uf240"` | |||||
fi | |||||
charge=`echo -e "%{T1}$charge"` | |||||
;; | |||||
CD*) | |||||
# date output | |||||
clock_date=`echo -e "%{T2}\uf073 %{T1}${line#??}"` | |||||
;; | |||||
CT*) | |||||
# clock output | |||||
clock=`echo -e "%{T2}\uf017 %{T1}${line#??}"` | |||||
;; | |||||
T*) | |||||
# xtitle output | |||||
title="%{T1}${line#?}" | |||||
;; | |||||
W*) | |||||
# bspwm internal state | |||||
wm_infos="" | |||||
IFS=':' | |||||
set -- ${line#?} | |||||
while [ $# -gt 0 ] ; do | |||||
item=$1 | |||||
name=${item#?} | |||||
case $item in | |||||
M*) | |||||
# active monitor | |||||
if [ $num_mon -gt 1 ] ; then | |||||
wm_infos="$wm_infos %{F$COLOR_FOCUSED} ${name} %{F-}:" | |||||
fi | |||||
;; | |||||
m*) | |||||
# inactive monitor | |||||
if [ $num_mon -gt 1 ] ; then | |||||
wm_infos="$wm_infos %{F$COLOR_OCCUPIED} ${name} %{F-}:" | |||||
fi | |||||
;; | |||||
O*) | |||||
# focused occupied desktop | |||||
wm_infos="${wm_infos}%{F$COLOR_FOCUSED}%{+u} ${name} %{-u}%{F-}" | |||||
;; | |||||
F*) | |||||
# focused free desktop | |||||
wm_infos="${wm_infos}%{F$COLOR_FOCUSED}%{+u} ${name} %{-u}%{F-}" | |||||
;; | |||||
U*) | |||||
# focused urgent desktop | |||||
wm_infos="${wm_infos}%{F$COLOR_FOCUSED}%{+u} ${name} %{-u}%{F-}" | |||||
;; | |||||
o*) | |||||
# occupied desktop | |||||
wm_infos="${wm_infos}%{F$COLOR_OCCUPIED} ${name} %{F-}" | |||||
;; | |||||
f*) | |||||
# free desktop | |||||
wm_infos="${wm_infos}%{F$COLOR_FREE} ${name} %{F-}" | |||||
;; | |||||
h*) | |||||
# urgent desktop | |||||
wm_infos="${wm_infos} ${name} " | |||||
;; | |||||
esac | |||||
shift | |||||
done | |||||
;; | |||||
esac | |||||
printf "%s\n" "%{l}${wm_infos}%{c}${title}%{r}${volume_state} ${volume} ${batt} ${charge}${batt_state} ${clock_date} ${clock} " | |||||
done |
@@ -0,0 +1,22 @@ | |||||
#!/bin/zsh | |||||
if [ $# -eq 0 ];then | |||||
echo "Give at least a classname to toggle" | |||||
exit 0 | |||||
fi | |||||
name=$1 | |||||
shift | |||||
if [ -z `xdotool search --classname $name` ];then | |||||
bspc subscribe node -c 1 | cut -d ' ' -f 5 > /tmp/${name}_win & | |||||
kitty --name $name $* | |||||
sleep .5 | |||||
else | |||||
win=`cat /tmp/${name}_win` | |||||
if [ -z `bspc query -N -n ${win}.hidden` ];then | |||||
bspc node ${win} -g hidden | |||||
else | |||||
bspc node ${win} -g hidden -f | |||||
fi | |||||
fi |
@@ -0,0 +1,4 @@ | |||||
#!/bin/bash | |||||
killall conky | |||||
conky -c /home/maxx/.config/conky/conkyrc |
@@ -0,0 +1,4 @@ | |||||
#!/bin/bash | |||||
killall stalonetray | |||||
/home/maxx/.config/bin/tray |
@@ -0,0 +1,10 @@ | |||||
#!/bin/zsh | |||||
if [ "$HOST" = "laptop" ] | |||||
then | |||||
width=1600 | |||||
elif [ "$HOST" = "hegp" ] | |||||
then | |||||
width=1400 | |||||
fi | |||||
stalonetray --window-type dock --geometry +$width+0 -t --icon-gravity S --grow-gravity NE -i 16 --slot-size 24 --kludges force_icons_size |
@@ -0,0 +1,113 @@ | |||||
#!/bin/zsh | |||||
bspc config border_width 0 | |||||
bspc config window_gap 10 | |||||
bspc config split_ratio 0.4 | |||||
bspc config borderless_monocle true | |||||
bspc config gapless_monocle true | |||||
bspc config focus_by_distance true | |||||
bspc config initial_polarity first_child | |||||
bspc config remove_unplugged_monitors true | |||||
bspc config ignore_ewmh_focus true | |||||
bspc config click_to_focus any | |||||
bspc config pointer_modifier mod4 | |||||
bspc config pointer_action1 move | |||||
bspc config pointer_action2 resize_corner | |||||
bspc config presel_feedback_color "#FFFFFF" | |||||
echo 1 > /tmp/lastdesk | |||||
if [ "$HOST" = "laptop" ];then | |||||
bspc monitor eDP1 -d 1 | |||||
elif [ "$HOST" = "hegp" ];then | |||||
bspc monitor HDMI1 -d 1 | |||||
bspc monitor VGA1 -d I II | |||||
elif [ "$HOST" = "home" ];then | |||||
bspc monitor HDMI2 -d 1 | |||||
fi | |||||
bspc rule -a Slack desktop= | |||||
bspc rule -a TelegramDesktop desktop= | |||||
bspc rule -a Skype desktop= state=tiled | |||||
bspc rule -a Thunderbird desktop= | |||||
bspc rule -a qutebrowser desktop= | |||||
bspc rule -a Galculator state=floating | |||||
bspc rule -a Arandr state=floating | |||||
bspc rule -a Zathura state=tiled | |||||
bspc rule -a Pinentry state=floating | |||||
bspc rule -a Soffice state=tiled | |||||
# Figures and PDFs on second monitor | |||||
if [ "$HOST" = "hegp" ];then | |||||
bspc rule -a R_x11 monitor=^2 | |||||
bspc rule -a Zathura monitor=^2 | |||||
fi | |||||
# Popup CLI apps | |||||
if [ "$HOST" = "laptop" ];then | |||||
bspc rule -a kitty:Ranger sticky=on state=floating rectangle=1820x900+0+0 center=on | |||||
bspc rule -a kitty:Music_playlist sticky=on state=floating rectangle=430x470+30+64 | |||||
bspc rule -a kitty:Music_media sticky=on state=floating rectangle=430x476+30+574 | |||||
bspc rule -a kitty:Music_playlist_home sticky=on state=floating rectangle=430x470+30+64 | |||||
bspc rule -a kitty:Music_media_home sticky=on state=floating rectangle=430x476+30+574 | |||||
bspc rule -a kitty:Wiki sticky=on state=floating rectangle=840x986+490+64 | |||||
bspc rule -a kitty:Volume sticky=on state=floating rectangle=530x270+1360+64 | |||||
bspc rule -a kitty:Torrent sticky=on state=floating rectangle=530x676+1360+374 | |||||
elif [ "$HOST" = "hegp" ];then | |||||
bspc rule -a kitty:Volume monitor=^1 sticky=on state=floating rectangle=490x300+1170+30 | |||||
bspc rule -a kitty:Wiki monitor=^1 sticky=on state=floating rectangle=1000x1000+350+30 | |||||
bspc rule -a kitty:Ranger monitor=^1 sticky=on state=floating rectangle=1550x900+0+0 center=on locked=on | |||||
bspc rule -a kitty:Music_playlist sticky=on state=floating rectangle=430x470+30+64 | |||||
bspc rule -a kitty:Music_media sticky=on state=floating rectangle=430x476+30+574 | |||||
elif [ "$HOST" = "home" ];then | |||||
bspc rule -a kitty:Ranger sticky=on state=floating rectangle=1820x900+0+0 center=on | |||||
bspc rule -a kitty:Music_playlist sticky=on state=floating rectangle=945x1036+10+34 | |||||
bspc rule -a kitty:Music_media sticky=on state=floating rectangle=945x1036+965+34 | |||||
bspc rule -a kitty:Volume sticky=on state=floating rectangle=600x400+1310+34 | |||||
fi | |||||
bspc rule -a kitty:Meteo monitor=^1 sticky=on state=floating rectangle=880x580+500+625 | |||||
bspc rule -a kitty:evimwhere state=floating rectangle=920x580+500+250 | |||||
mpd | |||||
greenclip daemon & | |||||
udiskie -s & | |||||
wmname compiz | |||||
dunst & | |||||
redshift & | |||||
compton -b | |||||
xsetroot -cursor_name left_ptr | |||||
if [ "$HOST" = "hegp" ];then | |||||
hsetroot -fill .config/bspwm/cat_sitting.png | |||||
else | |||||
hsetroot -tile .config/bspwm/cat.png | |||||
fi | |||||
conky -d -c .config/conky/conkyrc & | |||||
panel & | |||||
popup Ranger ranger & | |||||
sleep 1 | |||||
if [ "$HOST" = "home" ];then | |||||
synergyc laptop | |||||
else | |||||
tray & | |||||
thunderbird & | |||||
unclutter & | |||||
telegram-desktop & | |||||
slack & | |||||
fi | |||||
meteo | |||||
qutebrowser & | |||||
popup Ranger | |||||
if [ "$HOST" = "laptop" ];then | |||||
nm-applet --sm-disable & | |||||
synergys & | |||||
fi | |||||
bspc config top_padding 14 |
@@ -0,0 +1,21 @@ | |||||
0 8 * * * DISPLAY=:0.0 hsetroot -tile /home/maxx/.config/bspwm/cat_sitting.png | |||||
0 9 * * * DISPLAY=:0.0 hsetroot -tile /home/maxx/.config/bspwm/cat_mouse.png | |||||
0 10 * * * DISPLAY=:0.0 hsetroot -tile /home/maxx/.config/bspwm/cat.png | |||||
30 10 * * * DISPLAY=:0.0 hsetroot -tile /home/maxx/.config/bspwm/cat_sleeping.png | |||||
0 11 * * * DISPLAY=:0.0 hsetroot -tile /home/maxx/.config/bspwm/cat_playing.png | |||||
30 11 * * * DISPLAY=:0.0 hsetroot -tile /home/maxx/.config/bspwm/cat.png | |||||
30 12 * * * DISPLAY=:0.0 hsetroot -tile /home/maxx/.config/bspwm/cat_sitting.png | |||||
0 13 * * * DISPLAY=:0.0 hsetroot -tile /home/maxx/.config/bspwm/cat_playing.png | |||||
30 13 * * * DISPLAY=:0.0 hsetroot -tile /home/maxx/.config/bspwm/cat.png | |||||
0 14 * * * DISPLAY=:0.0 hsetroot -tile /home/maxx/.config/bspwm/cat_sleeping.png | |||||
50 17 * * * DISPLAY=:0.0 hsetroot -tile /home/maxx/.config/bspwm/cat_sitting.png | |||||
0 18 * * * DISPLAY=:0.0 hsetroot -tile /home/maxx/.config/bspwm/cat_mouse.png | |||||
0 19 * * * DISPLAY=:0.0 hsetroot -tile /home/maxx/.config/bspwm/cat_playing.png | |||||
30 19 * * * DISPLAY=:0.0 hsetroot -tile /home/maxx/.config/bspwm/cat.png | |||||
30 20 * * * DISPLAY=:0.0 hsetroot -tile /home/maxx/.config/bspwm/cat_sleeping.png | |||||
50 21 * * * DISPLAY=:0.0 hsetroot -tile /home/maxx/.config/bspwm/cat_sitting.png | |||||
00 22 * * * DISPLAY=:0.0 hsetroot -tile /home/maxx/.config/bspwm/cat_mouse.png | |||||
15 22 * * * DISPLAY=:0.0 hsetroot -tile /home/maxx/.config/bspwm/cat.png | |||||
30 22 * * * DISPLAY=:0.0 hsetroot -tile /home/maxx/.config/bspwm/cat_sleeping.png | |||||
40 0 * * * DISPLAY=:0.0 hsetroot -tile /home/maxx/.config/bspwm/cat_sitting.png | |||||
55 0 * * * DISPLAY=:0.0 hsetroot -tile /home/maxx/.config/bspwm/cat_sleeping.png |
@@ -0,0 +1,17 @@ | |||||
#!/bin/bash | |||||
for pad in `seq 0 20 560` | |||||
do | |||||
bspc config left_padding $pad | |||||
done | |||||
eval $(xdotool getmouselocation --shell) | |||||
while [ "$X" -lt 250 ] | |||||
do | |||||
eval $(xdotool getmouselocation --shell) | |||||
done | |||||
for pad in `seq 560 -20 0` | |||||
do | |||||
bspc config left_padding $pad | |||||
done |
@@ -0,0 +1,74 @@ | |||||
shadow = true; | |||||
no-dnd-shadow = true; | |||||
no-dock-shadow = true; | |||||
shadow-radius = 14; | |||||
shadow-offset-x = -25; | |||||
shadow-offset-y = -6; | |||||
shadow-opacity = 0.8; | |||||
shadow-red = 0.0; | |||||
shadow-green = 0.0; | |||||
shadow-blue = 0.0; | |||||
shadow-exclude = [ | |||||
"name = 'stalonetray'", | |||||
"name = 'Notification'", | |||||
"name = 'VirtualBox'", | |||||
"class_g = 'Bspwm'", | |||||
"class_i = 'presel_feedback'", | |||||
"class_g = 'Conky'", | |||||
"class_g ?= 'Notify-osd'", | |||||
"class_g = 'Cairo-clock'", | |||||
"class_i = 'POWERPNT.EXE'", | |||||
"class_i = 'WINWORD.EXE'", | |||||
"class_i = 'Meteo'" | |||||
]; | |||||
shadow-ignore-shaped = false; | |||||
menu-opacity = 0.9; | |||||
inactive-opacity = 1; | |||||
active-opacity = 1.0; | |||||
frame-opacity = 1.0; | |||||
inactive-opacity-override = false; | |||||
opacity-rule = [ | |||||
"10:class_g = 'Bspwm'", | |||||
"10:class_i = 'presel_feedback'", | |||||
]; | |||||
alpha-step = 0.1; | |||||
inactive-dim = .3; | |||||
blur-kern = "11x11gaussian"; | |||||
blur-background-exclude = [ "window_type = 'dock'", "window_type = 'desktop'" ]; | |||||
fading = true; | |||||
fade-delta = 10; | |||||
fade-in-step = 0.03; | |||||
fade-out-step = 0.03; | |||||
fade-exclude = []; | |||||
backend = "glx"; | |||||
mark-wmwin-focused = false; | |||||
mark-ovredir-focused = false; | |||||
detect-rounded-corners = true; | |||||
detect-client-opacity = true; | |||||
refresh-rate = 0; | |||||
vsync = "opengl"; | |||||
sw-opti = true; | |||||
dbe = false; | |||||
focus-exclude = [ "class_g = 'Cairo-clock'", "class_g = 'mpv'" ]; | |||||
detect-transient = true; | |||||
detect-client-leader = true; | |||||
invert-color-include = [ ]; | |||||
glx-copy-from-front = false; | |||||
glx-swap-method = "undefined"; | |||||
glx-no-stencil = true; | |||||
wintypes : | |||||
{ | |||||
tooltip = | |||||
{ | |||||
fade = true; | |||||
shadow = false; | |||||
opacity = 0.75; | |||||
focus = true; | |||||
}; | |||||
}; | |||||
blur-background = true; | |||||
inactive-dim-fixed = true; | |||||
blur-background-frame = true; | |||||
blur-background-fixed = true; | |||||
no-fading-openclose = false; | |||||
use-ewmh-active-win = true; |
@@ -0,0 +1,491 @@ | |||||
-- vim: set fdm=indent | |||||
-- conky uses lua5.1. lua51-utf8 package is needed | |||||
utf8 = require 'lua-utf8' | |||||
require 'cairo' | |||||
netuphist = {} | |||||
netdownhist = {} | |||||
ramhist = {} | |||||
swaphist = {} | |||||
cpuhist = {} | |||||
cur = 1 | |||||
-- SETTINGS | |||||
nbCPU = 4 | |||||
FSs = {"/", "/var", "/home"} | |||||
ladapter = "eth0" -- eno1 | |||||
wadapter = "wlan0" | |||||
ntop = 10 | |||||
-- SETTINGS | |||||
function conky_init() | |||||
local cr, cs = nil | |||||
if conky_window == nil then return end | |||||
if cs == nil or cairo_xlib_surface_get_width(cs) ~= conky_window.width or cairo_xlib_surface_get_height(cs) ~= conky_window.height then | |||||
if cs then cairo_surface_destroy(cs) end | |||||
cs = cairo_xlib_surface_create(conky_window.display, conky_window.drawable, conky_window.visual, conky_window.width, conky_window.height) | |||||
end | |||||
if cr then cairo_destroy(cr) end | |||||
cr = cairo_create(cs) | |||||
local items = 30 + nbCPU + #FSs + ntop | |||||
defaultSize = conky_window.height / items | |||||
height = defaultSize + 1 | |||||
small = defaultSize * .8 | |||||
blue = {.4,.6,.8,.5} | |||||
cur = cur % 100 + 1 | |||||
local ypos = 60 | |||||
local xpos = 25 | |||||
local margin = 50 | |||||
ypos = general(cr, xpos, ypos) + margin | |||||
ypos = fs (cr, xpos, ypos) + margin | |||||
ypos = ram (cr, xpos, ypos) + margin | |||||
ypos = cpu (cr, xpos, ypos) + margin | |||||
ypos = top (cr, xpos, ypos, ntop) + margin | |||||
ypos = network(cr, xpos, ypos) + margin | |||||
clock(cr, conky_window.width / 2, conky_window.height / 2 - 170) | |||||
weather(cr, conky_window.width / 2 - 11.5*.6*15, conky_window.height / 2 - 60) | |||||
cairo_destroy(cr) | |||||
cairo_surface_destroy(cs) | |||||
end | |||||
function clock(cr, x, y) | |||||
emboss(cr, x, y - 100, conky_parse("${time %H}"), 1, 200) | |||||
emboss(cr, x, y - 50, conky_parse(":${time %M}"), 0, 150) | |||||
end | |||||
function weather(cr, x, y) | |||||
size = 15 | |||||
meteo = "" | |||||
yt = 0 | |||||
for line in io.lines("/tmp/meteo") do | |||||
yt = yt + size | |||||
xt = 0 | |||||
for substr in string.gmatch(line, "[^]+") do | |||||
color = tonumber(substr:match("%[38;5;(%d+)m")) | |||||
if color ~= nil then | |||||
if color <= 231 then | |||||
color = color - 16 | |||||
b = color % 36 % 6 | |||||
color = color - b | |||||
g = color % 36 / 6 | |||||
color = color - g * 6 | |||||
r = color / 36 | |||||
color = {r * .2, g * .2, b * .2, 1} | |||||
else | |||||
a = (color - 232) / 24 | |||||
color = {a, a, a, 1} | |||||
end | |||||
end | |||||
substr = substr:gsub("%[[^m]+m", "") | |||||
emboss(cr, x + xt, y + yt, substr, 0, size, nil, color, "Fira Code") | |||||
xt = xt + .6*size * utf8.len(substr) | |||||
end | |||||
end | |||||
end | |||||
function general(cr, x, y) | |||||
cadre(cr, x, y, 450, 3 * height, 10) | |||||
emboss(cr , x , y, "Kernel") | |||||
y = emboss(cr, x + 450, y, conky_parse("$kernel") , 1) | |||||
emboss(cr , x , y, "Uptime") | |||||
y = emboss(cr, x + 450, y, conky_parse("$uptime") , 1) | |||||
emboss(cr , x , y, "Load") | |||||
y = emboss(cr, x + 450, y, conky_parse("$loadavg"), 1) | |||||
return y | |||||
end | |||||
function ram(cr, x, y) | |||||
cadre(cr, x, y, 450, 10 + 4 * height, 10) | |||||
if #swaphist == 0 then | |||||
local i | |||||
for i = 1,100 do | |||||
swaphist[i] =.001 | |||||
end | |||||
end | |||||
if #ramhist == 0 then | |||||
local i | |||||
for i = 1,100 do | |||||
ramhist[i] =.001 | |||||
end | |||||
end | |||||
ramhist[cur] = tonumber(conky_parse("$memperc")) | |||||
swaphist[cur] = tonumber(conky_parse("$swapperc")) | |||||
emboss(cr, x , y, "Ram") | |||||
emboss(cr, x + 180, y, conky_parse("$mem/") , 1) | |||||
y = emboss(cr, x + 260, y, conky_parse("$memmax"), 1) | |||||
bar(cr, x + 5, y, 255, conky_parse("$memperc"), blue) | |||||
graph(cr, x + 280, y, 170, ramhist, blue, 100) | |||||
y = y + height + 10 | |||||
emboss(cr, x , y, "Swap") | |||||
emboss(cr, x + 180, y, conky_parse("$swap/") , 1) | |||||
y = emboss(cr, x + 260, y, conky_parse("$swapmax"), 1) | |||||
bar(cr, x + 5, y, 255, conky_parse("$swapperc"), blue) | |||||
graph(cr, x + 280, y, 170, swaphist, blue, 100) | |||||
y = y + height | |||||
return y | |||||
end | |||||
function cpu(cr, x, y) | |||||
cadre(cr, x, y, 450, 10 + (1 + nbCPU) * height, 10) | |||||
if #cpuhist == 0 then | |||||
local i, j | |||||
for i = 1,nbCPU do | |||||
cpuhist[i] = {} | |||||
for j = 1,100 do | |||||
cpuhist[i][j] = .001 | |||||
end | |||||
end | |||||
end | |||||
emboss(cr , x , y, "Cpu") | |||||
emboss(cr , x + 260, y, conky_parse("$freq_g GHz") , 1) | |||||
y = emboss(cr, x + 450, y, conky_parse("Temp ${hwmon 0 temp 1}°C"), 1) + 10 | |||||
local cpu | |||||
for cpu=1,nbCPU do | |||||
bar(cr, x + 5, y, 255, conky_parse("${cpu cpu" .. cpu .. "}"), blue) | |||||
cpuhist[cpu][cur] = tonumber(conky_parse("${cpu cpu" .. cpu .. "}")) | |||||
graph(cr, x + 280, y, 170, cpuhist[cpu], blue, 100) | |||||
y = y + height | |||||
end | |||||
return y | |||||
end | |||||
function network(cr, x, y) | |||||
cadre(cr, x, y, 450, 4 * height + 10, 10) | |||||
local upspd = conky_parse("${upspeedf " .. wadapter .. "}") + conky_parse("${upspeedf " .. ladapter .. "}") | |||||
local downspd = conky_parse("${downspeedf " .. wadapter .. "}") + conky_parse("${downspeedf " .. ladapter .. "}") | |||||
local upspdunit = "KiB/s" | |||||
local downspdunit = "KiB/s" | |||||
if upspd > 1024 then | |||||
upspd = upspd / 1024 | |||||
upspdunit = "MiB/s" | |||||
end | |||||
if downspd > 1024 then | |||||
downspd = downspd / 1024 | |||||
downspdunit = "MiB/s" | |||||
end | |||||
local ethup = string.match(conky_parse("${totalup " .. ladapter .. "}"),"[%d.]+") | |||||
local ethupunit = string.match(conky_parse("${totalup " .. ladapter .. "}"),"%a") | |||||
if ethupunit == "K" then | |||||
ethup = ethup * 1024 | |||||
elseif ethupunit == "M" then | |||||
ethup = ethup * 1024 * 1024 | |||||
elseif ethupunit == "G" then | |||||
ethup = ethup * 1024 * 1024 * 1024 | |||||
end | |||||
local ethdown = string.match(conky_parse("${totaldown " .. ladapter .. "}"),"[%d.]+") | |||||
local ethdownunit = string.match(conky_parse("${totaldown " .. ladapter .. "}"),"%a") | |||||
if ethdownunit == "K" then | |||||
ethdown = ethdown * 1024 | |||||
elseif ethdownunit == "M" then | |||||
ethdown = ethdown * 1024 * 1024 | |||||
elseif ethdownunit == "G" then | |||||
ethdown = ethdown * 1024 * 1024 * 1024 | |||||
end | |||||
local wlanup = string.match(conky_parse("${totalup " .. wadapter .. "}"),"[%d.]+") | |||||
local wlanupunit = string.match(conky_parse("${totalup " .. wadapter .. "}"),"%a") | |||||
if wlanupunit == "K" then | |||||
wlanup = wlanup * 1024 | |||||
elseif wlanupunit == "M" then | |||||
wlanup = wlanup * 1024 * 1024 | |||||
elseif wlanupunit == "G" then | |||||
wlanup = wlanup * 1024 * 1024 * 1024 | |||||
end | |||||
local wlandown = string.match(conky_parse("${totaldown " .. wadapter .. "}"),"[%d.]+") | |||||
local wlandownunit = string.match(conky_parse("${totaldown " .. wadapter .. "}"),"%a") | |||||
if wlandownunit == "K" then | |||||
wlandown = wlandown * 1024 | |||||
elseif wlandownunit == "M" then | |||||
wlandown = wlandown * 1024 * 1024 | |||||
elseif wlandownunit == "G" then | |||||
wlandown = wlandown * 1024 * 1024 * 1024 | |||||
end | |||||
local totalup = ethup + wlanup | |||||
local upunit = "B" | |||||
if totalup > (1024 * 1024 * 1024) then | |||||
totalup = totalup / (1024 * 1024 * 1024) | |||||
upunit = "GiB" | |||||
elseif totalup > (1024 * 1024) then | |||||
totalup = totalup / (1024 * 1024) | |||||
upunit = "MiB" | |||||
elseif totalup > 1024 then | |||||
totalup = totalup / 1024 | |||||
upunit = "KiB" | |||||
end | |||||
local totaldown = ethdown + wlandown | |||||
local downunit = "B" | |||||
if totaldown > (1024 * 1024 * 1024) then | |||||
totaldown = totaldown / (1024 * 1024 * 1024) | |||||
downunit = "GiB" | |||||
elseif totaldown > (1024 * 1024) then | |||||
totaldown = totaldown / (1024 * 1024) | |||||
downunit = "MiB" | |||||
elseif totaldown > 1024 then | |||||
totaldown = totaldown / 1024 | |||||
downunit = "KiB" | |||||
end | |||||
if #netuphist == 0 then | |||||
local i | |||||
for i = 1,100 do | |||||
netuphist[i] = .001 | |||||
end | |||||
end | |||||
if #netdownhist == 0 then | |||||
local i | |||||
for i = 1,100 do | |||||
netdownhist[i] = .001 | |||||
end | |||||
end | |||||
netuphist[cur] = tonumber(conky_parse("${upspeedf " .. wadapter .. "}") + conky_parse("${upspeedf " .. ladapter .. "}")) | |||||
netdownhist[cur] = tonumber(conky_parse("${downspeedf " .. wadapter .. "}") + conky_parse("${downspeedf " .. ladapter .. "}")) | |||||
maxspeed = max({max(netuphist), max(netdownhist)}) | |||||
if maxspeed == 0 then | |||||
maxspeed = 1 | |||||
end | |||||
emboss(cr, x , y, "Up") | |||||
emboss(cr, x + 260, y, string.format("%.1f",upspd) .. upspdunit , 1) | |||||
graph(cr, x + 280, y, 170, netuphist, blue, maxspeed) | |||||
y = y + height | |||||
emboss(cr, x , y, "Down") | |||||
emboss(cr, x + 260, y, string.format("%.1f",downspd) .. downspdunit, 1) | |||||
graph(cr, x + 280, y, 170, netdownhist, blue, maxspeed, 1) | |||||
y = y + height + 10 | |||||
emboss(cr , x , y, "Total up") | |||||
y = emboss(cr, x+260, y, string.format("%.2f",totalup) .. upunit , 1) | |||||
emboss(cr , x , y, "Total down") | |||||
y = emboss(cr, x+260, y, string.format("%.2f",totaldown) .. downunit , 1) | |||||
return y | |||||
end | |||||
function fs(cr, x, y) | |||||
cadre(cr, x, y, 450, height * #FSs, 10) | |||||
for row=1,#FSs do | |||||
emboss(cr, x , y , FSs[row]) | |||||
emboss(cr, x + 180, y , conky_parse("${fs_used " .. FSs[row] .. "}/"), 1) | |||||
emboss(cr, x + 260, y , conky_parse("${fs_size " .. FSs[row] .. "}") , 1) | |||||
bar(cr, x + 280, y, 170, conky_parse("${fs_used_perc " .. FSs[row] .. "}"), blue) | |||||
y = y + height | |||||
end | |||||
return y | |||||
end | |||||
function top(cr, x, y, nrows) | |||||
cadre(cr, x, y, 450, height + 10 + nrows * small, 10) | |||||
emboss(cr , x , y, "Name") | |||||
emboss(cr , x + 220, y, "Cpu", 1) | |||||
emboss(cr , x + 230, y, "Name") | |||||
y = emboss(cr, x + 450, y, "Ram", 1) + 10 | |||||
local row | |||||
for row=1,nrows do | |||||
emboss(cr , x , y, conky_parse("${top name " .. row .. "}") , 0, small) | |||||
emboss(cr , x + 220, y, conky_parse("${top cpu " .. row .. "}") , 1, small) | |||||
emboss(cr , x + 230, y, conky_parse("${top_mem name " .. row .. "}"), 0, small) | |||||
y = emboss(cr, x + 450, y, conky_parse("${top_mem mem " .. row .. "}") , 1, small) | |||||
end | |||||
return y | |||||
end | |||||
function cadre(cr, x, y, w, h, r, pop, col) | |||||
if pop == nil then pop = 1 end | |||||
local pi = 3.141592 | |||||
if pop < 0 then y = y + pop end | |||||
cairo_set_operator(cr, CAIRO_OPERATOR_XOR) | |||||
cairo_move_to(cr, x, y - r) | |||||
cairo_arc(cr, x + w, y , r, 1.5 * pi, 0 * pi) | |||||
cairo_arc(cr, x + w, y + h, r, 0 * pi, .5 * pi) | |||||
cairo_arc(cr, x , y + h, r, .5 * pi, 1 * pi) | |||||
cairo_arc(cr, x , y , r, 1 * pi, 1.5 * pi) | |||||
cairo_set_source_rgb(cr, 1, 1, 1) | |||||
cairo_fill(cr) | |||||
y = y - pop | |||||
cairo_move_to(cr, x, y - r) | |||||
cairo_arc(cr, x + w, y , r,1.5 * pi, 0 * pi) | |||||
cairo_arc(cr, x + w, y + h, r,0 * pi, .5 * pi) | |||||
cairo_arc(cr, x , y + h, r,.5 * pi, 1 * pi) | |||||
cairo_arc(cr, x , y , r,1 * pi, 1.5 * pi) | |||||
cairo_set_source_rgb(cr, 0, 0, 0) | |||||
cairo_fill(cr) | |||||
cairo_set_operator(cr, CAIRO_OPERATOR_OVER) | |||||
cairo_move_to(cr, x, y - r) | |||||
cairo_arc(cr, x + w, y , r, 1.5 * pi, 0 * pi) | |||||
cairo_arc(cr, x + w, y + h, r, 0 * pi, .5 * pi) | |||||
cairo_arc(cr, x , y + h, r, .5 * pi, 1 * pi) | |||||
cairo_arc(cr, x , y , r, 1 * pi, 1.5 * pi) | |||||
if pop > 0 then cairo_set_source_rgba(cr, 0, 0, 0, .1) else cairo_set_source_rgba(cr, 1, 1, 1, .1) end | |||||
cairo_fill_preserve(cr) | |||||
if col ~= nil then cairo_set_source_rgba(cr, col[1], col[2], col[3], col[4]) else cairo_set_source_rgba(cr, 0, 0, 0, 0)end | |||||
cairo_fill(cr) | |||||
end | |||||
function bar(cr, x, y, width, percent, color) | |||||
local barh = height / 3 | |||||
emboss(cr, x + width, y + 3, percent .. "%", 1, small) | |||||
width = width - 45 | |||||
cadre(cr, x, y + barh + 4, width , barh - 4, 4) | |||||
cadre(cr, x, y + barh + 4, width * percent / 100, barh - 4, 2, -1, color) | |||||
end | |||||
function emboss(cr, x, y, text, right, size, pop, col, font) | |||||
if pop == nil then pop = 1 end | |||||
if size == nil then size = defaultSize end | |||||
if right == nil then right = 0 end | |||||
if font == nil then font = "Impact" end | |||||
y = y + size | |||||
cairo_select_font_face (cr, font, CAIRO_FONT_SLANT_NORMAL, CAIRO_FONT_WEIGHT_NORMAL); | |||||
cairo_set_font_size (cr, size); | |||||
if right == 1 then | |||||
extent = cairo_text_extents_t:create() | |||||
tolua.takeownership(extent) | |||||
cairo_text_extents(cr, text, extent) | |||||
x = x - extent.x_advance | |||||
-- cairo_text_extents_t:destroy(extent) | |||||
end | |||||
if pop < 0 then y = y + pop end | |||||
cairo_set_operator(cr, CAIRO_OPERATOR_XOR) | |||||
cairo_move_to(cr, x, y) | |||||
cairo_text_path(cr, text) | |||||
cairo_set_source_rgb(cr, 1, 1, 1) | |||||
cairo_fill(cr) | |||||
cairo_move_to(cr,x,y - pop) | |||||
cairo_text_path(cr, text) | |||||
cairo_set_source_rgb(cr, 0, 0, 0) | |||||
cairo_fill(cr) | |||||
cairo_set_operator(cr, CAIRO_OPERATOR_OVER) | |||||
cairo_move_to(cr, x, y) | |||||
cairo_text_path(cr, text) | |||||
if pop > 0 then cairo_set_source_rgba(cr, 0, 0, 0, .1) else cairo_set_source_rgba(cr, 1, 1, 1, .1) end | |||||
cairo_fill_preserve(cr) | |||||
if col ~= nil then cairo_set_source_rgba(cr, col[1], col[2], col[3], col[4]) else cairo_set_source_rgba(cr, 0, 0, 0, 0) end | |||||
cairo_fill(cr) | |||||
return y | |||||
end | |||||
function graph(cr, x, y, width, hist, color, maximum, reverse) | |||||
if maximum == nil then maximum = max(hist) end | |||||
if reverse == nil then reverse = 0 end | |||||
x = x - 2 | |||||
width = width + 2 | |||||
local scalev = (height - 2) / maximum | |||||
if reverse == 1 then | |||||
scalev = -scalev | |||||
y = y + 1 | |||||
else | |||||
y = y + height - 1 | |||||
end | |||||
local scaleh = width / 100 | |||||
cairo_move_to(cr, x + scaleh, y) | |||||
local i | |||||
for i = cur+1,100 do | |||||
cairo_line_to(cr, x + (i - cur) * scaleh, y - hist[i] * scalev) | |||||
end | |||||
for i = 1,cur do | |||||
cairo_line_to(cr, x + ((100 - cur) + i) * scaleh, y - hist[i] * scalev) | |||||
end | |||||
cairo_line_to(cr, x + 100 * scaleh, y) | |||||
cairo_close_path(cr) | |||||
cairo_set_source_rgb(cr, 1, 1, 1) | |||||
cairo_fill(cr) | |||||
y = y - 2 | |||||
cairo_move_to(cr, x + scaleh, y) | |||||
for i = cur+1,100 do | |||||
cairo_line_to(cr, x + (i - cur) * scaleh, y - hist[i] * scalev) | |||||
end | |||||
for i = 1,cur do | |||||
cairo_line_to(cr, x + ((100 - cur) + i) * scaleh, y - hist[i] * scalev) | |||||
end | |||||
cairo_line_to(cr, x + 100 * scaleh, y) | |||||
cairo_close_path(cr) | |||||
cairo_set_source_rgb(cr, 0, 0, 0) | |||||
cairo_fill(cr) | |||||
y = y + 1 | |||||
cairo_move_to(cr, x + scaleh, y) | |||||
for i = cur+1,100 do | |||||
cairo_line_to(cr, x + (i - cur) * scaleh, y - hist[i] * scalev) | |||||
end | |||||
for i = 1,cur do | |||||
cairo_line_to(cr, x + ((100 - cur) + i) * scaleh, y - hist[i] * scalev) | |||||
end | |||||
cairo_line_to(cr, x + 100 * scaleh, y) | |||||
cairo_close_path(cr) | |||||
cairo_set_source_rgba(cr, color[1], color[2], color[3], 1) | |||||
cairo_fill(cr) | |||||
end | |||||
function max(hist) | |||||
local i | |||||
local max = 0 | |||||
for i=1,#hist do | |||||
if hist[i] > max then max = hist[i] end | |||||
end | |||||
return max | |||||
end |
@@ -0,0 +1,40 @@ | |||||
conky.config = { | |||||
alignment = 'top_left', | |||||
background = true, | |||||
border_width = 0, | |||||
cpu_avg_samples = 2, | |||||
default_color = 'grey', | |||||
default_outline_color = 'white', | |||||
default_shade_color = 'white', | |||||
draw_borders = false, | |||||
draw_graph_borders = false, | |||||
draw_outline = false, | |||||
draw_shades = false, | |||||
use_xft = true, | |||||
minimum_width = 1920, | |||||
minimum_height = 1080, | |||||
gap_x = 5, | |||||
gap_y = 5, | |||||
net_avg_samples = 2, | |||||
no_buffers = true, | |||||
out_to_console = false, | |||||
out_to_stderr = false, | |||||
extra_newline = false, | |||||
own_window = true, | |||||
own_window_class = 'Conky', | |||||
own_window_type = 'desktop', | |||||
own_window_argb_visual = true, | |||||
own_window_transparent = true, | |||||
stippled_borders = 0, | |||||
update_interval = 1.0, | |||||
update_interval_on_battery = 10, | |||||
uppercase = false, | |||||
use_spacer = none, | |||||
show_graph_scale = false, | |||||
show_graph_range = false, | |||||
double_buffer = true, | |||||
lua_load = '~/.config/conky/conky.lua', | |||||
lua_draw_hook_pre = 'init' | |||||
} | |||||
conky.text = [[]] |
@@ -0,0 +1,245 @@ | |||||
[global] | |||||
font = FontAwesome 24 | |||||
# Allow a small subset of html markup: | |||||
# <b>bold</b> | |||||
# <i>italic</i> | |||||
# <s>strikethrough</s> | |||||
# <u>underline</u> | |||||
# | |||||
# For a complete reference see | |||||
# <http://developer.gnome.org/pango/stable/PangoMarkupFormat.html>. | |||||
# If markup is not allowed, those tags will be stripped out of the | |||||
# message. | |||||
allow_markup = yes | |||||
# The format of the message. Possible variables are: | |||||
# %a appname | |||||
# %s summary | |||||
# %b body | |||||
# %i iconname (including its path) | |||||
# %I iconname (without its path) | |||||
# %p progress value if set ([ 0%] to [100%]) or nothing | |||||
# Markup is allowed | |||||
format = "<b>%s</b>\n%b" | |||||
# Sort messages by urgency. | |||||
sort = no | |||||
# Show how many messages are currently hidden (because of geometry). | |||||
indicate_hidden = no | |||||
# Alignment of message text. | |||||
# Possible values are "left", "center" and "right". | |||||
alignment = center | |||||
# The frequency with wich text that is longer than the notification | |||||
# window allows bounces back and forth. | |||||
# This option conflicts with "word_wrap". | |||||
# Set to 0 to disable. | |||||
bounce_freq = 0 | |||||
# Show age of message if message is older than show_age_threshold | |||||
# seconds. | |||||
# Set to -1 to disable. | |||||
show_age_threshold = -1 | |||||
# Split notifications into multiple lines if they don't fit into | |||||
# geometry. | |||||
word_wrap = yes | |||||
# Ignore newlines '\n' in notifications. | |||||
ignore_newline = no | |||||
# The geometry of the window: | |||||
# [{width}]x{height}[+/-{x}+/-{y}] | |||||
# The geometry of the message window. | |||||
# The height is measured in number of notifications everything else | |||||
# in pixels. If the width is omitted but the height is given | |||||
# ("-geometry x2"), the message window expands over the whole screen | |||||
# (dmenu-like). If width is 0, the window expands to the longest | |||||
# message displayed. A positive x is measured from the left, a | |||||
# negative from the right side of the screen. Y is measured from | |||||
# the top and down respectevly. | |||||
# The width can be negative. In this case the actual width is the | |||||
# screen width minus the width defined in within the geometry option. | |||||
geometry = "400x1+760+420" | |||||
# Shrink window if it's smaller than the width. Will be ignored if | |||||
# width is 0. | |||||
shrink = no | |||||
# The transparency of the window. Range: [0; 100]. | |||||
# This option will only work if a compositing windowmanager is | |||||
# present (e.g. xcompmgr, compiz, etc.). | |||||
transparency = 30 | |||||
# Don't remove messages, if the user is idle (no mouse or keyboard input) | |||||
# for longer than idle_threshold seconds. | |||||
# Set to 0 to disable. | |||||
idle_threshold = 0 | |||||
# Which monitor should the notifications be displayed on. | |||||
monitor = 0 | |||||
# Display notification on focused monitor. Possible modes are: | |||||
# mouse: follow mouse pointer | |||||
# keyboard: follow window with keyboard focus | |||||
# none: don't follow anything | |||||
# | |||||
# "keyboard" needs a windowmanager that exports the | |||||
# _NET_ACTIVE_WINDOW property. | |||||
# This should be the case for almost all modern windowmanagers. | |||||
# | |||||
# If this option is set to mouse or keyboard, the monitor option | |||||
# will be ignored. | |||||
follow = keyboard | |||||
# Should a notification popped up from history be sticky or timeout | |||||
# as if it would normally do. | |||||
sticky_history = yes | |||||
# Maximum amount of notifications kept in history | |||||
history_length = 0 | |||||
# Display indicators for URLs (U) and actions (A). | |||||
show_indicators = yes | |||||
# The height of a single line. If the height is smaller than the | |||||
# font height, it will get raised to the font height. | |||||
# This adds empty space above and under the text. | |||||
line_height = 0 | |||||
# Draw a line of "separatpr_height" pixel height between two | |||||
# notifications. | |||||
# Set to 0 to disable. | |||||
separator_height = 2 | |||||
# Padding between text and separator. | |||||
padding = 8 | |||||
# Horizontal padding. | |||||
horizontal_padding = 8 | |||||
# Define a color for the separator. | |||||
# possible values are: | |||||
# * auto: dunst tries to find a color fitting to the background; | |||||
# * foreground: use the same color as the foreground; | |||||
# * frame: use the same color as the frame; | |||||
# * anything else will be interpreted as a X color. | |||||
separator_color = frame | |||||
# Print a notification on startup. | |||||
# This is mainly for error detection, since dbus (re-)starts dunst | |||||
# automatically after a crash. | |||||
startup_notification = false | |||||
# dmenu path. | |||||
dmenu = /usr/bin/dmenu -p dunst: | |||||
# Browser for opening urls in context menu. | |||||
browser = /usr/bin/firefox -new-tab | |||||
# Align icons left/right/off | |||||
icon_position = off | |||||
# Paths to default icons. | |||||
icon_folders = /usr/share/icons/gnome/16x16/status/:/usr/share/icons/gnome/16x16/devices/ | |||||
[frame] | |||||
width = 0 | |||||
color = "#aaaaaa" | |||||
[shortcuts] | |||||
# Shortcuts are specified as [modifier+][modifier+]...key | |||||
# Available modifiers are "ctrl", "mod1" (the alt-key), "mod2", | |||||
# "mod3" and "mod4" (windows-key). | |||||
# Xev might be helpful to find names for keys. | |||||
# Close notification. | |||||
close = ctrl+space | |||||
# Close all notifications. | |||||
close_all = ctrl+shift+space | |||||
# Redisplay last message(s). | |||||
# On the US keyboard layout "grave" is normally above TAB and left | |||||
# of "1". | |||||
history = ctrl+grave | |||||
# Context menu. | |||||
context = ctrl+shift+period | |||||
[urgency_low] | |||||
# IMPORTANT: colors have to be defined in quotation marks. | |||||
# Otherwise the "#" and following would be interpreted as a comment. | |||||
background = "#222222" | |||||
foreground = "#CCCCCC" | |||||
timeout = 1 | |||||
[urgency_normal] | |||||
background = "#222222" | |||||
foreground = "#CCCCCC" | |||||
timeout = 1 | |||||
[urgency_critical] | |||||
background = "#222222" | |||||
foreground = "#CCCCCC" | |||||
timeout = 0 | |||||
# Every section that isn't one of the above is interpreted as a rules to | |||||
# override settings for certain messages. | |||||
# Messages can be matched by "appname", "summary", "body", "icon", "category", | |||||
# "msg_urgency" and you can override the "timeout", "urgency", "foreground", | |||||
# "background", "new_icon" and "format". | |||||
# Shell-like globbing will get expanded. | |||||
# | |||||
# SCRIPTING | |||||
# You can specify a script that gets run when the rule matches by | |||||
# setting the "script" option. | |||||
# The script will be called as follows: | |||||
# script appname summary body icon urgency | |||||
# where urgency can be "LOW", "NORMAL" or "CRITICAL". | |||||
# | |||||
# NOTE: if you don't want a notification to be displayed, set the format | |||||
# to "". | |||||
# NOTE: It might be helpful to run dunst -print in a terminal in order | |||||
# to find fitting options for rules. | |||||
#[espeak] | |||||
# summary = "*" | |||||
# script = dunst_espeak.sh | |||||
#[script-test] | |||||
# summary = "*script*" | |||||
# script = dunst_test.sh | |||||
#[ignore] | |||||
# # This notification will not be displayed | |||||
# summary = "foobar" | |||||
# format = "" | |||||
#[signed_on] | |||||
# appname = Pidgin | |||||
# summary = "*signed on*" | |||||
# urgency = low | |||||
# | |||||
#[signed_off] | |||||
# appname = Pidgin | |||||
# summary = *signed off* | |||||
# urgency = low | |||||
# | |||||
#[says] | |||||
# appname = Pidgin | |||||
# summary = *says* | |||||
# urgency = critical | |||||
# | |||||
#[twitter] | |||||
# appname = Pidgin | |||||
# summary = *twitter.com* | |||||
# urgency = normal | |||||
# | |||||
# vim: ft=cfg |
@@ -0,0 +1,908 @@ | |||||
# vim:fileencoding=utf-8:ft=conf:foldmethod=marker | |||||
#: Fonts {{{ | |||||
#: kitty has very powerful font management. You can configure | |||||
#: individual font faces and even specify special fonts for particular | |||||
#: characters. | |||||
font_family Fira Code | |||||
# bold_font auto | |||||
italic_font Fira Code Italic | |||||
# bold_italic_font auto | |||||
#: You can specify different fonts for the bold/italic/bold-italic | |||||
#: variants. By default they are derived automatically, by the OSes | |||||
#: font system. Setting them manually is useful for font families that | |||||
#: have many weight variants like Book, Medium, Thick, etc. For | |||||
#: example:: | |||||
#: font_family Operator Mono Book | |||||
#: bold_font Operator Mono Medium | |||||
#: italic_font Operator Mono Book Italic | |||||
#: bold_italic_font Operator Mono Medium Italic | |||||
font_size 9 | |||||
#: Font size (in pts) | |||||
# adjust_line_height 0 | |||||
# adjust_column_width 0 | |||||
#: Change the size of each character cell kitty renders. You can use | |||||
#: either numbers, which are interpreted as pixels or percentages | |||||
#: (number followed by %), which are interpreted as percentages of the | |||||
#: unmodified values. You can use negative pixels or percentages less | |||||
#: than 100% to reduce sizes (but this might cause rendering | |||||
#: artifacts). | |||||
# symbol_map U+E0A0-U+E0A2,U+E0B0-U+E0B3 PowerlineSymbols | |||||
#: Map the specified unicode codepoints to a particular font. Useful | |||||
#: if you need special rendering for some symbols, such as for | |||||
#: Powerline. Avoids the need for patched fonts. Each unicode code | |||||
#: point is specified in the form U+<code point in hexadecimal>. You | |||||
#: can specify multiple code points, separated by commas and ranges | |||||
#: separated by hyphens. symbol_map itself can be specified multiple | |||||
#: times. Syntax is:: | |||||
#: symbol_map codepoints Font Family Name | |||||
# box_drawing_scale 0.001, 1, 1.5, 2 | |||||
#: Change the sizes of the lines used for the box drawing unicode | |||||
#: characters These values are in pts. They will be scaled by the | |||||
#: monitor DPI to arrive at a pixel value. There must be four values | |||||
#: corresponding to thin, normal, thick, and very thick lines. | |||||
#: }}} | |||||
#: Cursor customization {{{ | |||||
# cursor #cccccc | |||||
#: Default cursor color | |||||
# cursor_text_color #111111 | |||||
#: Choose the color of text under the cursor. If you want it rendered | |||||
#: with the background color of the cell underneath instead, use the | |||||
#: special keyword: background | |||||
# cursor_shape block | |||||
#: The cursor shape can be one of (block, beam, underline) | |||||
# cursor_blink_interval 0.5 | |||||
# cursor_stop_blinking_after 15.0 | |||||
#: The interval (in seconds) at which to blink the cursor. Set to zero | |||||
#: to disable blinking. Note that numbers smaller than repaint_delay | |||||
#: will be limited to repaint_delay. Stop blinking cursor after the | |||||
#: specified number of seconds of keyboard inactivity. Set to zero to | |||||
#: never stop blinking. | |||||
#: }}} | |||||
#: Scrollback {{{ | |||||
# scrollback_lines 2000 | |||||
#: Number of lines of history to keep in memory for scrolling back. | |||||
#: Memory is allocated on demand. Negative numbers are (effectively) | |||||
#: infinite scrollback. Note that using very large scrollback is not | |||||
#: recommended a it can slow down resizing of the terminal and also | |||||
#: use large amounts of RAM. | |||||
# scrollback_pager less --chop-long-lines --RAW-CONTROL-CHARS +INPUT_LINE_NUMBER | |||||
#: Program with which to view scrollback in a new window. The | |||||
#: scrollback buffer is passed as STDIN to this program. If you change | |||||
#: it, make sure the program you use can handle ANSI escape sequences | |||||
#: for colors and text formatting. INPUT_LINE_NUMBER in the command | |||||
#: line above will be replaced by an integer representing which line | |||||
#: should be at the top of the screen. | |||||
wheel_scroll_multiplier 4.0 | |||||
#: Modify the amount scrolled by the mouse wheel. Note this is only | |||||
#: used for low precision scrolling devices, not for high precision | |||||
#: scrolling on platforms such as macOS and Wayland. Use negative | |||||
#: numbers to change scroll direction. | |||||
#: }}} | |||||
#: Mouse {{{ | |||||
# url_color #0087BD | |||||
# url_style curly | |||||
#: The color and style for highlighting URLs on mouse-over. url_style | |||||
#: can be one of: none, single, double, curly | |||||
# open_url_modifiers kitty_mod | |||||
#: The modifier keys to press when clicking with the mouse on URLs to | |||||
#: open the URL | |||||
# open_url_with default | |||||
#: The program with which to open URLs that are clicked on. The | |||||
#: special value default means to use the operating system's default | |||||
#: URL handler. | |||||
# copy_on_select no | |||||
#: Copy to clipboard on select. With this enabled, simply selecting | |||||
#: text with the mouse will cause the text to be copied to clipboard. | |||||
#: Useful on platforms such as macOS/Wayland that do not have the | |||||
#: concept of primary selections. Note that this is a security risk, | |||||
#: as all programs, including websites open in your browser can read | |||||
#: the contents of the clipboard. | |||||
# rectangle_select_modifiers ctrl+alt | |||||
#: The modifiers to use rectangular selection (i.e. to select text in | |||||
#: a rectangular block with the mouse) | |||||
# select_by_word_characters :@-./_~?&=%+# | |||||
#: Characters considered part of a word when double clicking. In | |||||
#: addition to these characters any character that is marked as an | |||||
#: alpha-numeric character in the unicode database will be matched. | |||||
# click_interval 0.5 | |||||
#: The interval between successive clicks to detect double/triple | |||||
#: clicks (in seconds) | |||||
# mouse_hide_wait 3.0 | |||||
#: Hide mouse cursor after the specified number of seconds of the | |||||
#: mouse not being used. Set to zero to disable mouse cursor hiding. | |||||
# focus_follows_mouse no | |||||
#: Set the active window to the window under the mouse when moving the | |||||
#: mouse around | |||||
#: }}} | |||||
#: Performance tuning {{{ | |||||
# repaint_delay 10 | |||||
#: Delay (in milliseconds) between screen updates. Decreasing it, | |||||
#: increases frames-per-second (FPS) at the cost of more CPU usage. | |||||
#: The default value yields ~100 FPS which is more than sufficient for | |||||
#: most uses. Note that to actually achieve 100 FPS you have to either | |||||
#: set sync_to_monitor to no or use a monitor with a high refresh | |||||
#: rate. | |||||
# input_delay 3 | |||||
#: Delay (in milliseconds) before input from the program running in | |||||
#: the terminal is processed. Note that decreasing it will increase | |||||
#: responsiveness, but also increase CPU usage and might cause flicker | |||||
#: in full screen programs that redraw the entire screen on each loop, | |||||
#: because kitty is so fast that partial screen updates will be drawn. | |||||
# sync_to_monitor yes | |||||
#: Sync screen updates to the refresh rate of the monitor. This | |||||
#: prevents tearing (https://en.wikipedia.org/wiki/Screen_tearing) | |||||
#: when scrolling. However, it limits the rendering speed to the | |||||
#: refresh rate of your monitor. With a very high speed mouse/high | |||||
#: keyboard repeat rate, you may notice some slight input latency. If | |||||
#: so, set this to no. | |||||
#: }}} | |||||
#: Terminal bell {{{ | |||||
# enable_audio_bell yes | |||||
#: Enable/disable the audio bell. Useful in environments that require | |||||
#: silence. | |||||
# visual_bell_duration 0.0 | |||||
#: Visual bell duration. Flash the screen when a bell occurs for the | |||||
#: specified number of seconds. Set to zero to disable. | |||||
# window_alert_on_bell yes | |||||
#: Request window attention on bell. Makes the dock icon bounce on | |||||
#: macOS or the taskbar flash on linux. | |||||
# bell_on_tab yes | |||||
#: Show a bell symbol on the tab if a bell occurs in one of the | |||||
#: windows in the tab and the window is not the currently focused | |||||
#: window | |||||
#: }}} | |||||
#: Window layout {{{ | |||||
# remember_window_size yes | |||||
# initial_window_width 640 | |||||
# initial_window_height 400 | |||||
#: If enabled, the window size will be remembered so that new | |||||
#: instances of kitty will have the same size as the previous | |||||
#: instance. If disabled, the window will initially have size | |||||
#: configured by initial_window_width/height, in pixels. You can use a | |||||
#: suffix of "c" on the width/height values to have them interpreted | |||||
#: as number of cells instead of pixels. | |||||
# enabled_layouts * | |||||
#: The enabled window layouts. A comma separated list of layout names. | |||||
#: The special value all means all layouts. The first listed layout | |||||
#: will be used as the startup layout. For a list of available | |||||
#: layouts, see the | |||||
#: https://sw.kovidgoyal.net/kitty/index.html#layouts. | |||||
# window_resize_step_cells 2 | |||||
# window_resize_step_lines 2 | |||||
#: The step size (in units of cell width/cell height) to use when | |||||
#: resizing windows. The cells value is used for horizontal resizing | |||||
#: and the lines value for vertical resizing. | |||||
# window_border_width 1.0 | |||||
#: The width (in pts) of window borders. Will be rounded to the | |||||
#: nearest number of pixels based on screen resolution. Note that | |||||
#: borders are displayed only when more than one window is visible. | |||||
#: They are meant to separate multiple windows. | |||||
# draw_minimal_borders yes | |||||
#: Draw only the minimum borders needed. This means that only the | |||||
#: minimum needed borders for inactive windows are drawn. That is only | |||||
#: the borders that separate the inactive window from a neighbor. Note | |||||
#: that setting a non-zero window margin overrides this and causes all | |||||
#: borders to be drawn. | |||||
# window_margin_width 0.0 | |||||
#: The window margin (in pts) (blank area outside the border) | |||||
# single_window_margin_width -1000.0 | |||||
#: The window margin (in pts) to use when only a single window is | |||||
#: visible. Negative values will cause the value of | |||||
#: window_margin_width to be used instead. | |||||
# window_padding_width 0.0 | |||||
#: The window padding (in pts) (blank area between the text and the | |||||
#: window border) | |||||
# active_border_color #00ff00 | |||||
#: The color for the border of the active window | |||||
# inactive_border_color #cccccc | |||||
#: The color for the border of inactive windows | |||||
# bell_border_color #ff5a00 | |||||
#: The color for the border of inactive windows in which a bell has | |||||
#: occurred | |||||
# inactive_text_alpha 1.0 | |||||
#: Fade the text in inactive windows by the specified amount (a number | |||||
#: between zero and one, with zero being fully faded). | |||||
#: }}} | |||||
#: Tab bar {{{ | |||||
# tab_bar_edge bottom | |||||
#: Which edge to show the tab bar on, top or bottom | |||||
# tab_bar_margin_width 0.0 | |||||
#: The margin to the left and right of the tab bar (in pts) | |||||
# tab_bar_style fade | |||||
#: The tab bar style, can be one of: fade or separator. In the fade | |||||
#: style, each tab's edges fade into the background color, in the | |||||
#: separator style, tabs are separated by a configurable separator. | |||||
# tab_fade 0.25 0.5 0.75 1 | |||||
#: Control how each tab fades into the background when using fade for | |||||
#: the tab_bar_style. Each number is an alpha (between zero and one) | |||||
#: that controls how much the corresponding cell fades into the | |||||
#: background, with zero being no fade and one being full fade. You | |||||
#: can change the number of cells used by adding/removing entries to | |||||
#: this list. | |||||
# tab_separator " ┇" | |||||
#: The separator between tabs in the tab bar when using separator as | |||||
#: the tab_bar_style. | |||||
# active_tab_foreground #000 | |||||
# active_tab_background #eee | |||||
# active_tab_font_style bold-italic | |||||
# inactive_tab_foreground #444 | |||||
# inactive_tab_background #999 | |||||
# inactive_tab_font_style normal | |||||
#: Tab bar colors and styles | |||||
#: }}} | |||||
#: Color scheme {{{ | |||||
background #202020 | |||||
foreground #CCCCCC | |||||
color0 #666666 | |||||
color8 #999999 | |||||
color1 #CC6699 | |||||
color9 #FF99CC | |||||
color2 #99CC66 | |||||
color10 #CCFF99 | |||||
color3 #CC9966 | |||||
color11 #FFCC99 | |||||
color4 #6699CC | |||||
color12 #99CCFF | |||||
color5 #9966CC | |||||
color13 #CC99FF | |||||
color6 #66CC99 | |||||
color14 #99FFCC | |||||
color7 #CCCCCC | |||||
color15 #FFFFFF | |||||
# foreground #dddddd | |||||
# background #000000 | |||||
#: The foreground and background colors | |||||
background_opacity .8 | |||||
dynamic_background_opacity yes | |||||
#: The opacity of the background. A number between 0 and 1, where 1 is | |||||
#: opaque and 0 is fully transparent. This will only work if | |||||
#: supported by the OS (for instance, when using a compositor under | |||||
#: X11). Note that it only sets the default background color's | |||||
#: opacity. This is so that things like the status bar in vim, | |||||
#: powerline prompts, etc. still look good. But it means that if you | |||||
#: use a color theme with a background color in your editor, it will | |||||
#: not be rendered as transparent. Instead you should change the | |||||
#: default background color in your kitty config and not use a | |||||
#: background color in the editor color scheme. Or use the escape | |||||
#: codes to set the terminals default colors in a shell script to | |||||
#: launch your editor. Be aware that using a value less than 1.0 is a | |||||
#: (possibly significant) performance hit. If you want to dynamically | |||||
#: change transparency of windows set dynamic_background_opacity to | |||||
#: yes (this is off by default as it has a performance cost) | |||||
# dim_opacity 0.75 | |||||
#: How much to dim text that has the DIM/FAINT attribute set. One | |||||
#: means no dimming and zero means fully dimmed (i.e. invisible). | |||||
# selection_foreground #000000 | |||||
# selection_background #FFFACD | |||||
#: The foreground and background for text selected with the mouse | |||||
#: The 16 terminal colors. There are 8 basic colors, each color has a | |||||
#: dull and bright version. You can also set the remaining colors from | |||||
#: the 256 color table as color16 to color255. | |||||
# color0 #000000 | |||||
# color8 #767676 | |||||
#: black | |||||
# color1 #cc0403 | |||||
# color9 #f2201f | |||||
#: red | |||||
# color2 #19cb00 | |||||
# color10 #23fd00 | |||||
#: green | |||||
# color3 #cecb00 | |||||
# color11 #fffd00 | |||||
#: yellow | |||||
# color4 #0d73cc | |||||
# color12 #1a8fff | |||||
#: blue | |||||
# color5 #cb1ed1 | |||||
# color13 #fd28ff | |||||
#: magenta | |||||
# color6 #0dcdcd | |||||
# color14 #14ffff | |||||
#: cyan | |||||
# color7 #dddddd | |||||
# color15 #ffffff | |||||
#: white | |||||
#: }}} | |||||
#: Advanced {{{ | |||||
# shell . | |||||
#: The shell program to execute. The default value of . means to use | |||||
#: whatever shell is set as the default shell for the current user. | |||||
#: Note that on macOS if you change this, you might need to add | |||||
#: --login to ensure that the shell starts in interactive mode and | |||||
#: reads its startup rc files. | |||||
# editor . | |||||
#: The console editor to use when editing the kitty config file or | |||||
#: similar tasks. A value of . means to use the environment variable | |||||
#: EDITOR. Note that this environment variable has to be set not just | |||||
#: in your shell startup scripts but system-wide, otherwise kitty will | |||||
#: not see it. | |||||
# close_on_child_death no | |||||
#: Close the window when the child process (shell) exits. If no (the | |||||
#: default), the terminal will remain open when the child exits as | |||||
#: long as there are still processes outputting to the terminal (for | |||||
#: example disowned or backgrounded processes). If yes, the window | |||||
#: will close as soon as the child process exits. Note that setting it | |||||
#: to yes means that any background processes still using the terminal | |||||
#: can fail silently because their stdout/stderr/stdin no longer work. | |||||
# allow_remote_control no | |||||
#: Allow other programs to control kitty. If you turn this on other | |||||
#: programs can control all aspects of kitty, including sending text | |||||
#: to kitty windows, opening new windows, closing windows, reading the | |||||
#: content of windows, etc. Note that this even works over ssh | |||||
#: connections. | |||||
# env | |||||
#: Specify environment variables to set in all child processes. Note | |||||
#: that environment variables are expanded recursively, so if you | |||||
#: use:: | |||||
#: env MYVAR1=a | |||||
#: env MYVAR2=${MYVAR}/${HOME}/b | |||||
#: The value of MYVAR2 will be a/<path to home directory>/b. | |||||
# startup_session none | |||||
#: Path to a session file to use for all kitty instances. Can be | |||||
#: overridden by using the kitty --session command line option for | |||||
#: individual instances. See | |||||
#: https://sw.kovidgoyal.net/kitty/index.html#sessions in the kitty | |||||
#: documentation for details. Note that relative paths are interpreted | |||||
#: with respect to the kitty config directory. Environment variables | |||||
#: in the path are expanded. | |||||
# clipboard_control write-clipboard write-primary | |||||
#: Allow programs running in kitty to read and write from the | |||||
#: clipboard. You can control exactly which actions are allowed. The | |||||
#: set of possible actions is: write-clipboard read-clipboard write- | |||||
#: primary read-primary The default is to allow writing to the | |||||
#: clipboard and primary selection. Note that enabling the read | |||||
#: functionality is a security risk as it means that any program, even | |||||
#: one running on a remote server via SSH can read your clipboard. | |||||
# term xterm-kitty | |||||
#: The value of the TERM environment variable to set. Changing this | |||||
#: can break many terminal programs, only change it if you know what | |||||
#: you are doing, not because you read some advice on Stack Overflow | |||||
#: to change it. The TERM variable if used by various programs to get | |||||
#: information about the capabilities and behavior of the terminal. If | |||||
#: you change it, depending on what programs you run, and how | |||||
#: different the terminal you are changing it to is, various things | |||||
#: from key-presses, to colors, to various advanced features may not | |||||
#: work. | |||||
#: }}} | |||||
#: OS specific tweaks {{{ | |||||
# macos_titlebar_color system | |||||
#: Change the color of the kitty window's titlebar on macOS. A value | |||||
#: of system means to use the default system color, a value of | |||||
#: background means to use the background color of the currently | |||||
#: active window and finally you can use an arbitrary color, such as | |||||
#: #12af59 or red. WARNING: This option works by using a hack, as | |||||
#: there is no proper Cocoa API for it. It sets the background color | |||||
#: of the entire window and makes the titlebar transparent. As such it | |||||
#: is incompatible with background_opacity. If you want to use both, | |||||
#: you are probably better off just hiding the titlebar with | |||||
#: macos_hide_titlebar. | |||||
# macos_hide_titlebar no | |||||
#: Hide the kitty window's title bar on macOS. | |||||
# x11_hide_window_decorations no | |||||
#: Hide the window decorations (title bar and window borders) on X11 | |||||
#: and Wayland. Whether this works and exactly what effect it has | |||||
#: depends on the window manager, as it is the job of the window | |||||
#: manager/compositor to draw window decorations. | |||||
# macos_option_as_alt yes | |||||
#: Use the option key as an alt key. With this set to no, kitty will | |||||
#: use the macOS native Option+Key = unicode character behavior. This | |||||
#: will break any Alt+key keyboard shortcuts in your terminal | |||||
#: programs, but you can use the macOS unicode input technique. | |||||
# macos_hide_from_tasks no | |||||
#: Hide the kitty window from running tasks (Option+Tab) on macOS. | |||||
# macos_quit_when_last_window_closed no | |||||
#: Have kitty quit when all the top-level windows are closed. By | |||||
#: default, kitty will stay running, even with no open windows, as is | |||||
#: the expected behavior on macOS. | |||||
# macos_window_resizable yes | |||||
#: Disable this if you want kitty top-level (OS) windows to not be | |||||
#: resizable on macOS. | |||||
# macos_thicken_font 0 | |||||
#: Draw an extra border around the font with the given width, to | |||||
#: increase legibility at small font sizes. For example, a value of | |||||
#: 0.75 will result in rendering that looks similar to sub-pixel | |||||
#: antialiasing at common font sizes. | |||||
# macos_traditional_fullscreen no | |||||
#: Use the traditional full-screen transition, that is faster, but | |||||
#: less pretty. | |||||
# macos_custom_beam_cursor no | |||||
#: Enable/disable custom mouse cursor for macOS that is easier to see | |||||
#: on both light and dark backgrounds. WARNING: this might make your | |||||
#: mouse cursor invisible on dual GPU machines. | |||||
#: }}} | |||||
#: Keyboard shortcuts {{{ | |||||
#: For a list of key names, see: GLFW keys | |||||
#: <http://www.glfw.org/docs/latest/group__keys.html>. The name to use | |||||
#: is the part after the GLFW_KEY_ prefix. For a list of modifier | |||||
#: names, see: GLFW mods | |||||
#: <http://www.glfw.org/docs/latest/group__mods.html> | |||||
#: On Linux you can also use XKB key names to bind keys that are not | |||||
#: supported by GLFW. See XKB keys | |||||
#: <https://github.com/xkbcommon/libxkbcommon/blob/master/xkbcommon/xkbcommon- | |||||
#: keysyms.h> for a list of key names. The name to use is the part | |||||
#: after the XKB_KEY_ prefix. Note that you should only use an XKB key | |||||
#: name for keys that are not present in the list of GLFW keys. | |||||
#: Finally, you can use raw system key codes to map keys. To see the | |||||
#: system key code for a key, start kitty with the kitty --debug- | |||||
#: keyboard option. Then kitty will output some debug text for every | |||||
#: key event. In that text look for ``native_code`` the value of that | |||||
#: becomes the key name in the shortcut. For example: | |||||
#: .. code-block:: none | |||||
#: on_key_input: glfw key: 65 native_code: 0x61 action: PRESS mods: 0x0 text: 'a' | |||||
#: Here, the key name for the A key is 0x61 and you can use it with:: | |||||
#: map ctrl+0x61 something | |||||
#: to map ctrl+a to something. | |||||
#: You can use the special action no_op to unmap a keyboard shortcut | |||||
#: that is assigned in the default configuration. | |||||
#: You can combine multiple actions to be triggered by a single | |||||
#: shortcut, using the syntax below:: | |||||
#: map key combine <separator> action1 <separator> action2 <separator> action3 ... | |||||
#: For example:: | |||||
#: map kitty_mod+e combine : new_window : next_layout | |||||
#: this will create a new window and switch to the next available | |||||
#: layout | |||||
#: You can use multi-key shortcuts using the syntax shown below:: | |||||
#: map key1>key2>key3 action | |||||
#: For example:: | |||||
#: map ctrl+f>2 set_font_size 20 | |||||
# kitty_mod ctrl+shift | |||||
#: The value of kitty_mod is used as the modifier for all default | |||||
#: shortcuts, you can change it in your kitty.conf to change the | |||||
#: modifiers for all the default shortcuts. | |||||
# clear_all_shortcuts no | |||||
#: You can have kitty remove all shortcut definition seen up to this | |||||
#: point. Useful, for instance, to remove the default shortcuts. | |||||
#: Clipboard {{{ | |||||
# map kitty_mod+c copy_to_clipboard | |||||
# map kitty_mod+v paste_from_clipboard | |||||
# map kitty_mod+s paste_from_selection | |||||
# map shift+insert paste_from_selection | |||||
# map kitty_mod+o pass_selection_to_program | |||||
#: You can also pass the contents of the current selection to any | |||||
#: program using pass_selection_to_program. By default, the system's | |||||
#: open program is used, but you can specify your own, for example:: | |||||
#: map kitty_mod+o pass_selection_to_program firefox | |||||
#: You can pass the current selection to a terminal program running in | |||||
#: a new kitty window, by using the @selection placeholder:: | |||||
#: map kitty_mod+y new_window less @selection | |||||
#: }}} | |||||
#: Scrolling {{{ | |||||
# map kitty_mod+up scroll_line_up | |||||
# map kitty_mod+k scroll_line_up | |||||
# map kitty_mod+down scroll_line_down | |||||
# map kitty_mod+j scroll_line_down | |||||
# map kitty_mod+page_up scroll_page_up | |||||
# map kitty_mod+page_down scroll_page_down | |||||
# map kitty_mod+home scroll_home | |||||
# map kitty_mod+end scroll_end | |||||
# map kitty_mod+h show_scrollback | |||||
#: You can pipe the contents of the current screen + history buffer as | |||||
#: STDIN to an arbitrary program using the ``pipe`` function. For | |||||
#: example, the following opens the scrollback buffer in less in an | |||||
#: overlay window:: | |||||
#: map f1 pipe @ansi overlay less +G -R | |||||
#: Placeholders available are: @text (which is plain text) and @ansi | |||||
#: (which includes text styling escape codes). For only the current | |||||
#: screen, use @screen or @ansi_screen. For the secondary screen, use | |||||
#: @alternate and @ansi_alternate. The secondary screen is the screen | |||||
#: not currently displayed. For example if you run a fullscreen | |||||
#: terminal application, the secondary screen will be the screen you | |||||
#: return to when quitting the application. You can also use ``none`` | |||||
#: for no STDIN input. | |||||
#: To open in a new window, tab or new OS window, use ``window``, | |||||
#: ``tab``, or ``os_window`` respectively. You can also use ``none`` | |||||
#: in which case the data will be piped into the program without | |||||
#: creating any windows, useful if the program is a GUI program that | |||||
#: creates its own windows. | |||||
#: }}} | |||||
#: Window management {{{ | |||||
# map kitty_mod+enter new_window | |||||
#: You can open a new window running an arbitrary program, for | |||||
#: example:: | |||||
#: map kitty_mod+y new_window mutt | |||||
#: You can open a new window with the current working directory set to | |||||
#: the working directory of the current window using:: | |||||
#: map ctrl+alt+enter new_window_with_cwd | |||||
#: You can open a new window that is allowed to control kitty via the | |||||
#: kitty remote control facility by prefixing the command line with @. | |||||
#: Any programs running in that window will be allowed to control | |||||
#: kitty. For example:: | |||||
#: map ctrl+enter new_window @ some_program | |||||
# map kitty_mod+n new_os_window | |||||
# map kitty_mod+w close_window | |||||
# map kitty_mod+] next_window | |||||
# map kitty_mod+[ previous_window | |||||
# map kitty_mod+f move_window_forward | |||||
# map kitty_mod+b move_window_backward | |||||
# map kitty_mod+` move_window_to_top | |||||
# map kitty_mod+r start_resizing_window | |||||
# map kitty_mod+1 first_window | |||||
# map kitty_mod+2 second_window | |||||
# map kitty_mod+3 third_window | |||||
# map kitty_mod+4 fourth_window | |||||
# map kitty_mod+5 fifth_window | |||||
# map kitty_mod+6 sixth_window | |||||
# map kitty_mod+7 seventh_window | |||||
# map kitty_mod+8 eighth_window | |||||
# map kitty_mod+9 ninth_window | |||||
# map kitty_mod+0 tenth_window | |||||
#: }}} | |||||
#: Tab management {{{ | |||||
# map kitty_mod+right next_tab | |||||
# map kitty_mod+left previous_tab | |||||
# map kitty_mod+t new_tab | |||||
# map kitty_mod+q close_tab | |||||
# map kitty_mod+. move_tab_forward | |||||
# map kitty_mod+, move_tab_backward | |||||
# map kitty_mod+alt+t set_tab_title | |||||
#: You can also create shortcuts to go to specific tabs, with 1 being | |||||
#: the first tab:: | |||||
#: map ctrl+alt+1 goto_tab 1 | |||||
#: map ctrl+alt+2 goto_tab 2 | |||||
#: Just as with new_window above, you can also pass the name of | |||||
#: arbitrary commands to run when using new_tab and use | |||||
#: new_tab_with_cwd. Finally, if you want the new tab to open next to | |||||
#: the current tab rather than at the end of the tabs list, use:: | |||||
#: map ctrl+t new_tab !neighbor [optional cmd to run] | |||||
#: }}} | |||||
#: Layout management {{{ | |||||
# map kitty_mod+l next_layout | |||||
#: You can also create shortcuts to switch to specific layouts:: | |||||
#: map ctrl+alt+t goto_layout tall | |||||
#: map ctrl+alt+s goto_layout stack | |||||
#: Similarly, to switch back to the previous layout:: | |||||
#: map ctrl+alt+p last_used_layout | |||||
#: }}} | |||||
#: Font sizes {{{ | |||||
#: You can change the font size for all top-level kitty windows at a | |||||
#: time or only the current one. | |||||
# map kitty_mod+equal change_font_size all +2.0 | |||||
# map kitty_mod+minus change_font_size all -2.0 | |||||
# map kitty_mod+backspace change_font_size all 0 | |||||
#: To setup shortcuts for specific font sizes:: | |||||
#: map kitty_mod+f6 change_font_size all 10.0 | |||||
#: To setup shortcuts to change only the current window's font size:: | |||||
#: map kitty_mod+f6 change_font_size current 10.0 | |||||
#: }}} | |||||
#: Select and act on visible text {{{ | |||||
#: Use the hints kitten to select text and either pass it to an | |||||
#: external program or insert it into the terminal or copy it to the | |||||
#: clipboard. | |||||
# map kitty_mod+e kitten hints | |||||
#: Open a currently visible URL using the keyboard. The program used | |||||
#: to open the URL is specified in open_url_with. | |||||
# map kitty_mod+p>f kitten hints --type path --program - | |||||
#: Select a path/filename and insert it into the terminal. Useful, for | |||||
#: instance to run git commands on a filename output from a previous | |||||
#: git command. | |||||
# map kitty_mod+p>shift+f kitten hints --type path | |||||
#: Select a path/filename and open it with the default open program. | |||||
# map kitty_mod+p>l kitten hints --type line --program - | |||||
#: Select a line of text and insert it into the terminal. Use for the | |||||
#: output of things like: ls -1 | |||||
# map kitty_mod+p>w kitten hints --type word --program - | |||||
#: Select words and insert into terminal. | |||||
# map kitty_mod+p>h kitten hints --type hash --program - | |||||
#: Select something that looks like a hash and insert it into the | |||||
#: terminal. Useful with git, which uses sha1 hashes to identify | |||||
#: commits | |||||
#: The hints kitten has many more modes of operation that you can map | |||||
#: to different shortcuts. For a full description see kittens/hints. | |||||
#: }}} | |||||
#: Miscellaneous {{{ | |||||
# map kitty_mod+f11 toggle_fullscreen | |||||
# map kitty_mod+u kitten unicode_input | |||||
# map kitty_mod+f2 edit_config_file | |||||
# map kitty_mod+escape kitty_shell window | |||||
#: Open the kitty shell in a new window/tab/overlay/os_window to | |||||
#: control kitty using commands. | |||||
# map kitty_mod+a>m set_background_opacity +0.1 | |||||
# map kitty_mod+a>l set_background_opacity -0.1 | |||||
# map kitty_mod+a>1 set_background_opacity 1 | |||||
# map kitty_mod+a>d set_background_opacity default | |||||
# map kitty_mod+delete clear_terminal reset active | |||||
#: You can create shortcuts to clear/reset the terminal. For example:: | |||||
#: map kitty_mod+f9 clear_terminal reset active | |||||
#: map kitty_mod+f10 clear_terminal clear active | |||||
#: map kitty_mod+f11 clear_terminal scrollback active | |||||
#: These will reset screen/clear screen/clear screen+scrollback | |||||
#: respectively. If you want to operate on all windows instead of just | |||||
#: the current one, use all instead of :italic`active`. | |||||
#: You can tell kitty to send arbitrary (UTF-8) encoded text to the | |||||
#: client program when pressing specified shortcut keys. For example:: | |||||
#: map ctrl+alt+a send_text all Special text | |||||
#: This will send "Special text" when you press the ctrl+alt+a key | |||||
#: combination. The text to be sent is a python string literal so you | |||||
#: can use escapes like \x1b to send control codes or \u21fb to send | |||||
#: unicode characters (or you can just input the unicode characters | |||||
#: directly as UTF-8 text). The first argument to send_text is the | |||||
#: keyboard modes in which to activate the shortcut. The possible | |||||
#: values are normal or application or kitty or a comma separated | |||||
#: combination of them. The special keyword all means all modes. The | |||||
#: modes normal and application refer to the DECCKM cursor key mode | |||||
#: for terminals, and kitty refers to the special kitty extended | |||||
#: keyboard protocol. | |||||
#: Another example, that outputs a word and then moves the cursor to | |||||
#: the start of the line (same as pressing the Home key):: | |||||
#: map ctrl+alt+a send_text normal Word\x1b[H | |||||
#: map ctrl+alt+a send_text application Word\x1bOH | |||||
#: }}} | |||||
# }}} |
@@ -0,0 +1,21 @@ | |||||
[Default Applications] | |||||
x-scheme-handler/magnet=transmission.desktop | |||||
x-scheme-handler/http=qutebrowser.desktop | |||||
x-scheme-handler/https=qutebrowser.desktop | |||||
x-scheme-handler/ftp=qutebrowser.desktop | |||||
x-scheme-handler/chrome=qutebrowser.desktop | |||||
text/html=qutebrowser.desktop | |||||
application/octet-stream=qutebrowser.desktop | |||||
application/x-extension-htm=qutebrowser.desktop | |||||
application/x-extension-html=qutebrowser.desktop | |||||
application/x-extension-shtml=qutebrowser.desktop | |||||
application/xhtml+xml=qutebrowser.desktop | |||||
application/x-extension-xhtml=qutebrowser.desktop | |||||
application/x-extension-xht=qutebrowser.desktop | |||||
x-scheme-handler/tg=telegramdesktop.desktop | |||||
application/pdf=org.pwmt.zathura.desktop | |||||
image/jpeg=sxiv.desktop | |||||
[Added Associations] | |||||
text/csv=libreoffice-calc.desktop; | |||||
application/vnd.ms-excel=libreoffice-calc.desktop; |
@@ -0,0 +1,232 @@ | |||||
# 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 ignore | |||||
MOUSE_BTN4 ignore | |||||
MOUSE_BTN5 ignore | |||||
MOUSE_BTN6 ignore | |||||
# 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 ignore | |||||
AXIS_DOWN ignore | |||||
AXIS_LEFT ignore | |||||
AXIS_RIGHT ignore | |||||
a cycle audio | |||||
KP7 seek -3 | |||||
KP9 seek 3 | |||||
KP4 seek -30 | |||||
KP6 seek 30 | |||||
KP1 seek -60 | |||||
KP3 seek 60 | |||||
KP2 add volume -2 | |||||
KP8 add volume 2 | |||||
/ add sub-delay -0.1 | |||||
* add sub-delay 0.1 | |||||
+ add audio-delay -0.1 | |||||
- add audio-delay 0.1 | |||||
n playlist_next | |||||
m playlist_prev | |||||
KP0 show_progress | |||||
w show_text "${playlist}" | |||||
## 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 | |||||
#ESC set fullscreen no | |||||
#ESC {encode} quit | |||||
#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 osd # 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 | |||||
#d cycle framedrop # cycle through framedrop modes | |||||
# 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 ass-vsfilter-aspect-compat | |||||
#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 | |||||
#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 | |||||
#MENU cycle osd | |||||
#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 | |||||
#E cycle edition # next edition | |||||
#l ab_loop # Set/clear A-B loop points | |||||
#ctrl+c quit | |||||
# 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 | |||||
# Joystick section | |||||
# WARNING: joystick support has to be explicitly enabled at | |||||
# compiletime with --enable-joystick | |||||
# | |||||
#JOY_AXIS0_PLUS seek 10 | |||||
#JOY_AXIS0_MINUS seek -10 | |||||
#JOY_AXIS1_MINUS seek 60 | |||||
#JOY_AXIS1_PLUS seek -60 | |||||
#JOY_BTN0 cycle pause | |||||
#JOY_BTN1 cycle osd | |||||
#JOY_BTN2 add volume 2 | |||||
#JOY_BTN3 add volume -2 | |||||
# For dvdnav:// and bdnav:// | |||||
# navigation controls during playback | |||||
#ENTER {discnav} discnav menu # DISCNAV MENU | |||||
# BS {discnav} discnav prev # DISCNAV PREVIOUS menu (in the order chapter->title->root) | |||||
# navigation controls when showing menu (additionally to the controls above) | |||||
#UP {discnav-menu} discnav up # DISCNAV UP | |||||
#DOWN {discnav-menu} discnav down # DISCNAV DOWN | |||||
#LEFT {discnav-menu} discnav left # DISCNAV LEFT | |||||
#RIGHT {discnav-menu} discnav right # DISCNAV RIGHT | |||||
#ENTER {discnav-menu} discnav select # DISCNAV SELECT (ok) | |||||
#MOUSE_BTN0 {discnav-menu} discnav mouse | |||||
#MOUSE_MOVE {discnav-menu} discnav mouse_move | |||||
# For tv:// | |||||
#h cycle tv-channel -1 # previous channel | |||||
#k cycle tv-channel +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_values window-scale 0.5 2 1 # switch between 1/2, 2x, unresized window size | |||||
# ? cycle colormatrix | |||||
# ? add audio-delay 0.100 # this changes audio/video sync | |||||
# ? add audio-delay -0.100 | |||||
# ? 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) |
@@ -0,0 +1,135 @@ | |||||
# | |||||
# mpv configuration file | |||||
# | |||||
# Configuration files are read system-wide from /usr/local/etc/mpv.conf | |||||
# and per-user from ~/.config/mpv/mpv.conf, where per-user settings override | |||||
# system-wide settings, all of which are overridden by the command line. | |||||
# | |||||
# Configuration file settings and the command line options use the same | |||||
# underlying mechanisms. Most options can be put into the configuration file | |||||
# by dropping the preceding '--'. See the man page for a complete list of | |||||
# options. | |||||
# | |||||
# Lines starting with '#' are comments and are ignored. | |||||
# | |||||
# See the CONFIGURATION FILES section in the man page | |||||
# for a detailed description of the syntax. | |||||
# | |||||
# Profiles should be placed at the bottom of the configuration file to ensure | |||||
# that settings wanted as defaults are not restricted to specific profiles. | |||||
# | |||||
# Note that the commented example options usually do _not_ set the default | |||||
# values. Calling mpv with --list-options is a nice way to see the default | |||||
# values for most options. | |||||
################## | |||||
# video settings # | |||||
################## | |||||
# Specify default video driver (see --vo=help for a list). | |||||
vo=gpu | |||||
# waitvsync=enabled | |||||
# Start in fullscreen mode by default. | |||||
fs=no | |||||
#vf=delogo=x:y:w:h:t(thickness fuzzy edge):show(show rectangle) #blur a tv logo | |||||
# force starting with centered window | |||||
#geometry=50%:50% | |||||
# don't allow a new window to have a size larger than 90% of the screen size | |||||
#autofit-larger=90%x90% | |||||
# Disable the On Screen Controller (OSC). | |||||
osc=no | |||||
# Keep the player window on top of all other windows. | |||||
#ontop=yes | |||||
################## | |||||
# audio settings # | |||||
################## | |||||
# Specify default audio driver (see --ao=help for a list). | |||||
#ao=alsa | |||||
# Disable softvol usage, and always use the system mixer if available. | |||||
# softvol=yes | |||||
# Scale audio tempo by playback speed without altering pitch. (By default does | |||||
# nothing if playback speed is not changed. May introduce artifacts.) | |||||
#af=scaletempo | |||||
#af=bs2b #binaural for headphones, uses libbs2b (install needed) | |||||
# af=drc=2:0.25 | |||||
# Output 5.1 audio natively, and upmix/downmix audio with a different format. | |||||
#audio-channels=5.1 | |||||
# Disable any automatic remix, _if_ the audio output accepts the audio format. | |||||
# of the currently played file. | |||||
#audio-channels=empty | |||||
################## | |||||
# other settings # | |||||
################## | |||||
sub-font-size=40 | |||||
osd-font-size=40 | |||||
keep-open=yes | |||||
osd-bar=no | |||||
# Pretend to be a web browser. Might fix playback with some streaming sites, | |||||
# but also will break with shoutcast streams. | |||||
#user-agent="Mozilla/5.0" | |||||
# cache settings | |||||
# | |||||
# Use 8MB input cache by default. The cache is enabled for network streams only. | |||||
#cache-default=8192 | |||||
# | |||||
# Use 8MB input cache for everything, even local files. | |||||
#cache=8192 | |||||
# | |||||
# If a seek is issued, and the target is 1024KB past the cached range, then | |||||
# keep reading until the seek target is hit, instead of doing a real seek. | |||||
#cache-seek-min=1024 | |||||
# | |||||
# Disable the behavior that the player will pause if the cache goes below a | |||||
# certain fill size. | |||||
#cache-pause=no | |||||
# | |||||
# Read ahead about 5 seconds of audio and video packets. | |||||
#demuxer-readahead-secs=5.0 | |||||
# Display English subtitles if available. | |||||
slang=en | |||||
# Play Finnish audio if available, fall back to English otherwise. | |||||
alang=en | |||||
# Change subtitle encoding. For Arabic subtitles use 'cp1256'. | |||||
# If the file seems to be valid UTF-8, prefer UTF-8. | |||||
#sub-codepage=utf8:cp1256 | |||||
# Enable hardware decoding if available. Often, this requires using an certain | |||||
# video output, otherwise no hardware decoding will be used. | |||||
hwdec=vaapi | |||||
############ | |||||
# Profiles # | |||||
############ | |||||
# The options declared as part of profiles override global default settings, | |||||
# but only take effect when the profile is active. | |||||
# The following profile can be enabled on the command line with: --profile=vdpau | |||||
#[vdpau] | |||||
# The profile forces the vdpau VO. | |||||
#vo=vdpau | |||||
# Use hardware decoding (this might break playback of some h264 files) | |||||
#hwdec=vdpau | |||||
# Most video filters do not work with hardware decoding. | |||||
#vf-clr=yes | |||||
# You can also include other configuration files. | |||||
#include=/path/to/the/file/you/want/to/include |
@@ -0,0 +1,46 @@ | |||||
snippet doc | |||||
#' ${1:Title} | |||||
#' | |||||
#' ${2:Description} | |||||
#' | |||||
#' ${3:Description text} | |||||
#' | |||||
#' @param $4 | |||||
#' @return $5 | |||||
#' @export | |||||
#' @examples | |||||
#' $6 | |||||
endsnippet | |||||
snippet fun | |||||
function($1) | |||||
{ | |||||
$2 | |||||
} | |||||
endsnippet | |||||
snippet if | |||||
if ($1) | |||||
{ | |||||
$2 | |||||
} | |||||
endsnippet | |||||
snippet ifelse | |||||
ifelse($1, $2, $3) | |||||
endsnippet | |||||
snippet case | |||||
case_when($1 ~ $2, | |||||
$3 ~ $4, | |||||
${5:T} ~ $6) | |||||
endsnippet | |||||
snippet lib | |||||
library(${1:tidyverse}) | |||||
endsnippet |
@@ -0,0 +1,50 @@ | |||||
snippet --- | |||||
--- | |||||
title: $1 | |||||
output: | |||||
$2_document: | |||||
--- | |||||
endsnippet | |||||
snippet opts | |||||
opts_chunk$set(echo = ${1:F}, | |||||
message = ${2:F}, | |||||
error = ${3:F}, | |||||
warning = ${4:F}, | |||||
fig.width = ${5:12}, | |||||
fig.height = ${6:7}) | |||||
endsnippet | |||||
snippet fun | |||||
function($1) | |||||
{ | |||||
$2 | |||||
} | |||||
endsnippet | |||||
snippet if | |||||
if ($1) | |||||
{ | |||||
$2 | |||||
} | |||||
endsnippet | |||||
snippet ifelse | |||||
ifelse($1, $2, $3) | |||||
endsnippet | |||||
snippet case | |||||
case_when($1 ~ $2, | |||||
$3 ~ $4, | |||||
${5:T} ~ $6) | |||||
endsnippet | |||||
snippet lib | |||||
library(${1:tidyverse}) | |||||
endsnippet |
@@ -0,0 +1,13 @@ | |||||
noremap <buffer> D D | |||||
augroup custom_fugitive | |||||
autocmd! | |||||
autocmd VimEnter,BufWinEnter * if !empty(maparg('dd', 'n')) | | |||||
\ unmap <buffer> dd| | |||||
\ unmap <buffer> dp| | |||||
\ unmap <buffer> dv| | |||||
\ unmap <buffer> ds| | |||||
\ unmap <buffer> dh| | |||||
\ unmap <buffer> s| | |||||
\ endif | |||||
augroup END |
@@ -0,0 +1 @@ | |||||
set nofoldenable |
@@ -0,0 +1,12 @@ | |||||
noremap <buffer> D D | |||||
augroup custom_fugitive | |||||
autocmd! | |||||
autocmd VimEnter,BufWinEnter * if !empty(maparg('dd', 'n')) | | |||||
\ unmap <buffer> dd| | |||||
\ unmap <buffer> dp| | |||||
\ unmap <buffer> dv| | |||||
\ unmap <buffer> ds| | |||||
\ unmap <buffer> dh| | |||||
\ endif | |||||
augroup END |
@@ -0,0 +1 @@ | |||||
syntax region htmlFold start="<\z(\<\(area\|base\|br\|col\|command\|embed\|hr\|img\|input\|keygen\|link\|meta\|para\|source\|track\|wbr\>\)\@![a-z-]\+\>\)\%(\_s*\_[^/]\?>\|\_s\_[^>]*\_[^>/]>\)" end="</\z1\_s*>" fold transparent keepend extend |
@@ -0,0 +1,7 @@ | |||||
" vimcmdline options | |||||
nnoremap <buffer> <CR> :call VimCmdLineSendLine()<CR> | |||||
vnoremap <buffer> <CR> :call VimCmdLineSendSelection()<CR> | |||||
nnoremap <buffer> <leader>rq :call VimCmdLineQuit()<CR> | |||||
nnoremap <buffer> <F2> :call VimCmdLineStartApp()<CR> | |||||
let cmdline_term_height = 25 | |||||
@@ -0,0 +1,6 @@ | |||||
inoremap <buffer> » %>% | |||||
tnoremap » %>% | |||||
tnoremap <Space> | |||||
inoremap <Space> | |||||
" execute "normal \<Plug>RStart" |
@@ -0,0 +1,8 @@ | |||||
if !empty(maparg('\rl', 'n'))| | |||||
\ unmap <buffer> \rl| | |||||
\ endif | |||||
nmap <buffer> <silent> <leader>rd :call RAction(".View")<CR> | |||||
nmap <buffer> <silent> <leader>rl :call RAction("rm")<CR> | |||||
nmap <buffer> <silent> <leader>rg :call RAction("qplot")<CR> | |||||
nmap <buffer> <silent> <leader>rv :call RAction("table")<CR> |
@@ -0,0 +1,14 @@ | |||||
inoremap <buffer> » %>% | |||||
tnoremap » %>% | |||||
let b:surround_99 = "```{r \1name\1}\n\r\n```" | |||||
" execute "normal \<Plug>RStart" | |||||
" func! litprog#paintChunks() | |||||
" endfunc | |||||
" augroup paintChunksCmd | |||||
" autocmd! | |||||
" autocmd CursorHold * call litprog#paintChunks() | |||||
" augroup END |
@@ -0,0 +1 @@ | |||||
inoremap <silent><buffer> <expr><Right> pumvisible() ? "\<c-y>" : "\<CR>" |
@@ -0,0 +1,7 @@ | |||||
syntax match lambda "\\" conceal cchar=λ | |||||
syntax match div "//" conceal cchar=÷ | |||||
syntax match mul "*" conceal cchar=× | |||||
syntax match neq1 contained "/" conceal cchar=! containedin=neq | |||||
syntax match neq "/=" contains=neq1 | |||||
setlocal conceallevel=2 | |||||
setlocal concealcursor=nvic |
@@ -0,0 +1,8 @@ | |||||
syntax region rFold start="#.\{-}[-=]\{4,}" end="\n\ze\n#.\{-}[-=]\{4,}" fold transparent keepend | |||||
syntax match pipe1 contained "%" conceal cchar=| containedin=pipe | |||||
syntax match pipe2 contained ">%" conceal cchar=> containedin=pipe | |||||
syntax match pipe "%>%" contains=pipe1,pipe2 | |||||
syntax match mul "*" conceal cchar=× | |||||
syntax match in "%in%" conceal cchar=∈ | |||||
setlocal conceallevel=2 |
@@ -0,0 +1 @@ | |||||
syntax region rFold start="#.\{-}[-=]\{4,}" end="\n\ze\n#.\{-}[-=]\{4,}" fold transparent keepend |
@@ -0,0 +1,2 @@ | |||||
syn match vimMapRhs '.*\ze|\s*".*' | |||||
syn match vimLineComment '|\s*".*$' |
@@ -0,0 +1,66 @@ | |||||
#!/bin/bash | |||||
# | |||||
# This script converts markdown into html, to be used with vimwiki's | |||||
# "customwiki2html" option. Experiment with the two proposed methods by | |||||
# commenting / uncommenting the relevant lines below. | |||||
# | |||||
# NEW! An alternative converter was developed by Jason6Anderson, and can | |||||
# be located at https://github.com/vimwiki-backup/vimwiki/issues/384 | |||||
# | |||||
# | |||||
# To use this script, you must have the Discount converter installed. | |||||
# | |||||
# http://www.pell.portland.or.us/~orc/Code/discount/ | |||||
# | |||||
# To verify your installation, check that the commands markdown and mkd2text, | |||||
# are on your path. | |||||
# | |||||
# Also verify that this file is executable. | |||||
# | |||||
# Then, in your .vimrc file, set: | |||||
# | |||||
# g:vimwiki_customwiki2html=$HOME.'/.vim/autoload/vimwiki/customwiki2html.sh' | |||||
# | |||||
# On your next restart, Vimwiki will run this script instead of using the | |||||
# internal wiki2html converter. | |||||
# | |||||
MARKDOWN=markdown | |||||
MKD2HTML=mkd2html | |||||
FORCE="$1" | |||||
SYNTAX="$2" | |||||
EXTENSION="$3" | |||||
OUTPUTDIR="$4" | |||||
INPUT="$5" | |||||
CSSFILE="$6" | |||||
TPLPATH="$7" | |||||
TPLDEF="$8" | |||||
TPLEXT="$9" | |||||
FORCEFLAG= | |||||
[ $FORCE -eq 0 ] || { FORCEFLAG="-f"; }; | |||||
[ $SYNTAX = "markdown" ] || { echo "Error: Unsupported syntax"; exit -2; }; | |||||
OUTPUT="$OUTPUTDIR"/$(basename "$INPUT" .$EXTENSION).html | |||||
TPL="$TPLPATH$TPLDEF$TPLEXT" | |||||
# Method 1: | |||||
# markdown [-d] [-T] [-V] [-b url-base] [-C prefix] [-F bitmap] [-f flags] [-o file] [-s text] [-t text] [textfile] | |||||
OUT=`cat "$INPUT" | perl -pe 's/(\[.*?\]\(.*?)\)/\1.html)/g' | $MARKDOWN` | |||||
cat $TPL | perl -pe "s|%content%|$OUT|" > "$OUTPUT" | |||||
# Method 2: | |||||
# mkd2html [-css file] [-header string] [-footer string] [file] | |||||
# $MKD2HTML -css "$CSSFILE" "$INPUT" | |||||
# OUTPUTTMP=$(dirname "$INPUT")/$(basename "$INPUT" ."$EXTENSION").html | |||||
# mv -f "$OUTPUTTMP" "$OUTPUT" | |||||
@@ -0,0 +1,90 @@ | |||||
#! /usr/bin/env python | |||||
# -*- coding: utf-8 -*- | |||||
from __future__ import print_function | |||||
help_text = """ | |||||
Extracts tags from Elm files. Useful for the Tagbar plugin. | |||||
Usage: | |||||
Install Tagbar (http://majutsushi.github.io/tagbar/). Then, put this file | |||||
anywhere and add the following to your .vimrc: | |||||
let g:tagbar_type_elm = { | |||||
\ 'ctagstype':'elm' | |||||
\ , 'kinds':['h:header', 'i:import', 't:type', 'f:function'] | |||||
\ , 'sro':'&&&' | |||||
\ , 'kind2scope':{'h':'header', 'i:import', 't:type', 'f:function'} | |||||
\ , 'sort':0 | |||||
\ , 'ctagsbin':'/path/to/elmtags.py' | |||||
\ } | |||||
""" | |||||
import sys | |||||
import re | |||||
if len(sys.argv) < 2: | |||||
print(help_text) | |||||
exit() | |||||
filename = sys.argv[1] | |||||
re_header = re.compile(r"^-- (.*)$") | |||||
re_import = re.compile(r"^import ([^ \n]+)( as ([^ \n]+))?( exposing (\([^)]+\)))?") | |||||
re_type = re.compile(r"^type( alias)? ([^ \n]+)( =)?$") | |||||
re_function = re.compile(r"^([^ ]+) : (.*)$") | |||||
file_content = [] | |||||
try: | |||||
with open(filename, "r") as vim_buffer: | |||||
file_content = vim_buffer.readlines() | |||||
except: | |||||
exit() | |||||
cur_head = "" | |||||
for lnum, line in enumerate(file_content): | |||||
match_header = re_header.match(line) | |||||
match_import = re_import.match(line) | |||||
match_type = re_type.match(line) | |||||
match_function = re_function.match(line) | |||||
cur_searchterm = "" | |||||
cur_kind = "" | |||||
args = "" | |||||
lines = "" | |||||
if match_header: | |||||
cur_head = match_header.group(1) | |||||
cur_tag = cur_head | |||||
cur_searchterm = "^-- " + cur_tag + "$" | |||||
cur_kind = "h" | |||||
elif match_import: | |||||
cur_tag = match_import.group(1) | |||||
cur_searchterm = "^import " + cur_tag | |||||
cur_kind = "i" | |||||
args = "\theader:" + cur_head | |||||
if match_import.group(3): | |||||
args = args + "\tsignature:(" + cur_tag + ")" | |||||
cur_tag = match_import.group(3) | |||||
if match_import.group(5): | |||||
exposing = match_import.group(5).strip("()").replace(" ", "").split(",") | |||||
for exposed in exposing: | |||||
lines = lines + '\n{0}\t{1}\t/{2}/;"\t{3}\tline:{4}{5}'.format(exposed, filename, cur_searchterm, "e", str(lnum+1), "\taccess:public\timport:" + cur_head + "&&&" + cur_tag) | |||||
elif match_type: | |||||
cur_tag = match_type.group(2) | |||||
if match_type.group(1) == " alias": | |||||
args = "\taccess:protected" | |||||
cur_searchterm = "^type " + cur_tag + "$" | |||||
cur_kind = "t" | |||||
args = args + "\theader:" + cur_head | |||||
elif match_function: | |||||
cur_tag = match_function.group(1) | |||||
cur_searchterm = "^" + cur_tag + " :" | |||||
cur_kind = "f" | |||||
args = "\theader:" + cur_head + "\tsignature:(" + match_function.group(2) + ")" | |||||
else: | |||||
continue | |||||
print('{0}\t{1}\t/{2}/;"\t{3}\tline:{4}{5}'.format( | |||||
cur_tag, filename, cur_searchterm, cur_kind, str(lnum+1), args) + lines) |
@@ -0,0 +1,118 @@ | |||||
#! /usr/bin/env python | |||||
# -*- coding: utf-8 -*- | |||||
from __future__ import print_function | |||||
help_text = """ | |||||
Extracts tags from rmd files. Useful for the Tagbar plugin. | |||||
Usage: | |||||
Install Tagbar (http://majutsushi.github.io/tagbar/). Then, put this file | |||||
anywhere and add the following to your .vimrc: | |||||
let g:tagbar_type_rmd = { | |||||
\ 'ctagstype':'rmd' | |||||
\ , 'kinds':['h:header', 'c:chunk', 'f:function', 'v:variable'] | |||||
\ , 'sro':'&&&' | |||||
\ , 'kind2scope':{'h':'header', 'c':'chunk', 'f':'function', 'v':'variable'} | |||||
\ , 'sort':0 | |||||
\ , 'ctagsbin':'/path/to/rmdtags.py' | |||||
\ . 'ctagsargs':'' | |||||
\ } | |||||
""" | |||||
import sys | |||||
import re | |||||
if len(sys.argv) < 2: | |||||
print(help_text) | |||||
exit() | |||||
filename = sys.argv[1] | |||||
print(filename) | |||||
re_header = re.compile(r"^(#+)([^{]+)(\{[^}]+\})?$") | |||||
re_chunk = re.compile(r"^```\{r ([^,]+)(,[^}]*)?\}$") | |||||
re_function = re.compile(r"^[\t ]*([^ ]+) *<- *function.*$") | |||||
# re_variable1 = re.compile(r"^[\t ]*([^ ]+) *<-.*$") | |||||
# re_variable2 = re.compile(r"^.*-> *(.+)$") | |||||
file_content = [] | |||||
try: | |||||
with open(filename, "r") as vim_buffer: | |||||
file_content = vim_buffer.readlines() | |||||
except: | |||||
exit() | |||||
headers = [] | |||||
depth = [0] | |||||
inChunk = False | |||||
curChunk = None | |||||
for lnum, line in enumerate(file_content): | |||||
newline = [] | |||||
tag = "" | |||||
signature = "" | |||||
options = "" | |||||
# Headers | |||||
if re_header.match(line) and not inChunk: | |||||
level = len(re_header.match(line).group(1)) | |||||
tag = re_header.match(line).group(2).strip() | |||||
newline.append(tag) | |||||
newline.append(filename) | |||||
newline.append('/^' + line.rstrip("\n") + '$/;"') | |||||
newline.append("h") | |||||
newline.append("line:" + str(lnum+1)) | |||||
# header | |||||
while (level <= depth[len(depth) -1]): | |||||
headers.pop() | |||||
depth.pop() | |||||
if len(headers) > 0: | |||||
options = "header:" + "&&&".join(headers) | |||||
headers.append(tag) | |||||
depth.append(level) | |||||
# signature | |||||
if re_header.match(line).group(3): | |||||
signature = "(" + re_header.match(line).group(3).strip("{}") + ")" | |||||
options = options + "\tsignature:" + signature | |||||
newline.append(options) | |||||
print("\t".join(newline)) | |||||
# Chunks | |||||
if re_chunk.match(line): | |||||
inChunk = True | |||||
curChunk = re_chunk.match(line).group(1).strip() | |||||
newline.append(re_chunk.match(line).group(1).strip()) | |||||
newline.append(filename) | |||||
newline.append('/^' + line.rstrip("\n") + '$/;"') | |||||
newline.append("c") | |||||
newline.append("line:" + str(lnum+1)) | |||||
if len(headers) > 0: | |||||
options = "header:" + "&&&".join(headers) | |||||
if re_chunk.match(line).group(2): | |||||
signature = "(" + re_chunk.match(line).group(2).lstrip(", ") + ")" | |||||
options = options + "\tsignature:" + signature | |||||
newline.append(options) | |||||
print("\t".join(newline)) | |||||
if line == "```\n": | |||||
inChunk = False | |||||
curChunk = None | |||||
# Functions | |||||
if re_function.match(line) and inChunk: | |||||
newline.append(re_function.match(line).group(1).strip()) | |||||
newline.append(filename) | |||||
newline.append('/^' + line.rstrip("\n") + '$/;"') | |||||
newline.append("f") | |||||
newline.append("line:" + str(lnum+1)) | |||||
print("\t".join(newline)) | |||||
# elif (re_variable1.match(line) or re_variable2.match(line)) and inChunk: | |||||
# tag = re_variable1.match(line) or re_variable2.match(line) | |||||
# tag = tag.group(1).strip() | |||||
# newline.append(tag) | |||||
# newline.append(filename) | |||||
# newline.append('/^' + line.rstrip("\n") + '$/;"') | |||||
# newline.append("v") | |||||
# newline.append("line:" + str(lnum+1)) | |||||
# print("\t".join(newline)) | |||||
@@ -0,0 +1,82 @@ | |||||
#! /usr/bin/env python | |||||
# -*- coding: utf-8 -*- | |||||
from __future__ import print_function | |||||
help_text = """ | |||||
Extracts tags from Vimwiki files. Useful for the Tagbar plugin. | |||||
Usage: | |||||
Install Tagbar (http://majutsushi.github.io/tagbar/). Then, put this file | |||||
anywhere and add the following to your .vimrc: | |||||
let g:tagbar_type_vimwiki = { | |||||
\ 'ctagstype':'vimwiki' | |||||
\ , 'kinds':['h:header'] | |||||
\ , 'sro':'&&&' | |||||
\ , 'kind2scope':{'h':'header'} | |||||
\ , 'sort':0 | |||||
\ , 'ctagsbin':'/path/to/vwtags.py' | |||||
\ , 'ctagsargs': 'default' | |||||
\ } | |||||
The value of ctagsargs must be one of 'default', 'markdown' or 'media', | |||||
whatever syntax you use. However, if you use multiple wikis with different | |||||
syntaxes, you can, as a workaround, use the value 'all' instead. Then, Tagbar | |||||
will show markdown style headers as well as default/mediawiki style headers, | |||||
but there might be erroneously shown headers. | |||||
""" | |||||
import sys | |||||
import re | |||||
if len(sys.argv) < 3: | |||||
print(help_text) | |||||
exit() | |||||
syntax = sys.argv[1] | |||||
filename = sys.argv[2] | |||||
rx_default_media = r"^\s*(={1,6})([^=].*[^=])\1\s*$" | |||||
rx_markdown = r"^\s*(#{1,6})([^#].*)$" | |||||
if syntax in ("default", "media"): | |||||
rx_header = re.compile(rx_default_media) | |||||
elif syntax == "markdown": | |||||
rx_header = re.compile(rx_markdown) | |||||
else: | |||||
rx_header = re.compile(rx_default_media + "|" + rx_markdown) | |||||
file_content = [] | |||||
try: | |||||
with open(filename, "r") as vim_buffer: | |||||
file_content = vim_buffer.readlines() | |||||
except: | |||||
exit() | |||||
state = [""]*6 | |||||
for lnum, line in enumerate(file_content): | |||||
match_header = rx_header.match(line) | |||||
if not match_header: | |||||
continue | |||||
match_lvl = match_header.group(1) or match_header.group(3) | |||||
match_tag = match_header.group(2) or match_header.group(4) | |||||
cur_lvl = len(match_lvl) | |||||
cur_tag = match_tag.strip() | |||||
cur_searchterm = "^" + match_header.group(0).rstrip("\r\n") + "$" | |||||
cur_kind = "h" | |||||
state[cur_lvl-1] = cur_tag | |||||
for i in range(cur_lvl, 6): | |||||
state[i] = "" | |||||
scope = "&&&".join( | |||||
[state[i] for i in range(0, cur_lvl-1) if state[i] != ""]) | |||||
if scope: | |||||
scope = "\theader:" + scope | |||||
print('{0}\t{1}\t/{2}/;"\t{3}\tline:{4}{5}'.format( | |||||
cur_tag, filename, cur_searchterm, cur_kind, str(lnum+1), scope)) |
@@ -0,0 +1,121 @@ | |||||
" Map leader | |||||
map <Space> <leader> | |||||
map <Space><Space> <leader><leader> | |||||
let mapleader = " " | |||||
map <leader><leader><leader> :hi Normal ctermbg=NONE<CR>:hi EndOfBuffer ctermbg=NONE<CR> | |||||
" Quickfix navigation | |||||
noremap <Up> :cprev<CR> | |||||
noremap <Down> :cnext<CR> | |||||
" Play default macro | |||||
noremap <leader>q @q | |||||
" Bepo mappings | |||||
noremap t h | |||||
noremap r l | |||||
noremap T H | |||||
noremap R L | |||||
noremap L D | |||||
noremap h r | |||||
noremap H R | |||||
noremap j t | |||||
noremap l d | |||||
" Scrolling | |||||
noremap <C-D> <C-Y> | |||||
noremap <C-S> <C-E> | |||||
" Movements (by displayed line) | |||||
noremap d gk | |||||
noremap s gj | |||||
" Swap display line behavior | |||||
noremap gd k | |||||
noremap gs j | |||||
noremap 0 g0 | |||||
noremap g0 0 | |||||
noremap $ g$ | |||||
noremap g$ $ | |||||
noremap ^ g^ | |||||
noremap g^ ^ | |||||
" Page up/down | |||||
noremap D <C-u> | |||||
noremap S <C-d> | |||||
" Next and previous in 'f' search to match standard scheme | |||||
noremap , ; | |||||
noremap ; , | |||||
" Windows | |||||
nmap é <C-w> | |||||
noremap <C-W>h <C-W>s<C-W>j | |||||
noremap <C-W>v <C-W>v | |||||
noremap <C-W>é <C-w><C-w> | |||||
noremap <C-W>/ 4<C-W>< | |||||
noremap <C-W>* 4<C-W>> | |||||
noremap <C-W>+ 4<C-W>+ | |||||
noremap <C-W>- 4<C-W>- | |||||
noremap <C-W>t <C-W>h | |||||
noremap <C-W>r <C-W>l | |||||
noremap <C-W>d <C-W>k | |||||
noremap <C-W>s <C-W>j | |||||
noremap <C-W>T <C-W>H | |||||
noremap <C-W>R <C-W>L | |||||
noremap <C-W>D <C-W>K | |||||
noremap <C-W>S <C-W>J | |||||
noremap <C-W>n :vnew<CR> | |||||
noremap <C-W>f :vsplit<CR>gf | |||||
" Tabs | |||||
nnoremap ggt gt | |||||
nnoremap ggl :tabclose<CR> | |||||
nnoremap ggn :tabnew<CR> | |||||
" buffers as tabs | |||||
nnoremap gt :bnext<CR> | |||||
nnoremap gT :bprevious<CR> | |||||
nnoremap gn :enew<CR> | |||||
nnoremap gl :bprevious<CR>:bdelete #<CR> | |||||
nnoremap gL :bprevious<CR>:bdelete! #<CR> | |||||
" fold navigation | |||||
noremap zs zj | |||||
noremap zd zk | |||||
noremap zt zm | |||||
noremap zT zM | |||||
" Spell errors navigation | |||||
noremap zv [s | |||||
noremap zl ]s | |||||
" Insert lines | |||||
noremap <leader>o o<Esc> | |||||
noremap <leader>O O<Esc> | |||||
" follow links, C-] is impossible to type | |||||
noremap _ <C-]> | |||||
" disable Ex mode | |||||
noremap Q <nop> | |||||
" have Y work like D and C (ie: yank the line right of the cursor) | |||||
nnoremap Y y$ | |||||
" remap ii to Esc in insert mode, easier ! | |||||
inoremap ii <Esc> | |||||
" Write with root privileges | |||||
command! WW execute "w suda://%" | |||||
command! W execute "w" | |||||
" Edit vimrc | |||||
nnoremap <leader>$ :e $MYVIMRC<CR> | |||||
" Exit terminal | |||||
tnoremap ii <C-\><C-n> |
@@ -0,0 +1,115 @@ | |||||
set background=dark " Dark theme for the colorscheme | |||||
colorscheme hybrid " Colorscheme | |||||
set ruler " Show the cursor position all the time | |||||
set cursorline " Highlight current line | |||||
set number relativenumber " Line numbers, current and relative | |||||
set updatetime=100 " Shorten update time to 100ms instead of 4 | |||||
set listchars=tab:▸·,trail:-,nbsp:· | |||||
set list " Display tabs and trailing spaces | |||||
set linebreak " Break lines with wrap on word separators | |||||
set breakindent " Indent the wrapped line | |||||
set breakindentopt=shift:2,sbr " Indent by 2 and draw the break char | |||||
set showbreak=↳ | |||||
highlight Normal ctermbg=NONE guibg=NONE " transparent background | |||||
highlight EndOfBuffer ctermbg=NONE | |||||
highlight List ctermbg=NONE ctermfg=darkred guibg=lightgray " Listchars highlight | |||||
match List /\%xa0/ | |||||
2match List / \+$/ | |||||
highlight DiffText ctermbg=104 ctermfg=220 | |||||
highlight LineNr ctermfg=darkgrey | |||||
highlight Comment cterm=italic " Comments in italics | |||||
highlight MatchParen ctermbg = 11 " Match parenthesis in bright yellow | |||||
highlight Conceal ctermbg=NONE ctermfg=grey | |||||
highlight Visual ctermbg=darkgrey | |||||
highlight Pmenu ctermbg=darkgrey | |||||
set showcmd " Show visual selection size | |||||
set splitright " Vertical split to the right | |||||
set fillchars=vert:⎢ " Vertical line for splits | |||||
set laststatus=2 " Always display status bar | |||||
set timeoutlen=300 " Set key timeout | |||||
set hidden " Enable buffers to be hidden even if modified | |||||
set fileencoding=utf-8 " Encoding | |||||
scriptencoding utf-8 | |||||
set autochdir " Auto change directory to current file | |||||
set undofile undodir=~/.config/nvim/undodir/ " Permanent undo | |||||
set backup backupdir=~/.config/nvim/backupdir " Set backup folder | |||||
set swapfile directory=~/.config/nvim/swap " Swapfile | |||||
set updatecount=10 " Write to swap every 10 chars | |||||
set foldmethod=syntax " Fold with syntax | |||||
set foldlevelstart=99 | |||||
set completeopt=noinsert,menuone " Display a completion menu, don't insert anything till selected | |||||
set wildmenu " Autocomplete in command mode | |||||
set wildmode=list:longest,full " First show list of matches without replacing, then completion | |||||
set wildignore+=*.bmp,*.gif,*.ico,*.jpg,*.png,*.ico " Skip those filetypes and directories | |||||
set wildignore+=*.mkv,*.mp4,*.avi | |||||
set wildignore+=.cache/*,Private/*,Documents/*,Downloads/*,Jeux/*,node_modules/*,old_desktop/*,R/* | |||||
set wildignorecase " Ignore case when searching for files | |||||
set cpoptions+=$ " Display $ in change mode | |||||
set backspace=indent,eol,start " Allow backspace to erase indent,eol, before start | |||||
set history=50 " Keep 50 lines of command line history | |||||
set gdefault " s///g by default | |||||
set incsearch " Do incremental searching | |||||
set hlsearch " Highlight searches | |||||
set ignorecase smartcase " Smartcase | |||||
set inccommand=nosplit " Preview replace | |||||
highlight Search cterm=bold,underline ctermfg=NONE ctermbg=NONE " Search results in underlined bold | |||||
set spelllang=en_us " Correct spelling in English by default | |||||
set mouse=a " Enable mouse | |||||
set autoindent " Indent like previous line | |||||
set smartindent " Also indent in code blocks | |||||
set scrolloff=10 " Vertical scroll offset | |||||
set sidescroll=1 " Scroll horizontally one line at a time | |||||
set sidescrolloff=1000 " Horizontal scroll offset (keep cursor in middle) | |||||
set expandtab " Use spaces instead of tabs | |||||
set tabstop=2 " Use 2 spaces for one tab | |||||
set softtabstop=2 " Use 2 spaces for soft tabs | |||||
set shiftwidth=2 " Shift by 2 spaces when indenting | |||||
set formatoptions+=j " Delete comment character when joining comment lines | |||||
set diffopt=filler,vertical,foldcolumn:0 | |||||
set clipboard^=unnamed,unnamedplus "default clipboard to X clipboard | |||||
set diffopt=filler,vertical | |||||
augroup Resource | |||||
autocmd! | |||||
autocmd! bufwritepost ~/.config/nvim/init.* | |||||
\ source ~/.config/nvim/init.vim " Reload .vimrc after editing | |||||
augroup END | |||||
augroup templates | |||||
autocmd! | |||||
autocmd! BufNewFile *.md 0r ~/.config/nvim/templates/template.md | |||||
autocmd! BufNewFile *.Rmd 0r ~/.config/nvim/templates/template.Rmd | |||||
augroup END | |||||
augroup ncm2start | |||||
autocmd! | |||||
autocmd! BufEnter * call ncm2#enable_for_buffer() | |||||
augroup END |
@@ -0,0 +1,145 @@ | |||||
" elm | |||||
let g:elm_make_output_file = "index.html" | |||||
let g:elm_make_show_warnings = 1 | |||||
let g:elm_format_autosave = 1 | |||||
let g:elm_format_fail_silently = 1 | |||||
let g:elm_jump_to_error = 0 | |||||
let g:elm_setup_keybindings = 0 | |||||
let g:elm_detailed_complete = 1 | |||||
let g:elm_browser_command = "qutebrowser" | |||||
" vim-pandoc | |||||
let g:pandoc#filetypes#handled = ["markdown"] | |||||
let g:pandoc#modules#enabled = ["bibliographies", "toc", "completion"] | |||||
let g:pandoc#biblio#use_bibtool = 1 | |||||
" 고요 and Limelight | |||||
let g:goyo_width = 100 | |||||
let g:goyo_height = 95 | |||||
" Nvim-R | |||||
let R_rconsole_height = 25 | |||||
let R_nvimpager="vertical" | |||||
let R_args_in_stline = 1 | |||||
let r_syntax_folding = 0 | |||||
let R_rconsole_width = 0 | |||||
let R_close_term = 1 | |||||
let R_assign = 3 | |||||
let R_objbr_opendf = 0 | |||||
let R_start_libs = 'base,stats,graphics,grDevices,utils,methods,dplyr,tidyr,ggplot2,stringr,forcats,lubridate,purrr' | |||||
" easymotion | |||||
let g:EasyMotion_smartcase = 1 | |||||
let g:EasyMotion_keys = 'auiecmtsrn' | |||||
let g:EasyMotion_use_upper = 1 | |||||
" Autopairs | |||||
let g:AutoPairsMultilineClose = 0 | |||||
" vim-airline options | |||||
set noshowmode | |||||
let g:airline_powerline_fonts=1 | |||||
" vim-workspace | |||||
let g:workspace_powerline_separators = 1 | |||||
let g:workspace_tab_icon = "#" | |||||
function! g:WorkspaceSetCustomColors() | |||||
hi! WorkspaceBufferTruncDefault cterm=bold ctermbg=10 ctermfg=8 guibg=#999999 guifg=#000000 | |||||
hi! WorkspaceIconDefault cterm=NONE ctermbg=5 ctermfg=10 guibg=#FF0000 guifg=#999999 | |||||
highlight WorkspaceBufferCurrent ctermbg=green ctermfg=black guibg=green | |||||
highlight WorkspaceBufferActive ctermbg=darkgreen ctermfg=black guibg=darkgreen | |||||
highlight WorkspaceBufferHidden ctermbg=black ctermfg=white guibg=black | |||||
highlight WorkspaceTabHidden ctermbg=darkblue ctermfg=black guibg=darkblue | |||||
highlight WorkspaceTabCurrent ctermbg=blue ctermfg=white guibg=black | |||||
highlight WorkspaceFill ctermbg=black ctermfg=white guibg=black | |||||
endfunction | |||||
function! s:goyo_enter() | |||||
highlight EndOfBuffer ctermbg=NONE | |||||
Limelight | |||||
endfunction | |||||
function! s:goyo_leave() | |||||
highlight Comment cterm=italic | |||||
highlight List ctermbg=NONE ctermfg=darkred guibg=gray | |||||
highlight EndOfBuffer ctermbg=235 | |||||
highlight Search cterm=bold,underline ctermfg=NONE ctermbg=NONE | |||||
highlight MatchParen ctermbg = 11 | |||||
Limelight! | |||||
endfunction | |||||
augroup Goyo | |||||
autocmd! | |||||
autocmd! User GoyoEnter nested call <SID>goyo_enter() | |||||
autocmd! User GoyoLeave nested call <SID>goyo_leave() | |||||
augroup END | |||||
" vimwiki | |||||
let g:vimwiki_folding='expr:quick' | |||||
let g:vimwiki_list = [{'path': '~/Private/vimwiki/', | |||||
\ 'template_path': '~/Private/vimwiki/templates/', | |||||
\ 'template_default': 'default', | |||||
\ 'template_ext': '.tpl', | |||||
\ 'ext': '.wiki', | |||||
\ 'path_html': '~/Private/vimwiki/html/'}, | |||||
\ {'path': '~/Projects/z_Perso/website/content/page/', | |||||
\ 'index': 'pages', | |||||
\ 'syntax': 'markdown', | |||||
\ 'ext': '.md'}] | |||||
" Tagbar | |||||
let g:tagbar_foldlevel=0 | |||||
let g:tagbar_autoshowtag=1 | |||||
let g:tagbar_iconchars = ['▸', '▾'] | |||||
let g:tagbar_autofocus=1 | |||||
let g:tagbar_compact=1 | |||||
let g:tagbar_width=40 | |||||
let g:tagbar_type_elm = { | |||||
\ 'ctagstype':'elm' | |||||
\ , 'kinds':['h:header', 'i:import', 't:type', 'f:function', 'e:exposing'] | |||||
\ , 'sro':'&&&' | |||||
\ , 'kind2scope':{ 'h':'header', 'i':'import'} | |||||
\ , 'sort':0 | |||||
\ , 'ctagsbin':'~/.config/nvim/gentags/elmtags.py' | |||||
\ , 'ctagsargs': '' | |||||
\ } | |||||
let g:tagbar_type_vimwiki = { | |||||
\ 'ctagstype':'vimwiki' | |||||
\ , 'kinds':['h:header'] | |||||
\ , 'sro':'&&&' | |||||
\ , 'kind2scope':{'h':'header'} | |||||
\ , 'sort':0 | |||||
\ , 'ctagsbin':'~/.config/nvim/gentags/vwtags.py' | |||||
\ , 'ctagsargs': 'default' | |||||
\ } | |||||
let g:tagbar_type_rmd = { | |||||
\ 'ctagstype':'rmd' | |||||
\ , 'kinds':['h:header', 'c:chunk', 'f:function'] | |||||
\ , 'sro':'&&&' | |||||
\ , 'kind2scope':{'h':'header', 'c':'chunk'} | |||||
\ , 'sort':0 | |||||
\ , 'ctagsbin':'~/.config/nvim/gentags/rmdtags.py' | |||||
\ , 'ctagsargs': '' | |||||
\ } | |||||
let g:tagbar_type_r = { | |||||
\ 'ctagstype' : 'r', | |||||
\ 'kinds' : [ | |||||
\ 'f:Functions', | |||||
\ 'g:GlobalVariables', | |||||
\ 'v:FunctionVariables', | |||||
\ ] | |||||
\ } | |||||
augroup Tagbar | |||||
autocmd! | |||||
autocmd! FileType vimwiki nested :TagbarOpen | |||||
augroup END |
@@ -0,0 +1,80 @@ | |||||
" NCM | |||||
inoremap <expr> <Tab> pumvisible() ? "\<C-n>" : "\<Tab>" | |||||
inoremap <expr> <S-Tab> pumvisible() ? "\<C-p>" : "\<S-Tab>" | |||||
" inoremap <silent> <expr> <CR> ncm2_ultisnips#expand_or("\<CR>", 'n') | |||||
" Ale | |||||
nmap <silent> <leader>ld <Plug>(ale_previous_wrap) | |||||
nmap <silent> <leader>ls <Plug>(ale_next_wrap) | |||||
nmap <silent> <leader>la <Plug>(ale_detail) | |||||
nmap <silent> <leader>lt <Plug>(ale_toggle) | |||||
" Tagbar | |||||
nnoremap <silent> <leader>tt :TagbarOpen fjc<CR> | |||||
let g:tagbar_map_togglesort = "S" | |||||
let g:tagbar_map_nextfold = "zs" | |||||
let g:tagbar_map_prevfold = "zd" | |||||
let g:tagbar_map_incrementfold = "zr" | |||||
let g:tagbar_map_decrementfold = "zt" | |||||
let g:tagbar_map_openallfolds = "zR" | |||||
let g:tagbar_map_closeallfolds = "zT" | |||||
" Elm | |||||
nmap <leader>em <Plug>(elm-make) | |||||
nmap <leader>er <Plug>(elm-repl) | |||||
nmap <leader>ee <Plug>(elm-error-detail) | |||||
nmap <leader>ed <Plug>(elm-show-docs) | |||||
" Loupe | |||||
nmap ÷ <Plug>(LoupeClearHighlight) | |||||
" Ultisnips | |||||
" let g:UltiSnipsExpandTrigger="<Tab>" | |||||
let g:UltiSnipsJumpForwardTrigger="<tab>" | |||||
let g:UltiSnipsJumpBackwardTrigger="<s-tab>" | |||||
" 고요 and Limelight | |||||
noremap <leader>d :Goyo<CR> | |||||
noremap <leader>D :Limelight!!<CR> | |||||
" Fugitive | |||||
noremap <leader>g :Gstatus<CR> | |||||
noremap <leader>gp :Git push<CR> | |||||
noremap <leader>ga :Git add % -f<CR> | |||||
" Gitv | |||||
let g:Gitv_CustomMappings = { | |||||
\'prevCommit': 's', | |||||
\'nextCommit': 'd', | |||||
\'vdiff': 'D', | |||||
\'delete': 'l', | |||||
\'quit': 'q', | |||||
\'editCommit': '<cr>', | |||||
\'vertSplitCommit': 'S', | |||||
\'nextBranch': 'x', | |||||
\'prevBranch': 'X', | |||||
\'vcherryPick': 'cp' | |||||
\} | |||||
" Nvim-R | |||||
nmap <F1> <Plug>RHelp | |||||
nmap <F2> <Plug>RStart | |||||
nmap <F3> <Plug>RUpdateObjBrowser | |||||
nmap <CR> <Plug>RDSendLine | |||||
vmap <CR> <Plug>REDSendSelection | |||||
" vim-lion | |||||
let g:lion_create_maps = 1 | |||||
let g:lion_map_right = "<leader>a" | |||||
let g:lion_map_left = "<leader>A" | |||||
" UndoTree | |||||
nnoremap <leader>u :UndotreeToggle<CR> :UndotreeFocus<CR> | |||||
" vim-surround | |||||
au vimenter * unmap ds | |||||
nmap ls <Plug>Dsurround | |||||
" vim-ranger | |||||
let g:ranger_map_keys = 0 | |||||
map <leader>F :Ranger<CR> |
@@ -0,0 +1,63 @@ | |||||
if !exists("g:syntax_on") | |||||
syntax enable "detect syntax | |||||
endif | |||||
filetype plugin indent on "filetype plugins + indentation | |||||
call plug#begin('~/.config/nvim/plugged') | |||||
" Sudo replacement | |||||
Plug 'lambdalisue/suda.vim' | |||||
" Appearance | |||||
Plug 'bagrat/vim-workspace' | |||||
Plug 'w0ng/vim-hybrid' | |||||
Plug 'bling/vim-airline' | |||||
Plug 'junegunn/goyo.vim' | |||||
Plug 'junegunn/limelight.vim' | |||||
Plug 'wincent/loupe' | |||||
" Git | |||||
Plug 'tpope/vim-fugitive' | |||||
Plug 'airblade/vim-gitgutter' | |||||
Plug 'gregsexton/gitv' | |||||
" Elm | |||||
Plug 'elmcast/elm-vim' | |||||
" vimwiki | |||||
Plug 'vimwiki/vimwiki' | |||||
Plug 'majutsushi/tagbar' | |||||
" Python | |||||
Plug 'davidhalter/jedi' | |||||
Plug 'jalvesaq/vimcmdline' | |||||
" HTML/JS | |||||
Plug 'pangloss/vim-javascript' | |||||
Plug 'rstacruz/sparkup' | |||||
" R/Rmd | |||||
Plug 'jalvesaq/Nvim-R' | |||||
Plug 'vim-pandoc/vim-pandoc' | |||||
Plug 'vim-pandoc/vim-pandoc-syntax' | |||||
" All purpose | |||||
Plug 'w0rp/ale' | |||||
Plug 'SirVer/ultisnips' | |||||
Plug 'reedes/vim-wordy' | |||||
Plug 'junegunn/vim-peekaboo' | |||||
Plug 'tpope/vim-surround' | |||||
Plug 'wellle/targets.vim' | |||||
Plug 'tommcdo/vim-lion' | |||||
Plug 'tpope/vim-repeat' | |||||
Plug 'tpope/vim-commentary' | |||||
Plug 'mbbill/undotree' | |||||
Plug 'easymotion/vim-easymotion' | |||||
" Ranger | |||||
Plug 'francoiscabrol/ranger.vim' | |||||
Plug 'rbgrouleff/bclose.vim' | |||||
" NCM2 | |||||
Plug 'ncm2/ncm2' | |||||
Plug 'roxma/nvim-yarp' | |||||
Plug 'ncm2/ncm2-path' | |||||
Plug 'ncm2/ncm2-bufword' | |||||
Plug 'ncm2/ncm2-jedi' | |||||
Plug 'ncm2/ncm2-ultisnips' | |||||
Plug 'gaalcaras/ncm-R' | |||||
call plug#end() | |||||
source $HOME/.config/nvim/init.d/keys.vim | |||||
source $HOME/.config/nvim/init.d/plugins.vim | |||||
source $HOME/.config/nvim/init.d/plugkeys.vim | |||||
source $HOME/.config/nvim/init.d/options.vim |
@@ -0,0 +1,23 @@ | |||||
--- | |||||
title: | |||||
output: | |||||
html_document: | |||||
toc: true | |||||
toc_float: true | |||||
--- | |||||
```{r init, echo = F, message = F, warning = F} | |||||
library(tidyverse) | |||||
library(knitr) | |||||
library(DT) | |||||
opts_chunk$set(echo = F, | |||||
message = F, | |||||
warning = F) | |||||
options(DT.options = list(paging = F, | |||||
searching = T, | |||||
info = F, | |||||
dom = "Bfrtip", | |||||
buttons = c("copy", "excel"))) | |||||
``` |
@@ -0,0 +1,9 @@ | |||||
--- | |||||
title: | |||||
authors: ['maximewack'] | |||||
date: '' | |||||
slug: | |||||
draft: true | |||||
categories: [] | |||||
tags: [] | |||||
--- |
@@ -0,0 +1,697 @@ | |||||
# vim: ft=conf | |||||
# | |||||
# In this config file, qutebrowser's key bindings are configured. | |||||
# The format looks like this: | |||||
# | |||||
# [keymode] | |||||
# | |||||
# command | |||||
# keychain | |||||
# keychain2 | |||||
# ... | |||||
# | |||||
# All blank lines and lines starting with '#' are ignored. | |||||
# Inline-comments are not permitted. | |||||
# | |||||
# keymode is a comma separated list of modes in which the key binding should be | |||||
# active. If keymode starts with !, the key binding is active in all modes | |||||
# except the listed modes. | |||||
# | |||||
# For special keys (can't be part of a keychain), enclose them in `<`...`>`. | |||||
# For modifiers, you can use either `-` or `+` as delimiters, and these names: | |||||
# | |||||
# * Control: `Control`, `Ctrl` | |||||
# * Meta: `Meta`, `Windows`, `Mod4` | |||||
# * Alt: `Alt`, `Mod1` | |||||
# * Shift: `Shift` | |||||
# | |||||
# For simple keys (no `<>`-signs), a capital letter means the key is pressed | |||||
# with Shift. For special keys (with `<>`-signs), you need to explicitly add | |||||
# `Shift-` to match a key pressed with shift. | |||||
# | |||||
# Note that default keybindings are always bound, and need to be explicitly | |||||
# unbound if you wish to remove them: | |||||
# | |||||
# <unbound> | |||||
# keychain | |||||
# keychain2 | |||||
# ... | |||||
[!normal] | |||||
leave-mode | |||||
<escape> | |||||
<ctrl-[> | |||||
[normal] | |||||
# Keybindings for normal mode. | |||||
clear-keychain ;; search ;; fullscreen --leave | |||||
<escape> | |||||
set-cmd-text -s :open | |||||
J | |||||
set-cmd-text :open {url} | |||||
go | |||||
set-cmd-text -s :open -t | |||||
j | |||||
set-cmd-text :open -t {url} | |||||
gO | |||||
set-cmd-text -s :open -b | |||||
xo | |||||
set-cmd-text :open -b {url} | |||||
xO | |||||
set-cmd-text -s :open -w | |||||
wo | |||||
set-cmd-text :open -w {url} | |||||
wO | |||||
open -t | |||||
ga | |||||
<ctrl-t> | |||||
tab-close | |||||
q | |||||
<ctrl-w> | |||||
tab-only | |||||
co | |||||
tab-focus | |||||
l | |||||
tab-move | |||||
gm | |||||
tab-move - | |||||
gv | |||||
tab-move + | |||||
gl | |||||
tab-prev | |||||
v | |||||
tab-clone | |||||
gC | |||||
reload | |||||
m | |||||
reload -f | |||||
R | |||||
back | |||||
gt | |||||
back -t | |||||
gT | |||||
back -w | |||||
gW | |||||
forward | |||||
gr | |||||
forward -t | |||||
gR | |||||
forward -w | |||||
gw | |||||
fullscreen | |||||
<f11> | |||||
hint | |||||
f | |||||
hint all tab | |||||
F | |||||
hint all window | |||||
wf | |||||
hint all tab-bg | |||||
;b | |||||
hint all tab-fg | |||||
;r | |||||
hint all hover | |||||
;h | |||||
hint images | |||||
;i | |||||
hint images tab | |||||
;I | |||||
hint images tab-bg | |||||
.i | |||||
hint links fill :open {hint-url} | |||||
;o | |||||
hint links fill :open -t {hint-url} | |||||
;O | |||||
hint links fill :open -b {hint-url} | |||||
.o | |||||
hint links yank | |||||
;y | |||||
hint links yank-primary | |||||
;Y | |||||
hint --rapid links tab-bg | |||||
;f | |||||
hint --rapid links window | |||||
;R | |||||
hint links download | |||||
;d | |||||
scroll left | |||||
t | |||||
scroll down | |||||
s | |||||
scroll up | |||||
d | |||||
scroll right | |||||
r | |||||
undo | |||||
h | |||||
<ctrl-shift-t> | |||||
scroll-perc 0 | |||||
gg | |||||
scroll-perc | |||||
G | |||||
search-next | |||||
n | |||||
search-prev | |||||
N | |||||
enter-mode insert | |||||
i | |||||
enter-mode caret | |||||
c | |||||
yank | |||||
yy | |||||
yank -s | |||||
yY | |||||
yank title | |||||
yt | |||||
yank title -s | |||||
yT | |||||
yank domain | |||||
yd | |||||
yank domain -s | |||||
yD | |||||
open -- {clipboard} | |||||
pp | |||||
open -- {primary} | |||||
pP | |||||
open -t -- {clipboard} | |||||
Pp | |||||
open -t -- {primary} | |||||
PP | |||||
open -w -- {clipboard} | |||||
wp | |||||
open -w -- {primary} | |||||
wP | |||||
set-cmd-text -s :quickmark-load | |||||
b | |||||
set-cmd-text -s :quickmark-load -t | |||||
B | |||||
set-cmd-text -s :quickmark-load -w | |||||
wb | |||||
set-cmd-text -s :bookmark-load | |||||
gb | |||||
set-cmd-text -s :bookmark-load -t | |||||
gB | |||||
set-cmd-text -s :bookmark-load -w | |||||
wB | |||||
zoom-out | |||||
- | |||||
zo | |||||
zoom-in | |||||
+ | |||||
zi | |||||
zoom | |||||
= | |||||
zz | |||||
navigate prev | |||||
[[ | |||||
navigate next | |||||
]] | |||||
navigate prev -t | |||||
{{ | |||||
navigate next -t | |||||
}} | |||||
navigate up | |||||
gu | |||||
navigate up -t | |||||
gU | |||||
navigate increment | |||||
<ctrl-a> | |||||
navigate decrement | |||||
<ctrl-x> | |||||
inspector | |||||
wi | |||||
download | |||||
gd | |||||
download-cancel | |||||
ad | |||||
download-clear | |||||
cd | |||||
view-source | |||||
gf | |||||
tab-focus last | |||||
<ctrl-tab> | |||||
enter-mode passthrough | |||||
<ctrl-v> | |||||
quit | |||||
<ctrl-q> | |||||
scroll-page 0 1 | |||||
<ctrl-s> | |||||
scroll-page 0 -1 | |||||
<ctrl-d> | |||||
scroll-page 0 0.5 | |||||
S | |||||
scroll-page 0 -0.5 | |||||
D | |||||
tab-focus 1 | |||||
<alt-1> | |||||
tab-focus 2 | |||||
<alt-2> | |||||
tab-focus 3 | |||||
<alt-3> | |||||
tab-focus 4 | |||||
<alt-4> | |||||
tab-focus 5 | |||||
<alt-5> | |||||
tab-focus 6 | |||||
<alt-6> | |||||
tab-focus 7 | |||||
<alt-7> | |||||
tab-focus 8 | |||||
<alt-8> | |||||
tab-focus 9 | |||||
<alt-9> | |||||
home | |||||
<ctrl-h> | |||||
stop | |||||
<ctrl-z> | |||||
<ctrl-alt-p> | |||||
follow-selected | |||||
<return> | |||||
<ctrl-m> | |||||
<ctrl-j> | |||||
<shift-return> | |||||
<enter> | |||||
<shift-enter> | |||||
follow-selected -t | |||||
<ctrl-return> | |||||
<ctrl-enter> | |||||
<unbound> | |||||
ss | |||||
sl | |||||
sk | |||||
Ss | |||||
sf | |||||
spawn mpv {url} | |||||
p | |||||
quickmark-save | |||||
M | |||||
hint links spawn mpv {hint-url} | |||||
P | |||||
open -w | |||||
<ctrl-n> | |||||
enter-mode set_mark | |||||
` | |||||
enter-mode jump_mark | |||||
' | |||||
yank pretty-url | |||||
yp | |||||
yank pretty-url -s | |||||
yP | |||||
hint inputs | |||||
;t | |||||
repeat-command | |||||
. | |||||
yank selection | |||||
y | |||||
spawn --userscript password_fill | |||||
<space> | |||||
set-cmd-text / | |||||
/ | |||||
set-cmd-text ? | |||||
? | |||||
set-cmd-text : | |||||
: | |||||
tab-next | |||||
<ctrl-pgdown> | |||||
run-macro | |||||
@ | |||||
wq | |||||
ZZ | |||||
tab-focus -1 | |||||
g$ | |||||
tab-pin | |||||
<ctrl-p> | |||||
[insert] | |||||
# Keybindings for insert mode. | |||||
# Since normal keypresses are passed through, only special keys are | |||||
# supported in this mode. | |||||
# Useful hidden commands to map in this section: | |||||
# * `open-editor`: Open a texteditor with the focused field. | |||||
# * `paste-primary`: Paste primary selection at cursor position. | |||||
open-editor | |||||
<ctrl-e> | |||||
insert-text {primary} | |||||
<shift-ins> | |||||
[hint] | |||||
# Keybindings for hint mode. | |||||
# Since normal keypresses are passed through, only special keys are | |||||
# supported in this mode. | |||||
# Useful hidden commands to map in this section: | |||||
# * `follow-hint`: Follow the currently selected hint. | |||||
follow-hint | |||||
<return> | |||||
<ctrl-m> | |||||
<ctrl-j> | |||||
<shift-return> | |||||
<enter> | |||||
<shift-enter> | |||||
hint --rapid links download | |||||
<ctrl-d> | |||||
hint all tab-bg | |||||
<ctrl-b> | |||||
hint --rapid links tab-bg | |||||
<ctrl-r> | |||||
hint links | |||||
<ctrl-f> | |||||
[command] | |||||
# Keybindings for command mode. | |||||
# Since normal keypresses are passed through, only special keys are | |||||
# supported in this mode. | |||||
# Useful hidden commands to map in this section: | |||||
# * `command-history-prev`: Switch to previous command in history. | |||||
# * `command-history-next`: Switch to next command in history. | |||||
# * `completion-item-focus`: Select another item in completion. | |||||
# * `command-accept`: Execute the command currently in the commandline. | |||||
command-history-prev | |||||
<ctrl-p> | |||||
command-history-next | |||||
<ctrl-n> | |||||
completion-item-focus prev | |||||
<shift-tab> | |||||
<up> | |||||
completion-item-focus next | |||||
<tab> | |||||
<down> | |||||
completion-item-del | |||||
<ctrl-d> | |||||
command-accept | |||||
<return> | |||||
<ctrl-m> | |||||
<ctrl-j> | |||||
<shift-return> | |||||
<enter> | |||||
<shift-enter> | |||||
completion-item-focus next-category | |||||
<ctrl-tab> | |||||
completion-item-focus prev-category | |||||
<ctrl-shift-tab> | |||||
[prompt] | |||||
# Keybindings for prompts in the status line. | |||||
# You can bind normal keys in this mode, but they will be only active | |||||
# when a yes/no-prompt is asked. For other prompt modes, you can only | |||||
# bind special keys. | |||||
# Useful hidden commands to map in this section: | |||||
# * `prompt-accept`: Confirm the entered value. | |||||
# * `prompt-accept yes`: Answer yes to a yes/no question. | |||||
# * `prompt-accept no`: Answer no to a yes/no question. | |||||
prompt-accept | |||||
<return> | |||||
<ctrl-m> | |||||
<ctrl-j> | |||||
<shift-return> | |||||
<enter> | |||||
<shift-enter> | |||||
prompt-accept yes | |||||
y | |||||
prompt-accept no | |||||
n | |||||
prompt-open-download | |||||
<ctrl-x> | |||||
prompt-item-focus prev | |||||
<shift-tab> | |||||
<up> | |||||
prompt-item-focus next | |||||
<tab> | |||||
<down> | |||||
[command,prompt] | |||||
rl-backward-char | |||||
<ctrl-b> | |||||
rl-forward-char | |||||
<ctrl-f> | |||||
rl-backward-word | |||||
<alt-b> | |||||
rl-forward-word | |||||
<alt-f> | |||||
rl-beginning-of-line | |||||
<ctrl-a> | |||||
rl-end-of-line | |||||
<ctrl-e> | |||||
rl-unix-line-discard | |||||
<ctrl-u> | |||||
rl-kill-line | |||||
<ctrl-k> | |||||
rl-kill-word | |||||
<alt-d> | |||||
rl-unix-word-rubout | |||||
<ctrl-w> | |||||
<alt-backspace> | |||||
rl-yank | |||||
<ctrl-y> | |||||
rl-delete-char | |||||
<ctrl-?> | |||||
rl-backward-delete-char | |||||
<ctrl-h> | |||||
[caret] | |||||
toggle-selection | |||||
v | |||||
<space> | |||||
drop-selection | |||||
<ctrl-space> | |||||
enter-mode normal | |||||
c | |||||
move-to-next-line | |||||
j | |||||
move-to-prev-line | |||||
k | |||||
move-to-next-char | |||||
l | |||||
move-to-prev-char | |||||
h | |||||
move-to-end-of-word | |||||
e | |||||
move-to-next-word | |||||
w | |||||
move-to-prev-word | |||||
b | |||||
move-to-start-of-next-block | |||||
] | |||||
move-to-start-of-prev-block | |||||
[ | |||||
move-to-end-of-next-block | |||||
} | |||||
move-to-end-of-prev-block | |||||
{ | |||||
move-to-start-of-line | |||||
0 | |||||
move-to-end-of-line | |||||
$ | |||||
move-to-start-of-document | |||||
gg | |||||
move-to-end-of-document | |||||
G | |||||
yank selection -s | |||||
Y | |||||
yank selection | |||||
y | |||||
<return> | |||||
<ctrl-m> | |||||
<ctrl-j> | |||||
<shift-return> | |||||
<enter> | |||||
<shift-enter> | |||||
scroll left | |||||
H | |||||
scroll down | |||||
J | |||||
scroll up | |||||
K | |||||
scroll right | |||||
L | |||||
@@ -0,0 +1,199 @@ | |||||
Billets de Train pas chers sur Troc des Trains: Bon plan pour billets de train à petits prix. http://trocdestrains.com/ | |||||
Blogs/Bret Victor, beast of burden http://worrydream.com/ | |||||
Blogs/Grise Bouille http://grisebouille.net/ | |||||
Blogs/Hackery, Math & Design — Acko.net http://acko.net/ | |||||
Blogs/Home - colah's blog https://colah.github.io/ | |||||
Blogs/I’m a data scientist – mind if I do surgery on your heart? | Simply Statistics http://simplystatistics.org/?p=4068# | |||||
Blogs/Le blog d'un odieux connard | Qu'il est bon d'être mauvais. http://unodieuxconnard.com/ | |||||
Blogs/Merlanfrit http://www.merlanfrit.net/ | |||||
Blogs/Nioutaik, le blog de l'inutile indispensable totalement... indispensable ! http://nioutaik.fr/ | |||||
Blogs/OWNI, News, Augmented http://owni.fr/ | |||||
Blogs/Personal Registry Editor http://www.nicolasbize.com/blog/ | |||||
Blogs/The Daily WTF: Curious Perversions in Information Technology http://thedailywtf.com/ | |||||
Blogs/The X Bar · A Statistics Blog http://jhonaker.github.io/ | |||||
Blogs/Things Of Interest @ Things Of Interest http://qntm.org/ | |||||
Blogs/Variance Explained http://varianceexplained.org/ | |||||
Blogs/Wait But Why http://waitbutwhy.com/ | |||||
Blogs/ploum.net | Le blog de Lionel Dricot http://ploum.net/ | |||||
Cyberplus https://www.icgauth.banquepopulaire.fr/WebSSO_BP/_14707/index.html?transactionID=dacs210adac554204c52a2914e98ced03f59 | |||||
DBMI/Avillach Lab http://avillach-lab.hms.harvard.edu/ | |||||
DBMI/HMS Secure File Transfer Server https://transfer.med.harvard.edu/courier/web/1000@/wmLogin.html? | |||||
DBMI/Home | Caleydo http://www.caleydo.org/ | |||||
DBMI/Secure Access SSL VPN - Home https://secure.med.harvard.edu/dana/home/index.cgi | |||||
DBMI/Top 10 data mining algorithms in plain English | rayli.net http://rayli.net/blog/data/top-10-data-mining-algorithms-in-plain-english/ | |||||
DBMI/WebEx | Harvard Medical School https://hms.webex.com/mw3000/mywebex/cmr/cmr.do?siteurl=hms&AT=meet&username=PAvillach | |||||
DBMI/parklab/refinery-platform https://github.com/parklab/refinery-platform | |||||
Dev/A successful Git branching model » nvie.com http://nvie.com/posts/a-successful-git-branching-model/ | |||||
Dev/CodeMirror http://codemirror.net/ | |||||
Dev/D3/Connecting… http://chimera.labs.oreilly.com/books/1230000000345/ch11.html#_force_layout | |||||
Dev/D3/Mike Bostock http://bost.ocks.org/mike/ | |||||
Dev/D3/SVG Attribute reference - SVG | MDN https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute | |||||
Dev/Git Reference http://gitref.org/ | |||||
Dev/Guide ABS - traduction française http://abs.traduc.org/ | |||||
Dev/Learn Git Branching http://pcottle.github.io/learnGitBranching/ | |||||
Dev/Programmer's Learning Machine http://www.loria.fr/~quinson/Teaching/PLM/ | |||||
Dev/Programming Languages - Hyperpolyglot http://hyperpolyglot.org/ | |||||
Dev/The Elements of Computing Systems / Nisan & Schocken http://www.nand2tetris.org/course.php | |||||
Dev/bayandin/awesome-awesomeness https://github.com/bayandin/awesome-awesomeness | |||||
Dev/deeplearning/CS231n Convolutional Neural Networks Stanford http://cs231n.stanford.edu/ | |||||
Dev/deeplearning/deeplearningbook http://www.deeplearningbook.org/ | |||||
Divers/50YearsDataScience.pdf https://dl.dropboxusercontent.com/u/23421017/50YearsDataScience.pdf | |||||
Divers/A Good Movie to Watch - Highly-Rated, Little-Known Film Suggestions http://agoodmovietowatch.com/ | |||||
Divers/A step by step backpropagation example http://mattmazur.com/2015/03/17/a-step-by-step-backpropagation-example/ | |||||
Divers/BetterExplained | Friendly lessons for lasting insight. http://betterexplained.com/ | |||||
Divers/CLIapps http://www.jaredandcoralee.com/CLIapps.html | |||||
Divers/Dave Conservatoire http://www.daveconservatoire.org/course/introduction-to-sonic-pi | |||||
Divers/DotShare.it http://dotshare.it/ | |||||
Divers/Exploring the Hacker Tools of Mr Robot | HackerTarget.com https://hackertarget.com/hacker-tools-mr-robot// | |||||
Divers/Fellows | Mozilla Science Lab https://www.mozillascience.org/fellows | |||||
Divers/Font Awesome Cheatsheet http://fortawesome.github.io/Font-Awesome/cheatsheet/ | |||||
Divers/Gnod - The Global Network of Discovery http://www.gnod.com/ | |||||
Divers/Graph TV http://graphtv.kevinformatics.com/ | |||||
Divers/Implementing a Neural Network from Scratch – An Introduction | WildML http://www.wildml.com/2015/09/implementing-a-neural-network-from-scratch/ | |||||
Divers/Index of /~miriah/cs6630/lectures http://www.sci.utah.edu/~miriah/cs6630/lectures/ | |||||
Divers/Learning how to code neural networks https://medium.com/learning-new-stuff/how-to-learn-neural-networks-758b78f2736e#.ca646g6j2 | |||||
Divers/Machine learning - overview and applications - YouTube https://www.youtube.com/watch?v=yDLKJtOVx5c&list=PLD0F06AA0D2E8FFBA | |||||
Divers/Method of Action http://method.ac/ | |||||
Divers/Missing Value Treatment - r-statistics.co http://r-statistics.co/Missing-Value-Treatment-With-R.html | |||||
Divers/Navigating the massive world of reddit: using backbone networks to map user interests in social media [ PeerJ ] https://peerj.com/articles/cs-4/ | |||||
Divers/PLOS Computational Biology: Ten Simple Rules for the Care and Feeding of Scientific Data http://journals.plos.org/ploscompbiol/article?id=10.1371/journal.pcbi.1003542 | |||||
Divers/Part2 - I was asked to crack a program in a job interview ! http://erenyagdiran.github.io/I-was-just-asked-to-crack-a-program-Part-2/ | |||||
Divers/Shodan https://www.shodan.io/ | |||||
Divers/Statistical Graphics and Visualization course materials | Civil Statistician http://civilstat.com/2015/10/statistical-graphics-and-visualization-course-materials/ | |||||
Divers/TasteKid | Recommends music, movies, TV shows, books, games http://www.tastekid.com/ | |||||
Divers/The Second Intelligent Species by Marshall Brain http://marshallbrain.com/second-intelligent-species.htm | |||||
Divers/The Wub Machine https://the.wubmachine.com/ | |||||
Divers/ZeroNet: Decentralized websites using Bitcoin crypto and the BitTorrent network http://zeronet.io/ | |||||
Divers/http://nbviewer.ipython.org/gist/msund/d3e00e5e27dff31a7b6d http://nbviewer.ipython.org/gist/msund/d3e00e5e27dff31a7b6d | |||||
Divers/jlevy/the-art-of-command-line https://github.com/jlevy/the-art-of-command-line | |||||
Divers/paulfitz/daff https://github.com/paulfitz/daff | |||||
Download/Download YIFY Torrent for YIFY Movies faster - yify-torrent.org http://www.yify-torrent.org/ | |||||
Download/Links to help you find college textbooks, because they are expensive as hell. - Imgur http://imgur.com/gallery/2PS74yj | |||||
Jeux/Abandonware/Abandonia - Home of abandonware DOS games http://www.abandonia.com/index2.php | |||||
Jeux/Abandonware/Home of the Underdogs http://www.homeoftheunderdogs.net/ | |||||
Jeux/Abandonware/LTF Lost Treasures Fr Abandonware France, l'histoire des vieux jeux video http://www.abandonware-france.org/ | |||||
Jeux/Consoles/Automation Atari ST CD Catalog http://steem.atari.st/automation.htm | |||||
Jeux/Consoles/PSP/PSP-GENERATION http://www.pspgen.com/ | |||||
Jeux/Consoles/PSP/PSX2PSP/PSX on PSP Compatibility List - TheGamersPress http://www.gamerspress.com/index.php?title=PSX_on_PSP_Compatibility_List | |||||
Jeux/Consoles/PSP/PSX2PSP/PSXPSP Manuals http://www.psxpspmanuals.com/ | |||||
Jeux/Consoles/PSP/PSX2PSP/PopStation ImagePacks http://popsdb.twystneko.com/ | |||||
Jeux/Consoles/PSP/PSX2PSP/Sony Index Homepage http://www.sonyindex.com/ | |||||
Jeux/Consoles/Roms/GBA Roms, NDS Roms, We have all the Roms - The Epitome of Emulation! http://www.romulation.net/ | |||||
Jeux/Consoles/Roms/Mondemul.net : Emulateurs, roms et jeux vidéo. http://www.mondemul.net/ | |||||
Jeux/Consoles/Roms/Playstation paradize - Le site des RPG Playstation http://www.psxrenzukoken.com/nk/ | |||||
Jeux/Consoles/VGMaps.com: The Video Game Atlas http://www.vgmaps.com/ | |||||
Jeux/CrossCode http://cross-code.com/en/home#download | |||||
Jeux/Download the latest indie games - itch.io http://itch.io/ | |||||
Jeux/Frontierverse > Missions http://www.sharoma.com/frontierverse/missions.htm | |||||
Jeux/Jeux et Stratégie, les ressources du web - Vox http://laurent36.vox.com/library/post/jeux-et-strat%C3%A9gie-les-ressources-du-web.html | |||||
Jeux/Koikou/Base de test http://francknet.net/koikou/ | |||||
Jeux/Koikou/liste des jeux du koikoukèsse =) - Forum de Nolife http://www.nolife-tv.com/forum/showthread.php?t=966 | |||||
Jeux/Linux/Free Gamer - Open Source Games http://freegamer.blogspot.com/ | |||||
Jeux/Linux/FreeGameDev Planet - Games http://planet.freegamedev.net/ | |||||
Jeux/Linux/Gameolith - The Linux® Game Download Store http://www.gameolith.com/ | |||||
Jeux/Linux/Independent Video Games - Wolfire Games http://www.wolfire.com/ | |||||
Jeux/Linux/Libregamewiki http://libregamewiki.org/Main_Page | |||||
Jeux/Linux/Linux Games | Indie Game Reviewer http://www.indiegamereviewer.com/category/platforms/linux/ | |||||
Jeux/Linux/The Linux Game Tome http://happypenguin.org/ | |||||
Jeux/Main | EteRNA http://eterna.cmu.edu/htmls/action.html?pagedata=Action | |||||
Jeux/TIGSource http://www.tigsource.com/ | |||||
Jeux/TIGTumblr http://tigsource.tumblr.com/ | |||||
Jeux/The Humble Indie Bundle http://www.humblebundle.com/ | |||||
Jeux/The Let's Play Archive http://lparchive.org/ | |||||
Jeux/Upcoming/Among The Sleep http://www.krillbite.com/ats/ | |||||
Jeux/Upcoming/Heart Machine http://www.heart-machine.com/ | |||||
Jeux/Upcoming/Miegakure: A puzzle-platforming game in four dimensions http://marctenbosch.com/miegakure/ | |||||
M2IBM/DailyMed http://dailymed.nlm.nih.gov/dailymed/index.cfm | |||||
M2IBM/Elearning Smbh https://campusvirtuel.smbh.univ-paris13.fr/index.php?category=M2ibm | |||||
M2IBM/Thesorimed http://theso.prod-deux.thesorimed.org/ | |||||
Médecine/BioMart http://www.biomart.org/index.html | |||||
Médecine/Juste après dresseuse d'ours http://www.jaddo.fr/ | |||||
Médecine/Le grand dictionnaire terminologique http://www.granddictionnaire.com/ | |||||
Médecine/Le journal d’un interne en médecine générale, un peu remplaçant aussi | Parce qu’il y a des choses que j’ai envie de partager http://drfoulard.fr/ | |||||
Médecine/Sous la blouse http://sous-la-blouse.blogspot.com/ | |||||
Médecine/Thériaque http://www.theriaque.org/ | |||||
Toys and Games/3D Logic II http://www.jeuxvideo-flash.com/jeu-3172-3d-logic-ii.php | |||||
Toys and Games/Canvas Cycle: True 8-bit Color Cycling with HTML5 http://www.effectgames.com/demos/canvascycle/?sound=0 | |||||
Toys and Games/Cardboard Box Assembler http://games.adultswim.com/cardboard-box-assembler-puzzle-online-game.html | |||||
Toys and Games/Chargement… http://www.nitrome.com/games/faultline/ | |||||
Toys and Games/Coccinelles http://www.koreus.com/jeu/coccinelles.html | |||||
Toys and Games/D I N O * R U N - http://www.pixeljam.com/dinorun/ | |||||
Toys and Games/DOFI-BLOG どふぃぶろぐ Cat on a Dolphin http://ishi.blog2.fc2.com/blog-entry-213.html | |||||
Toys and Games/Enough Plumbers - Play it on Not Doppler http://www.notdoppler.com/enoughplumbers.php | |||||
Toys and Games/Epsilon | Armor Games http://armorgames.com/play/1642/epsilon | |||||
Toys and Games/Free Online Game - Give Up Robot 2 from Adult Swim http://games.adultswim.com/give-up-robot-2-online-game.html | |||||
Toys and Games/Game about Squares http://gameaboutsquares.com/ | |||||
Toys and Games/I Love Traffic | Armor Games http://armorgames.com/play/3515/i-love-traffic | |||||
Toys and Games/Ice Breaker - Nitrome - Play Free Games http://www.nitrome.com/games/icebreaker/ | |||||
Toys and Games/Instants! Collection http://instantsfun.es/ | |||||
Toys and Games/Knuckleheads - Nitrome - Play Free Games http://www.nitrome.com/games/knuckleheads/ | |||||
Toys and Games/Kongregate: Play Fancy Pants Adventure: World 2 http://www.kongregate.com/games/DrNeroCF/fancy-pants-adventure-world-2 | |||||
Toys and Games/Kongregate: Play Fold http://www.kongregate.com/games/joelesler/fold/?referrer=Jayisgames | |||||
Toys and Games/Need For Madness - Car Racing Game, Car Crashing and Stunt Cars Game http://www.radicalplay.com/madness/ | |||||
Toys and Games/OLE Coordinate System - Fun-Motion Physics Games Forum http://www.fun-motion.com/forums/showthread.php?t=1260 | |||||
Toys and Games/OneMoreLevel.com - Sling Jumper http://www.onemorelevel.com/game/sling_jumper | |||||
Toys and Games/OneMoreLevel.com - Spin the Black Circle http://onemorelevel.com/game/spin_the_black_circle | |||||
Toys and Games/Open Doors http://www.koreus.com/jeu/open-doors.html | |||||
Toys and Games/Orbitrunner | Games | Orbitrunner Online Gravitation Game | Free Online Games At Gamezhero.com http://www.gamezhero.com/online-games/sports-games/orbitrunner-games.html | |||||
Toys and Games/Pica Pic | retro handheld games collection http://www.pica-pic.com/# | |||||
Toys and Games/Pixel http://hp.vector.co.jp/authors/VA022293/ | |||||
Toys and Games/Play Chronotron, a free online game on Kongregate http://www.kongregate.com/games/Scarybug/chronotron | |||||
Toys and Games/Play Impasse, a free online game on Kongregate http://www.kongregate.com/games/wanderlands/impasse | |||||
Toys and Games/Polluted Planet Demo http://pollutedplanet.googlepages.com/pollutedplanet.html | |||||
Toys and Games/Portal: The Flash Version http://www.newgrounds.com/portal/view/404612# | |||||
Toys and Games/RRRR : Keep Talking http://www.rrrrthats5rs.com/games/keep-talking/ | |||||
Toys and Games/Red Rogue http://www.newgrounds.com/portal/view/607114 | |||||
Toys and Games/SeppuKuties | Armor Games http://armorgames.com/play/2565/seppukuties | |||||
Toys and Games/Spiderling http://www.newgrounds.com/portal/view/636477 | |||||
Toys and Games/Splitter http://www.freewebarcade.com/game/splitter/ | |||||
Toys and Games/Tactical Assassin http://files.jeuxvideo-flash.com/3b304ed6735bb32204b423e935c3c532/4857fc89/1701.swf | |||||
Toys and Games/The Cryptic Canvas | 50 Movies Hidden In A Painting | Empire | www.empireonline.com http://www.empireonline.com/crypticcanvas/ | |||||
Toys and Games/The World's Hardest Game - Free Arcade & Classic Game from AddictingGames http://www.addictinggames.com/theworldshardestgame.html | |||||
Toys and Games/Yin Yang - Nitrome - Play Free Games http://www.nitrome.com/games/yinyang/index.html | |||||
Toys and Games/as3sfxr http://www.superflashbros.net/as3sfxr/ | |||||
Toys and Games/deepnight.net | Proletarian Ninja X http://deepnight.net/games/proletarian-ninja-x/ | |||||
Toys and Games/pandemic2.swf (Objet application/x-shockwave-flash) http://www.crazymonkeygames.com/jkf6Tr/pandemic2.swf | |||||
Toys and Games/tacticalassassin2.swf (Objet application/x-shockwave-flash) http://www.crazymonkeygames.com/jkf6Tr/tacticalassassin2.swf | |||||
Toys and Games/zoomquilt2.swf (Objet application/x-shockwave-flash) http://zoomquilt2.madmindworx.com/zoomquilt2.swf | |||||
SNCF http://www.voyages-sncf.com/ | |||||
The Pirate Bay onion http://uj3wazyk5u4hnvtk.onion/ | |||||
The art of unix programming (unix philosophy) http://www.catb.org/esr/writings/taoup/html/index.html | |||||
Rmarkdown website http://rmarkdown.rstudio.com/rmarkdown_websites.html | |||||
WHO motor development milestones http://www.who.int/childgrowth/standards/motor_milestones/en/ | |||||
équipe22/réservation salle https://docs.google.com/spreadsheets/d/18wHLTwPtasB_QkhsQLUc0DPIEyCV-Gq6Zf_pCsMSe-o/edit#gid=2080891252 | |||||
vape http://torontovaporizer.ca/vaporizer/utillian-721.html | |||||
git cheatsheet https://github.com/k88hudson/git-flight-rules | |||||
APK downloader https://apps.evozi.com/apk-downloader/?id=com.citymapper.app.release | |||||
apkpure https://apkpure.com/search?q=alarm+droid | |||||
R to python http://n-s-f.github.io/2017/03/25/r-to-python.html | |||||
ggplot2 publication ggpubr http://www.sthda.com/english/articles/24-ggpubr-publication-ready-plots/ | |||||
korean vocabulary practice https://freshkorean.com/2015/01/03/korean-vocabulary-practice-writing-worksheet-1/ | |||||
detective poe http://webtoon.daum.net/webtoon/viewer/37685 | |||||
grey hack http://www.moddb.com/games/grey-hack | |||||
hegp/galaxy http://egp-galaxy1.egp.aphp.fr:8123/login?redirect=%2F | |||||
hegp/redcap dev http://egp-svldcarp3.egp.aphp.fr:81/redcap/ | |||||
hegp/redcap https://egp-svwacarp4.egp.aphp.fr/redcap/ | |||||
hegp/intranet http://portail-cms.aphp.fr/hupo/ | |||||
hegp/i2b2 https://cdw.egp.aphp.fr/ | |||||
hegp/rstudio http://egp-svlwstat1.egp.aphp.fr:8787/ | |||||
hegp/shiny http://egp-svlwstat1.egp.aphp.fr:3838/users/mwk/01_hello/ | |||||
eliquid https://www.eliquidandco.com/ | |||||
hegp/email https://courriel-bsr.aphp.fr/ | |||||
hegp/ent https://ent.parisdescartes.fr/ | |||||
hegp/id_map http://egp-sdlatran2.egp.aphp.fr/id_map/ | |||||
Sci-hub onion http://scihub22266oqcxt.onion/ | |||||
hegp/NAS http://egp-nascarp1.egp.aphp.fr:5000/ | |||||
SIGAPS https://sigaps.aphp.fr/ | |||||
jane http://jane.biosemantics.org/index.php | |||||
Oralia https://myoralia.fr/extranet/monenvironnement_location.php?Urlhash=3505e7b895b5950578e57969f9115505e7b8789578196979792929515e6e6e6e69694989e9915e0e0e0e09694919e9515e3e3e3e39694949f971 | |||||
qutebrowser arch forum https://bbs.archlinux.org/viewtopic.php?id=191076&p=27 | |||||
vim galore https://github.com/mhinz/vim-galore/blob/master/README.md | |||||
Blogs/wlroots https://drewdevault.com/ | |||||
Terminal.sexy https://terminal.sexy/#ICAgzMzMZmZmRSAglt5P5c41ZpnMmWbMZsyZzMzMmZmZc0ByzP-Z__2Amcz_zJn_mf_M8PDw | |||||
torrent https://torrent.maximewack.com/transmission/web/ | |||||
selfhosted https://github.com/Kickball/awesome-selfhosted | |||||
git pretty http://justinhileman.info/article/git-pretty/ | |||||
dataviz https://datavizproject.com/ | |||||
one piece http://www.onepiece-streaming.com/streaming/saga-quatre-empereurs | |||||
blog/R art https://fronkonstin.com/ | |||||
parcours cal https://docs.google.com/spreadsheets/d/17z0eg8EoKjRfguWKNvxZO0RCl50RDtYZ2zmwMu_BL_g/edit?ts=5bb76a7e#gid=0 |
@@ -0,0 +1,161 @@ | |||||
# 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() | |||||
class bulkrename(Command): | |||||
""":bulkrename | |||||
This command opens a list of selected files in an external editor. | |||||
After you edit and save the file, it will generate a shell script | |||||
which does bulk renaming according to the changes you did in the file. | |||||
This shell script is opened in an editor for you to review. | |||||
After you close it, it will be executed. | |||||
""" | |||||
def execute(self): | |||||
import sys | |||||
import tempfile | |||||
from ranger.container.file import File | |||||
from ranger.ext.shell_escape import shell_escape as esc | |||||
py3 = sys.version_info[0] >= 3 | |||||
# Create and edit the file list | |||||
filenames = [f.relative_path for f in self.fm.thistab.get_selection()] | |||||
listfile = tempfile.NamedTemporaryFile(delete=False) | |||||
listpath = listfile.name | |||||
if py3: | |||||
listfile.write("\n".join(filenames).encode("utf-8")) | |||||
else: | |||||
listfile.write("\n".join(filenames)) | |||||
listfile.close() | |||||
self.fm.execute_file([File(listpath)], app='nvim') | |||||
listfile = open(listpath, 'r') | |||||
new_filenames = listfile.read().split("\n") | |||||
listfile.close() | |||||
os.unlink(listpath) | |||||
if all(a == b for a, b in zip(filenames, new_filenames)): | |||||
self.fm.notify("No renaming to be done!") | |||||
return | |||||
# Generate script | |||||
cmdfile = tempfile.NamedTemporaryFile() | |||||
script_lines = [] | |||||
script_lines.append("# This file will be executed when you close the editor.\n") | |||||
script_lines.append("# Please double-check everything, clear the file to abort.\n") | |||||
script_lines.extend("mv -vi -- %s %s\n" % (esc(old), esc(new)) \ | |||||
for old, new in zip(filenames, new_filenames) if old != new) | |||||
script_content = "".join(script_lines) | |||||
if py3: | |||||
cmdfile.write(script_content.encode("utf-8")) | |||||
else: | |||||
cmdfile.write(script_content) | |||||
cmdfile.flush() | |||||
# Open the script and let the user review it, then check if the script | |||||
# was modified by the user | |||||
self.fm.execute_file([File(cmdfile.name)], app='nvim') | |||||
cmdfile.seek(0) | |||||
script_was_edited = (script_content != cmdfile.read()) | |||||
# Do the renaming | |||||
self.fm.run(['/bin/sh', cmdfile.name], flags='w') | |||||
cmdfile.close() | |||||
# Retag the files, but only if the script wasn't changed during review, | |||||
# because only then we know which are the source and destination files. | |||||
if not script_was_edited: | |||||
tags_changed = False | |||||
for old, new in zip(filenames, new_filenames): | |||||
if old != new: | |||||
oldpath = self.fm.thisdir.path + '/' + old | |||||
newpath = self.fm.thisdir.path + '/' + new | |||||
if oldpath in self.fm.tags: | |||||
old_tag = self.fm.tags.tags[oldpath] | |||||
self.fm.tags.remove(oldpath) | |||||
self.fm.tags.tags[newpath] = old_tag | |||||
tags_changed = True | |||||
if tags_changed: | |||||
self.fm.tags.dump() | |||||
else: | |||||
fm.notify("files have not been retagged") | |||||
class playlist(Command): | |||||
""":playlist | |||||
This script creates a playlist for mpv from selection | |||||
""" | |||||
def execute(self): | |||||
import sys | |||||
from ranger.container.file import File | |||||
from ranger.ext.shell_escape import shell_escape as esc | |||||
py3 = sys.version_info[0] >= 3 | |||||
# Create and edit the file list | |||||
filenames = [f.relative_path for f in self.fm.thistab.get_selection()] | |||||
listfile = open("playlist.play" ,'w') | |||||
listfile.write("\n".join(filenames)) | |||||
listfile.close() | |||||
self.fm.mark_files(all=True, val=False) | |||||
self.fm.run('xdotool search --classname Ranger windowunmap') | |||||
self.fm.run('mpv --playlist=' + listfile.name) | |||||
os.unlink(listfile.name) |
@@ -0,0 +1,631 @@ | |||||
# =================================================================== | |||||
# This file contains the default startup commands for ranger. | |||||
# To change them, it is recommended to create the file | |||||
# ~/.config/ranger/rc.conf and add your custom commands there. | |||||
# | |||||
# If you copy this whole file there, you may want to set the environment | |||||
# variable RANGER_LOAD_DEFAULT_RC to FALSE to avoid loading it twice. | |||||
# | |||||
# The purpose of this file is mainly to define keybindings and settings. | |||||
# For running more complex python code, please create a plugin in "plugins/" or | |||||
# a command in "commands.py". | |||||
# | |||||
# Each line is a command that will be run before the user interface | |||||
# is initialized. As a result, you can not use commands which rely | |||||
# on the UI such as :delete or :mark. | |||||
# =================================================================== | |||||
# =================================================================== | |||||
# == Options | |||||
# =================================================================== | |||||
# Which viewmode should be used? Possible values are: | |||||
# miller: Use miller columns which show multiple levels of the hierarchy | |||||
# multipane: Midnight-commander like multipane view showing all tabs next | |||||
# to each other | |||||
set viewmode miller | |||||
#set viewmode multipane | |||||
# How many columns are there, and what are their relative widths? | |||||
set column_ratios 1,1,2,4 | |||||
# Which files should be hidden? (regular expression) | |||||
set hidden_filter ^\.|\.(?:pyc|pyo|bak|swp)$|^lost\+found$|^__(py)?cache__$ | |||||
# Show hidden files? You can toggle this by typing 'zh' | |||||
set show_hidden false | |||||
# Ask for a confirmation when running the "delete" command? | |||||
# Valid values are "always", "never", "multiple" (default) | |||||
# With "multiple", ranger will ask only if you delete multiple files at once. | |||||
set confirm_on_delete multiple | |||||
# Use non-default path for file preview script? | |||||
# ranger ships with scope.sh, a script that calls external programs (see | |||||
# README.md for dependencies) to preview images, archives, etc. | |||||
set preview_script ~/.config/ranger/scope.sh | |||||
# Use the external preview script or display simple plain text or image previews? | |||||
set use_preview_script true | |||||
# Automatically count files in the directory, even before entering them? | |||||
set automatically_count_files true | |||||
# Open all images in this directory when running certain image viewers | |||||
# like feh or sxiv? You can still open selected files by marking them. | |||||
set open_all_images true | |||||
# Be aware of version control systems and display information. | |||||
set vcs_aware true | |||||
# State of the four backends git, hg, bzr, svn. The possible states are | |||||
# disabled, local (only show local info), enabled (show local and remote | |||||
# information). | |||||
set vcs_backend_git enabled | |||||
set vcs_backend_hg disabled | |||||
set vcs_backend_bzr disabled | |||||
set vcs_backend_svn disabled | |||||
# Use one of the supported image preview protocols | |||||
set preview_images true | |||||
# Set the preview image method. Supported methods: | |||||
# | |||||
# * w3m (default): | |||||
# Preview images in full color with the external command "w3mimgpreview"? | |||||
# This requires the console web browser "w3m" and a supported terminal. | |||||
# It has been successfully tested with "xterm" and "urxvt" without tmux. | |||||
# | |||||
# * iterm2: | |||||
# Preview images in full color using iTerm2 image previews | |||||
# (http://iterm2.com/images.html). This requires using iTerm2 compiled | |||||
# with image preview support. | |||||
# | |||||
# This feature relies on the dimensions of the terminal's font. By default, a | |||||
# width of 8 and height of 11 are used. To use other values, set the options | |||||
# iterm2_font_width and iterm2_font_height to the desired values. | |||||
# | |||||
# * urxvt: | |||||
# Preview images in full color using urxvt image backgrounds. This | |||||
# requires using urxvt compiled with pixbuf support. | |||||
# | |||||
# * urxvt-full: | |||||
# The same as urxvt but utilizing not only the preview pane but the | |||||
# whole terminal window. | |||||
set preview_images_method kitty | |||||
# Default iTerm2 font size (see: preview_images_method: iterm2) | |||||
set iterm2_font_width 8 | |||||
set iterm2_font_height 11 | |||||
# Use a unicode "..." character to mark cut-off filenames? | |||||
set unicode_ellipsis false | |||||
# Show dotfiles in the bookmark preview box? | |||||
set show_hidden_bookmarks true | |||||
# Which colorscheme to use? These colorschemes are available by default: | |||||
# default, jungle, snow, solarized | |||||
set colorscheme default | |||||
# Preview files on the rightmost column? | |||||
# And collapse (shrink) the last column if there is nothing to preview? | |||||
set preview_files true | |||||
set preview_directories true | |||||
set collapse_preview true | |||||
# Save the console history on exit? | |||||
set save_console_history true | |||||
# Draw the status bar on top of the browser window (default: bottom) | |||||
set status_bar_on_top false | |||||
# Draw a progress bar in the status bar which displays the average state of all | |||||
# currently running tasks which support progress bars? | |||||
set draw_progress_bar_in_status_bar true | |||||
# Draw borders around columns? | |||||
set draw_borders true | |||||
# Display the directory name in tabs? | |||||
set dirname_in_tabs true | |||||
# Enable the mouse support? | |||||
set mouse_enabled true | |||||
# Display the file size in the main column or status bar? | |||||
set display_size_in_main_column true | |||||
set display_size_in_status_bar true | |||||
# Display files tags in all columns or only in main column? | |||||
set display_tags_in_all_columns true | |||||
# Set a title for the window? | |||||
set update_title false | |||||
# Set the title to "ranger" in the tmux program? | |||||
set update_tmux_title false | |||||
# Shorten the title if it gets long? The number defines how many | |||||
# directories are displayed at once, 0 turns off this feature. | |||||
set shorten_title 3 | |||||
# Show hostname in titlebar? | |||||
set hostname_in_titlebar true | |||||
# Abbreviate $HOME with ~ in the titlebar (first line) of ranger? | |||||
set tilde_in_titlebar false | |||||
# How many directory-changes or console-commands should be kept in history? | |||||
set max_history_size 20 | |||||
set max_console_history_size 50 | |||||
# Try to keep so much space between the top/bottom border when scrolling: | |||||
set scroll_offset 8 | |||||
# Flush the input after each key hit? (Noticeable when ranger lags) | |||||
set flushinput true | |||||
# Padding on the right when there's no preview? | |||||
# This allows you to click into the space to run the file. | |||||
set padding_right false | |||||
# Save bookmarks (used with mX and `X) instantly? | |||||
# This helps to synchronize bookmarks between multiple ranger | |||||
# instances but leads to *slight* performance loss. | |||||
# When false, bookmarks are saved when ranger is exited. | |||||
set autosave_bookmarks true | |||||
# Save the "`" bookmark to disk. This can be used to switch to the last | |||||
# directory by typing "``". | |||||
set save_backtick_bookmark true | |||||
# You can display the "real" cumulative size of directories by using the | |||||
# command :get_cumulative_size or typing "dc". The size is expensive to | |||||
# calculate and will not be updated automatically. You can choose | |||||
# to update it automatically though by turning on this option: | |||||
set autoupdate_cumulative_size false | |||||
# Turning this on makes sense for screen readers: | |||||
set show_cursor false | |||||
# One of: size, natural, basename, atime, ctime, mtime, type, random | |||||
set sort natural | |||||
# Additional sorting options | |||||
set sort_reverse false | |||||
set sort_case_insensitive true | |||||
set sort_directories_first true | |||||
set sort_unicode false | |||||
# Enable this if key combinations with the Alt Key don't work for you. | |||||
# (Especially on xterm) | |||||
set xterm_alt_key false | |||||
# Whether to include bookmarks in cd command | |||||
set cd_bookmarks true | |||||
# Changes case sensitivity for the cd command tab completion | |||||
set cd_tab_case sensitive | |||||
# Use fuzzy tab completion with the "cd" command. For example, | |||||
# ":cd /u/lo/b<tab>" expands to ":cd /usr/local/bin". | |||||
set cd_tab_fuzzy true | |||||
# Avoid previewing files larger than this size, in bytes. Use a value of 0 to | |||||
# disable this feature. | |||||
set preview_max_size 100000000 | |||||
# Add the highlighted file to the path in the titlebar | |||||
set show_selection_in_titlebar true | |||||
# The delay that ranger idly waits for user input, in milliseconds, with a | |||||
# resolution of 100ms. Lower delay reduces lag between directory updates but | |||||
# increases CPU load. | |||||
set idle_delay 2000 | |||||
# When the metadata manager module looks for metadata, should it only look for | |||||
# a ".metadata.json" file in the current directory, or do a deep search and | |||||
# check all directories above the current one as well? | |||||
set metadata_deep_search false | |||||
# Clear all existing filters when leaving a directory | |||||
set clear_filters_on_dir_change true | |||||
# Disable displaying line numbers in main column | |||||
set line_numbers false | |||||
# Start line numbers from 1 instead of 0 | |||||
set one_indexed false | |||||
# Save tabs on exit | |||||
set save_tabs_on_exit true | |||||
# Enable scroll wrapping - moving down while on the last item will wrap around to | |||||
# the top and vice versa. | |||||
set wrap_scroll false | |||||
# Set the global_inode_type_filter to nothing. Possible options: d, f and l for | |||||
# directories, files and symlinks respectively. | |||||
set global_inode_type_filter | |||||
# =================================================================== | |||||
# == Local Options | |||||
# =================================================================== | |||||
# You can set local options that only affect a single directory. | |||||
# Examples: | |||||
# setlocal path=~/downloads sort mtime | |||||
# =================================================================== | |||||
# == Command Aliases in the Console | |||||
# =================================================================== | |||||
map e chain draw_possible_programs; console open_with%%space | |||||
alias q quit | |||||
alias q! quitall | |||||
alias qall quitall | |||||
alias setl setlocal | |||||
alias filter scout -prts | |||||
alias find scout -aetlsf | |||||
alias mark scout -mr | |||||
alias unmark scout -Mr | |||||
alias search scout -rs | |||||
alias search_inc scout -rts | |||||
alias travel scout -aefklst | |||||
# =================================================================== | |||||
# == Define keys for the browser | |||||
# =================================================================== | |||||
# Basic | |||||
map Q quitall | |||||
map q quit | |||||
copymap q ZZ ZQ | |||||
map R reload_cwd | |||||
map F set freeze_files! | |||||
map <C-r> reset | |||||
map <C-l> redraw_window | |||||
map <C-c> abort | |||||
map <esc> change_mode normal | |||||
map zM set viewmode! | |||||
map i display_file | |||||
map ? help | |||||
map W display_log | |||||
map w taskview_open | |||||
map S shell $SHELL | |||||
map : console | |||||
map ; console | |||||
map ^ terminal | |||||
map ! shell $SHELL | |||||
map @ console -p6 shell %%s | |||||
map # console -p9 shell -w %%s | |||||
map f console find%space | |||||
map cd console cd%space | |||||
# Tagging / Marking | |||||
map <Space> mark_files toggle=True | |||||
map v mark_files all=True toggle=True | |||||
map uv mark_files all=True val=False | |||||
map V 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 E edit | |||||
map <F5> copy | |||||
map <F6> cut | |||||
map <F7> console mkdir%space | |||||
map <F8> console delete | |||||
map <F10> exit | |||||
# Bepo-vim movement | |||||
map t move left=1 | |||||
map s move down=1 | |||||
map r move right=1 | |||||
map d move up=1 | |||||
# 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 x console delete | |||||
map <INSERT> console touch%space | |||||
map S move down=0.5 pages=True | |||||
map D move up=0.5 pages=True | |||||
copymap J <C-D> | |||||
copymap K <C-U> | |||||
# Jumping around | |||||
map T history_go -1 | |||||
map R history_go 1 | |||||
map ] move_parent 1 | |||||
map [ move_parent -1 | |||||
map } traverse | |||||
map gh cd ~ | |||||
map ge cd /etc | |||||
map gu cd /usr | |||||
map gd cd /dev | |||||
map gl cd -r . | |||||
map gL cd -r %f | |||||
map go cd /opt | |||||
map gv cd /var | |||||
map gm cd /media | |||||
map gM cd /mnt | |||||
map gs cd /srv | |||||
map gr cd / | |||||
map gR eval fm.cd(ranger.RANGERDIR) | |||||
map g/ cd / | |||||
map g? cd /usr/share/doc/ranger | |||||
# External Programs | |||||
map E edit | |||||
map lu shell -p du --max-depth=1 -h --apparent-size | |||||
map lU shell -p du --max-depth=1 -h --apparent-size | sort -rh | |||||
map yp yank path | |||||
map yd yank dir | |||||
map yn yank name | |||||
# Filesystem Operations | |||||
map = chmod | |||||
map cw console rename%space | |||||
map C console rename%space | |||||
map A eval fm.open_console('rename ' + fm.thisfile.basename) | |||||
map I eval fm.open_console('rename ' + fm.thisfile.basename, position=7) | |||||
map pp paste | |||||
map po paste overwrite=True | |||||
map pl paste_symlink relative=False | |||||
map pL paste_symlink relative=True | |||||
map phl paste_hardlink | |||||
map pht paste_hardlinked_subtree | |||||
map ll cut | |||||
map ud uncut | |||||
map la cut mode=add | |||||
map lr cut mode=remove | |||||
map yy copy | |||||
map uy uncut | |||||
map ya copy mode=add | |||||
map yr copy mode=remove | |||||
# Temporary workarounds | |||||
map lgg eval fm.cut(dirarg=dict(to=0), narg=quantifier) | |||||
map lG eval fm.cut(dirarg=dict(to=-1), narg=quantifier) | |||||
map lj eval fm.cut(dirarg=dict(down=1), narg=quantifier) | |||||
map lk 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 | |||||
# 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 gl 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 | |||||
# Sorting | |||||
map or set 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 lc get_cumulative_size | |||||
# Settings | |||||
map zc set collapse_preview! | |||||
map zd set sort_directories_first! | |||||
map zh set show_hidden! | |||||
map <C-h> set show_hidden! | |||||
map zI set flushinput! | |||||
map zi set preview_images! | |||||
map zm set mouse_enabled! | |||||
map zp set preview_files! | |||||
map zP set preview_directories! | |||||
map zs set sort_case_insensitive! | |||||
map zu set autoupdate_cumulative_size! | |||||
map zv set use_preview_script! | |||||
map zf console filter%space | |||||
map zF filter | |||||
map zg console travel%space | |||||
# Bookmarks | |||||
map `<any> enter_bookmark %any | |||||
map '<any> enter_bookmark %any | |||||
map m<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)) | |||||
# =================================================================== | |||||
# == Define keys for the console | |||||
# =================================================================== | |||||
# Note: Unmapped keys are passed directly to the console. | |||||
# 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) | |||||
cmap <a-left> eval fm.ui.console.move_word(left=1) | |||||
cmap <a-right> eval fm.ui.console.move_word(right=1) | |||||
# 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 Keybindings | |||||
# =================================================================== | |||||
# Movement | |||||
pmap s pager_move down=1 | |||||
pmap d pager_move up=1 | |||||
pmap t pager_move left=4 | |||||
pmap r pager_move right=4 | |||||
pmap gg pager_move to=0 | |||||
pmap G pager_move to=-1 | |||||
pmap <pagedown> pager_move down=1.0 pages=True | |||||
pmap <pageup> pager_move up=1.0 pages=True | |||||
pmap S pager_move down=0.5 pages=True | |||||
pmap D 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 d taskview_move up=1 | |||||
tmap s taskview_move down=1 | |||||
tmap gg taskview_move to=0 | |||||
tmap G taskview_move to=-1 | |||||
tmap <pagedown> taskview_move down=1.0 pages=True | |||||
tmap <pageup> taskview_move up=1.0 pages=True | |||||
tmap S taskview_move down=0.5 pages=True | |||||
tmap D 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 S eval -q fm.ui.taskview.task_move(-1) | |||||
tmap D eval -q fm.ui.taskview.task_move(0) | |||||
tmap ll 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> |
@@ -0,0 +1,190 @@ | |||||
# 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) | |||||
# 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. | |||||
# mime application.x-executable, flag f = setxkbmap us;"$1";setxkbmap bepo | |||||
mime application.x-executable, flag f = $1 | |||||
#------------------------------------------- | |||||
# 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 qutebrowser, X, flag f = qutebrowser -- "$@" | |||||
ext x?html?, has firefox, X, flag f = firefox -- "$@" | |||||
ext x?html?, has chromium, X, flag f = chromium -- "$@" | |||||
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 | |||||
#------------------------------------------- | |||||
ext 1 = man "$1" | |||||
ext s[wmf]c, has zsnes, X = zsnes "$1" | |||||
ext nes, has fceux, X = fceux "$1" | |||||
ext exe = wine "$1" | |||||
name ^[mM]akefile$ = make | |||||
ext epub, X, flag f = ebook-viewer "$1" | |||||
mime ^text, flag f, ext srt = gaupol "$@" | |||||
#-------------------------------------------- | |||||
# Code | |||||
#------------------------------------------- | |||||
ext py = python -- "$1" | |||||
ext pl = perl -- "$1" | |||||
ext rb = ruby -- "$1" | |||||
ext sh, flag t = sh -- "$1" | |||||
ext php = php -- "$1" | |||||
#-------------------------------------------- | |||||
# database | |||||
#-------------------------------------------- | |||||
ext db, X, flag f = sqliteman "$@" | |||||
#-------------------------------------------- | |||||
# Audio without X | |||||
#------------------------------------------- | |||||
mime ^audio|ogg$, terminal, has mplayer = mplayer -- "$@" | |||||
mime ^audio|ogg$, terminal, has mplayer2 = mplayer2 -- "$@" | |||||
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 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 mpv, X, flag f = popup Ranger && mpv -- "$@" | |||||
mime ^video|audio, has totem, X, flag f = totem -- "$@" | |||||
mime ^video|audio, has totem, X, flag f = totem --fullscreen -- "$@" | |||||
ext play, has mpv, X, flag f = popup Ranger && mpv --playlist="$@" | |||||
#-------------------------------------------- | |||||
# Video without X: | |||||
#------------------------------------------- | |||||
mime ^video, terminal, !X, has mplayer2 = mplayer2 -- "$@" | |||||
mime ^video, terminal, !X, has mplayer = mplayer -- "$@" | |||||
#------------------------------------------- | |||||
# Image Viewing: | |||||
#------------------------------------------- | |||||
mime ^image, ext svg, has inkscape, X, flag f = inkscape -- "$@" | |||||
mime ^image, has eog, X, flag f = eog -- "$@" | |||||
mime ^image, has sxiv, X, flag f = sxiv -absf "$@" | |||||
mime ^image, has feh, X, flag f = feh -- "$@" | |||||
mime ^image, has mirage, X, flag f = mirage -- "$@" | |||||
mime ^image, has gimp, X, flag f = gimp -- "$@" | |||||
ext xcf, X, flag f = gimp -- "$@" | |||||
#------------------------------------------- | |||||
# Documents | |||||
#------------------------------------------- | |||||
ext pdf, has zathura, X, flag f = zathura -- "$@" | |||||
ext docx?, has catdoc, terminal = catdoc -- "$@" | "$PAGER" | |||||
ext sxc|xlsx?|xlt|xlw|gnm|gnumeric|csv, has gnumeric, X, flag f = gnumeric -- "$@" | |||||
ext sxc|xlsx?|xlt|xlw|gnm|gnumeric|csv, has kspread, X, flag f = kspread -- "$@" | |||||
ext doc, X, flag f = env WINEPREFIX=/home/maxx/.office wine start /ProgIDOpen Word.Document.8 "$@" | |||||
ext docx, X, flag f = env WINEPREFIX=/home/maxx/.office wine start /ProgIDOpen Word.Document.12 "$@" | |||||
ext xls, X, flag f = env WINEPREFIX=/home/maxx/.office wine start /ProgIDOpen Excel.Sheet.8 "$@" | |||||
ext xlsx, X, flag f = env WINEPREFIX=/home/maxx/.office wine start /ProgIDOpen Excel.Sheet.12 "$@" | |||||
ext ppt, X, flag f = env WINEPREFIX=/home/maxx/.office wine start /ProgIDOpen Powerpoint.Show.8 "$@" | |||||
ext pptx, X, flag f = env WINEPREFIX=/home/maxx/.office wine start /ProgIDOpen Powerpoint.Show.12 "$@" | |||||
ext od[dfgpst]|docx?|sxc|xlsx?|xlt|xlw|gnm|gnumeric|csv, has libreoffice, X, flag f = libreoffice "$@" | |||||
ext od[dfgpst]|docx?|sxc|xlsx?|xlt|xlw|gnm|gnumeric|csv, has soffice, X, flag f = soffice "$@" | |||||
ext od[dfgpst]|docx?|sxc|xlsx?|xlt|xlw|gnm|gnumeric|csv, has ooffice, X, flag f = ooffice "$@" | |||||
ext djvu, has evince, X, flag f = evince -- "$@" | |||||
#------------------------------------------- | |||||
# Archives | |||||
#------------------------------------------- | |||||
# This requires atool | |||||
ext 7z|ace|ar|arc|bz2?|cab|cpio|cpt|deb|dgc|dmg|gz, has aunpack = atool -X . -- "$@" | |||||
ext iso|jar|msi|pkg|rar|shar|tar|tgz|xar|xpi|xz|zip, has aunpack = atool -X . -- "$@" | |||||
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" | |||||
# Fallback: | |||||
ext tar|gz, has tar = tar vvtf "$@" | "$PAGER" | |||||
ext tar|gz, has tar = tar vvxf "$@" | |||||
#------------------------------------------- | |||||
# Misc | |||||
#------------------------------------------- | |||||
label wallpaper, number 11, mime ^image, X = feh --bg-scale "$1" | |||||
label wallpaper, number 12, mime ^image, X = feh --bg-tile "$1" | |||||
label wallpaper, number 13, mime ^image, X = feh --bg-center "$1" | |||||
label wallpaper, number 14, mime ^image, X = feh --bg-fill "$1" | |||||
# Define the editor + pager as last action | |||||
!mime ^text, !ext xml|csv|tex|py|pl|rb|sh|php = ask | |||||
label editor, X, flag t, !mime ^text, !ext xml|csv|tex|py|pl|rb|sh|php = "$EDITOR" -- "$@" | |||||
label pager, X, flag t, !mime ^text, !ext xml|csv|tex|py|pl|rb|sh|php = "$PAGER" -- "$@" | |||||
mime ^text, X, flag t, label editor = "$EDITOR" -- "$@" | |||||
mime ^text, X, flag t, label pager = "$PAGER" -- "$@" | |||||
!mime ^text, X, flag t, label editor, ext R|xml|tex|py|pl|rb|sh|php = "$EDITOR" -- "$@" | |||||
!mime ^text, X, flag t, label pager, ext R|xml|tex|py|pl|rb|sh|php = "$PAGER" -- "$@" | |||||
!mime ^text, X, flag t, editor = "$EDITOR" -- "$@" | |||||
!mime ^text, X, flag t, editor = "$PAGER" -- "$@" | |||||
label editor, terminal, !mime ^text, !ext xml|csv|tex|py|pl|rb|sh|php = "$EDITOR" -- "$@" | |||||
label pager, terminal, !mime ^text, !ext xml|csv|tex|py|pl|rb|sh|php = "$PAGER" -- "$@" | |||||
mime ^text, terminal, label editor = "$EDITOR" -- "$@" | |||||
mime ^text, terminal, label pager = "$PAGER" -- "$@" | |||||
!mime ^text, terminal, label editor, ext R|xml|tex|py|pl|rb|sh|php = "$EDITOR" -- "$@" | |||||
!mime ^text, terminal, label pager, ext R|xml|tex|py|pl|rb|sh|php = "$PAGER" -- "$@" | |||||
!mime ^text, terminal, editor = "$EDITOR" -- "$@" | |||||
!mime ^text, terminal, editor = "$PAGER" -- "$@" |
@@ -0,0 +1,124 @@ | |||||
#!/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;; | |||||
# Image preview for videos, disabled by default: | |||||
video/*) | |||||
ffmpegthumbnailer -i "$path" -o "$cached" -s 0 && exit 6 || 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 |
@@ -0,0 +1,15 @@ | |||||
[redshift] | |||||
temp-day=5500 | |||||
temp-night=3500 | |||||
transition=1 | |||||
brightness=1 | |||||
location-provider=manual | |||||
adjustment-method=randr | |||||
[manual] | |||||
lat=48.35 | |||||
lon=6 |
@@ -0,0 +1,15 @@ | |||||
rofi.terminal: kitty | |||||
rofi.theme: theme.rasi | |||||
rofi.scroll-method: 1 | |||||
rofi.show-icons: true | |||||
rofi.kb-row-tab: | |||||
rofi.kb-mode-next: Tab | |||||
rofi.monitor: -1 | |||||
rofi.combi-hide-mode-prefix: true | |||||
rofi.hide-scrollbar: true | |||||
rofi.sidebar-mode: true | |||||
rofi.padding: 10 | |||||
rofi.bw: 0 | |||||
rofi.lines: 10 | |||||
rofi.combi-modi: drun,run | |||||
rofi.modi: combi,calc:qalc +u8 -nocurrencies,clipboard:greenclip print,emoji:~/.config/rofi/splatmoji |
@@ -0,0 +1,9 @@ | |||||
#!/bin/bash | |||||
if [ -z $@ ] | |||||
then | |||||
cat ~/.config/rofi/emoji.tsv ~/.config/rofi/emoticons.tsv | |||||
else | |||||
IFS='';emoji=$@ | |||||
echo $emoji | cut -f 1 -z | xsel -b > /dev/null | |||||
fi |
@@ -0,0 +1,139 @@ | |||||
/************************************************ | |||||
* ROFI Color theme | |||||
* User: leofa | |||||
* Copyright: 2017 leofa | |||||
***********************************************/ | |||||
* { | |||||
selected-normal-foreground: rgba ( 249, 249, 249, 100 % ); | |||||
foreground: rgba ( 196, 203, 212, 100 % ); | |||||
normal-foreground: @foreground; | |||||
alternate-normal-background: rgba ( 64, 69, 82, 59 % ); | |||||
red: rgba ( 220, 50, 47, 100 % ); | |||||
selected-urgent-foreground: rgba ( 249, 249, 249, 100 % ); | |||||
blue: rgba ( 38, 139, 210, 100 % ); | |||||
urgent-foreground: rgba ( 204, 102, 102, 100 % ); | |||||
alternate-urgent-background: rgba ( 75, 81, 96, 90 % ); | |||||
active-foreground: rgba ( 101, 172, 255, 100 % ); | |||||
lightbg: rgba ( 238, 232, 213, 100 % ); | |||||
selected-active-foreground: rgba ( 249, 249, 249, 100 % ); | |||||
alternate-active-background: rgba ( 75, 81, 96, 89 % ); | |||||
background: rgba ( 45, 48, 59, 95 % ); | |||||
alternate-normal-foreground: @foreground; | |||||
normal-background: @background; | |||||
lightfg: rgba ( 88, 104, 117, 100 % ); | |||||
selected-normal-background: rgba ( 64, 132, 214, 100 % ); | |||||
border-color: rgba ( 124, 131, 137, 100 % ); | |||||
spacing: 2; | |||||
separatorcolor: rgba ( 29, 31, 33, 100 % ); | |||||
urgent-background: rgba ( 29, 31, 33, 17 % ); | |||||
selected-urgent-background: rgba ( 165, 66, 66, 100 % ); | |||||
alternate-urgent-foreground: @urgent-foreground; | |||||
background-color: rgba ( 0, 0, 0, 0 % ); | |||||
alternate-active-foreground: @active-foreground; | |||||
active-background: rgba ( 29, 31, 33, 17 % ); | |||||
selected-active-background: rgba ( 68, 145, 237, 100 % ); | |||||
} | |||||
#window { | |||||
background-color: @background; | |||||
border: 1; | |||||
padding: 5; | |||||
} | |||||
#mainbox { | |||||
border: 0; | |||||
padding: 0; | |||||
} | |||||
#message { | |||||
border: 2px 0px 0px ; | |||||
border-color: @separatorcolor; | |||||
padding: 1px ; | |||||
} | |||||
#textbox { | |||||
text-color: @foreground; | |||||
} | |||||
#listview { | |||||
fixed-height: 0; | |||||
border: 2px 0px 0px ; | |||||
border-color: @separatorcolor; | |||||
spacing: 2px ; | |||||
scrollbar: false; | |||||
padding: 2px 0px 0px ; | |||||
} | |||||
#element { | |||||
border: 0; | |||||
padding: 1px ; | |||||
} | |||||
#element.normal.normal { | |||||
background-color: @normal-background; | |||||
text-color: @normal-foreground; | |||||
} | |||||
#element.normal.urgent { | |||||
background-color: @urgent-background; | |||||
text-color: @urgent-foreground; | |||||
} | |||||
#element.normal.active { | |||||
background-color: @active-background; | |||||
text-color: @active-foreground; | |||||
} | |||||
#element.selected.normal { | |||||
background-color: @selected-normal-background; | |||||
text-color: @selected-normal-foreground; | |||||
} | |||||
#element.selected.urgent { | |||||
background-color: @selected-urgent-background; | |||||
text-color: @selected-urgent-foreground; | |||||
} | |||||
#element.selected.active { | |||||
background-color: @selected-active-background; | |||||
text-color: @selected-active-foreground; | |||||
} | |||||
#element.alternate.normal { | |||||
background-color: @alternate-normal-background; | |||||
text-color: @alternate-normal-foreground; | |||||
} | |||||
#element.alternate.urgent { | |||||
background-color: @alternate-urgent-background; | |||||
text-color: @alternate-urgent-foreground; | |||||
} | |||||
#element.alternate.active { | |||||
background-color: @alternate-active-background; | |||||
text-color: @alternate-active-foreground; | |||||
} | |||||
#sidebar { | |||||
border: 2px 0px 0px ; | |||||
border-color: @separatorcolor; | |||||
} | |||||
#button { | |||||
spacing: 0; | |||||
text-color: @normal-foreground; | |||||
} | |||||
#button.selected { | |||||
background-color: @selected-normal-background; | |||||
text-color: @selected-normal-foreground; | |||||
} | |||||
#inputbar { | |||||
spacing: 0; | |||||
text-color: @normal-foreground; | |||||
padding: 1px ; | |||||
} | |||||
#case-indicator { | |||||
spacing: 0; | |||||
text-color: @normal-foreground; | |||||
} | |||||
#entry { | |||||
spacing: 0; | |||||
text-color: @normal-foreground; | |||||
} | |||||
#prompt { | |||||
spacing: 0; | |||||
text-color: @normal-foreground; | |||||
} | |||||
#inputbar { | |||||
children: [ prompt,textbox-prompt-colon,entry,case-indicator ]; | |||||
} | |||||
#textbox-prompt-colon { | |||||
expand: false; | |||||
str: ":"; | |||||
margin: 0px 0.3em 0em 0em ; | |||||
text-color: @normal-foreground; | |||||
} |
@@ -0,0 +1,223 @@ | |||||
# vim: sw=1:fdm=indent:fdl=0 | |||||
# | |||||
# bspwm hotkeys | |||||
# | |||||
# Quit bspwm | |||||
super + ctrl + Escape | |||||
pkill -x panel; bspc quit | |||||
## Desktop | |||||
# Move desktop (with focused node) to the left | |||||
super + {_,shift} + v | |||||
bspc {desktop -f prev.local,node -d prev.local --follow}; \ | |||||
clear_desktops | |||||
# Move desktop (with focused node) to the right | |||||
super + {_,shift} + l | |||||
last=`cat /tmp/lastdesk`; \ | |||||
if [ `bspc query -D -d focused --names` -eq "$last" ]; then; \ | |||||
let "last += 1"; \ | |||||
echo $last > /tmp/lastdesk; \ | |||||
bspc monitor -a $last; \ | |||||
fi; \ | |||||
bspc {desktop -f next.local,node -d next.local --follow}; \ | |||||
clear_desktops | |||||
# Send node to a new empty desktop at the far right (and follow) | |||||
super + {_,shift} + j | |||||
echo `bspc query -D -d focused --names` > /tmp/desk; \ | |||||
last=`cat /tmp/lastdesk`; \ | |||||
let "last += 1"; \ | |||||
echo $last > /tmp/lastdesk; \ | |||||
bspc monitor -a $last; \ | |||||
bspc node -d "$last" {_,--follow}; \ | |||||
clear_desktops | |||||
# Go to last node and back (optionally carrying a node) | |||||
super + {_,shift} + n | |||||
old=`cat /tmp/desk`; \ | |||||
current=`bspc query -D -d focused --names`; \ | |||||
last=`cat /tmp/lastdesk`; \ | |||||
if [[ "$current" == "$last" ]]; then; \ | |||||
target="$old"; \ | |||||
else; \ | |||||
target="$last"; \ | |||||
echo $current > /tmp/desk; \ | |||||
fi; \ | |||||
bspc {desktop -f "$target",node -d "$target" --follow}; \ | |||||
clear_desktops | |||||
# Rotate desktop | |||||
super + {q,h} | |||||
bspc node @focused:/ -R {270,90} | |||||
# Toggle monitor focus | |||||
super + m | |||||
bspc monitor -f next | |||||
# Move node to the other monitor | |||||
super + shift + m | |||||
win=`bspc query -N -n focused`; \ | |||||
bspc node -m next; \ | |||||
bspc monitor -f next; \ | |||||
bspc node -f $win; \ | |||||
clear_desktops | |||||
# Go to desktop | |||||
super + {quotedbl,guillemotleft,guillemotright,parenleft,parenright,Delete,at,plus,minus,slash} | |||||
bspc desktop -f {^1,^2,^3,^4,^5,^6,^7,^8,^9,^10}; \ | |||||
clear_desktops | |||||
# Move node to desktop n | |||||
super + shift + {quotedbl,guillemotleft,guillemotright,parenleft,parenright,Delete,at,plus,minus,slash} | |||||
bspc node -d {^1,^2,^3,^4,^5,^6,^7,^8,^9,^10} --follow; \ | |||||
clear_desktops | |||||
# Balance desktop | |||||
super + k | |||||
bspc node @focused:/ -B | |||||
## node | |||||
# Focus/swap to DIR | |||||
super + {_,shift + }{t,s,d,r} | |||||
bspc node -{f,s} {west,south,north,east} | |||||
# Focus to CYCLE_DIR | |||||
super + w | |||||
bspc node -f next.local | |||||
# Preselect node to DIR | |||||
super + ctrl + {t,s,d,r} | |||||
bspc node -p \~{west,south,north,east} | |||||
# Resize node to DIR | |||||
super + alt + {t,s,d,r} | |||||
bspc node @{west -r -10,south -r +10,north -r -10,east -r +10} | |||||
super + alt + shift + {t,s,d,r} | |||||
bspc node @{east -r -10,north -r +10,south -r -10,west -r +10} | |||||
# Toggle floating/pseudo_tiles/fullscreen | |||||
super + {y,x,period} | |||||
bspc node -t \~{floating,tiled,fullscreen} | |||||
# Move to presel | |||||
super + b | |||||
bspc node -n last.!automatic | |||||
# Close node | |||||
super + {g,agrave} | |||||
bspc node -c | |||||
# wm independent hotkeys | |||||
# | |||||
# File explorer | |||||
super + space | |||||
popup Ranger ranger | |||||
# Popup utils | |||||
# Music | |||||
super + a | |||||
popup Music_playlist ncmpcpp -s playlist ; \ | |||||
popup Music_media ncmpcpp -s media_library | |||||
super + eacute | |||||
popup Music_playlist_home ncmpcpp -s playlist -h 192.168.0.121 ; \ | |||||
popup Music_media_home ncmpcpp -s media_library -h 192.168.0.121 | |||||
# Torrent | |||||
super + i | |||||
popup Torrent transmission-remote-cli | |||||
# xdotool search --onlyvisible --classname Torrent windowunmap ||\ | |||||
# xdotool search --classname Torrent windowmap ||\ | |||||
# kitty --name Torrent transmission-remote-cli | |||||
# Wiki | |||||
super + u | |||||
popup Wiki nvim ~/Private/vimwiki/index.wiki | |||||
# Volume | |||||
super + e | |||||
popup Volume pulsemixer | |||||
# Weather | |||||
super + p | |||||
xdotool search --onlyvisible --classname Meteo windowkill ||\ | |||||
kitty --override background_opacity=0 -o background='#000000' -o font_size=9 --hold --name Meteo meteo_display && meteo | |||||
# Pin pop-up window | |||||
super + shift + space | |||||
bspc node -g sticky=off -t tiled &&\ | |||||
xdotool getactivewindow set_window --classname urxvt | |||||
# Launcher | |||||
super + alt + space | |||||
rofi -font "monofur for Powerline 18" -show | |||||
# Show conky | |||||
super + c | |||||
if [ `bspc config -d focused left_padding` -gt 0 ]; then;\ | |||||
start=500;\ | |||||
step=-20;\ | |||||
end=0;\ | |||||
else;\ | |||||
start=0;\ | |||||
step=20;\ | |||||
end=500;\ | |||||
fi;\ | |||||
for pad in `seq $start $step $end`; do;\ | |||||
bspc config -d focused left_padding $pad;\ | |||||
done | |||||
# Open terminal | |||||
super + ctrl + space | |||||
kitty | |||||
# vim everywhere | |||||
super + Return | |||||
kitty --name evimwhere nvim '+au BufWritePost * %y+' /dev/null -c 'startinsert';\ | |||||
sleep .5;\ | |||||
xdotool key ctrl+v | |||||
# make sxhkd reload its configuration files: | |||||
super + Escape | |||||
pkill -USR1 -x sxhkd | |||||
# Lock | |||||
super + z | |||||
slimlock | |||||
XF86Display | |||||
arandr | |||||
XF86MonBrightnessUp | |||||
xbacklight +5 | |||||
XF86MonBrightnessDown | |||||
xbacklight -5 | |||||
XF86AudioRaiseVolume | |||||
pactl set-sink-volume 0 +4%;\ | |||||
dunstify -r 1234 "`echo -e "\uf028"` `volume -f '%i'`" | |||||
XF86AudioLowerVolume | |||||
pactl set-sink-volume 0 -4%;\ | |||||
dunstify -r 1234 "`echo -e "\uf027"` `volume -f '%i'`" | |||||
XF86AudioMute | |||||
pactl set-sink-mute 0 toggle;\ | |||||
dunstify -r 1234 "`echo -e "\uf026"` `volume -f '%s' -d hw:1`" | |||||
XF86AudioPlay | |||||
mpc toggle;\ | |||||
dunstify -r 1234 "`echo -e "\uf04b\uf04c"`" | |||||
scrot | |||||
alt + Print | |||||
scrot -s |
@@ -0,0 +1,32 @@ | |||||
map s scroll down | |||||
map d scroll up | |||||
map t scroll left | |||||
map r scroll right | |||||
map S navigate next | |||||
map D navigate previous | |||||
map l rotate rotate-cw | |||||
map v rotate rotate-ccw | |||||
map a adjust_window best-fit | |||||
map u adjust_window width | |||||
map i toggle_page_mode | |||||
map b recolor | |||||
map é recolor-keephue | |||||
map p recolor-reverse-video | |||||
set database sqlite | |||||
set page-cache-size 50 | |||||
set smooth-scroll true | |||||
set window-title-page true | |||||
set scroll-step 20 | |||||
set guioptions "" | |||||
set incremental-search | |||||
set recolor-darkcolor "#93A1A1" | |||||
set recolor-lightcolor "#002B36" | |||||
set recolor | |||||
set recolor-keephue | |||||
set window-title-basename | |||||
set adjust-open "width" |
@@ -0,0 +1,49 @@ | |||||
[gui] | |||||
[user] | |||||
email = maximewack@free.Fr | |||||
name = Maxime Wack | |||||
[core] | |||||
autocrlf = input | |||||
editor = nvim | |||||
[alias] | |||||
co = checkout | |||||
ci = commit | |||||
st = status | |||||
br = branch | |||||
hist = log --pretty=format:'%h %ad | %s%d [%an]' --graph --date=short | |||||
type = cat-file -t | |||||
dump = cat-file -p | |||||
d = difftool | |||||
[push] | |||||
default = current | |||||
[diff] | |||||
tool = nvimdiff | |||||
[merge] | |||||
tool = nvimdiff | |||||
conflictstyle = diff3 | |||||
[difftool] | |||||
prompt = false | |||||
[difftool "nvimdiff"] | |||||
cmd = "nvim -d \"$LOCAL\" \"$REMOTE\"" | |||||
[mergetool "nvimdiff"] | |||||
cmd = "nvim -d \"$BASE\" \"$LOCAL\" \"$REMOTE\" \"$MERGED\"" | |||||
[url "https://aur.archlinux.org/"] | |||||
insteadOf = aur: | |||||
[url "https://maximewack@github.com/"] | |||||
insteadOf = "gh:" | |||||
[url "https://maximewack@github.com/maximewack/"] | |||||
insteadOf = "mw:" | |||||
[url "https://maxx@git.maximewack.com/maxx/"] | |||||
insteadOf = "me:" | |||||
[url "https://maxx@git.maximewack.com/Consults/"] | |||||
insteadOf = "cs:" | |||||
[url "https://maxx@git.maximewack.com/HEGP/"] | |||||
insteadOf = "hegp:" | |||||
[url "https://maxx@git.maximewack.com/Docker/"] | |||||
insteadOf = "docker:" |
@@ -0,0 +1,7 @@ | |||||
file:/// / | |||||
file:///home/maxx/Downloads Downloads | |||||
file:///home/maxx/Projects Projects | |||||
file:///home/maxx/Documents Documents | |||||
file:///home/maxx/Jeux Jeux | |||||
file:///home/maxx/Images Images | |||||
file:///home/maxx/Windows Windows |
@@ -0,0 +1,157 @@ | |||||
#command | |||||
d back-line | |||||
D back-scroll | |||||
s forw-line | |||||
S forw-scroll | |||||
r right-scroll | |||||
t left-scroll | |||||
\r forw-line | |||||
\n forw-line | |||||
e forw-line | |||||
j forw-line | |||||
\kd forw-line | |||||
^E forw-line | |||||
^N forw-line | |||||
k back-line | |||||
y back-line | |||||
^Y back-line | |||||
^K back-line | |||||
^P back-line | |||||
J forw-line-force | |||||
K back-line-force | |||||
Y back-line-force | |||||
^D forw-scroll | |||||
u back-scroll | |||||
^U back-scroll | |||||
\40 forw-screen | |||||
f forw-screen | |||||
^F forw-screen | |||||
^V forw-screen | |||||
\kD forw-screen | |||||
b back-screen | |||||
^B back-screen | |||||
\ev back-screen | |||||
\kU back-screen | |||||
z forw-window | |||||
w back-window | |||||
\e\40 forw-screen-force | |||||
F forw-forever | |||||
\eF forw-until-hilite | |||||
R repaint-flush | |||||
^R repaint | |||||
^L repaint | |||||
\eu undo-hilite | |||||
g goto-line | |||||
\kh goto-line | |||||
< goto-line | |||||
\e< goto-line | |||||
p percent | |||||
% percent | |||||
\e[ left-scroll | |||||
\e] right-scroll | |||||
\e( left-scroll | |||||
\e) right-scroll | |||||
{ forw-bracket {} | |||||
} back-bracket {} | |||||
( forw-bracket () | |||||
) back-bracket () | |||||
[ forw-bracket [] | |||||
] back-bracket [] | |||||
\e^F forw-bracket | |||||
\e^B back-bracket | |||||
G goto-end | |||||
\e> goto-end | |||||
> goto-end | |||||
\ke goto-end | |||||
\eG goto-end-buffered | |||||
= status | |||||
^G status | |||||
:f status | |||||
/ forw-search | |||||
? back-search | |||||
\e/ forw-search * | |||||
\e? back-search * | |||||
n repeat-search | |||||
\en repeat-search-all | |||||
N reverse-search | |||||
\eN reverse-search-all | |||||
& filter | |||||
m set-mark | |||||
' goto-mark | |||||
^X^X goto-mark | |||||
E examine | |||||
:e examine | |||||
^X^V examine | |||||
:n next-file | |||||
:p prev-file | |||||
t next-tag | |||||
T prev-tag | |||||
:x index-file | |||||
:d remove-file | |||||
- toggle-option | |||||
:t toggle-option t | |||||
_ display-option | |||||
| pipe | |||||
v visual | |||||
! shell | |||||
+ firstcmd | |||||
H help | |||||
h help | |||||
V version | |||||
0 digit | |||||
1 digit | |||||
2 digit | |||||
3 digit | |||||
4 digit | |||||
5 digit | |||||
6 digit | |||||
7 digit | |||||
8 digit | |||||
9 digit | |||||
q quit | |||||
Q quit | |||||
:q quit | |||||
:Q quit | |||||
ZZ quit |
@@ -0,0 +1,441 @@ | |||||
# An example configuration file for MPD | |||||
# See the mpd.conf man page for a more detailed description of each parameter. | |||||
# Files and directories ####################################################### | |||||
# | |||||
# This setting controls the top directory which MPD will search to discover the | |||||
# available audio files and add them to the daemon's online database. This | |||||
# setting defaults to the XDG directory, otherwise the music directory will be | |||||
# be disabled and audio files will only be accepted over ipc socket (using | |||||
# file:// protocol) or streaming files over an accepted protocol. | |||||
# | |||||
music_directory "~/Documents/Musique" | |||||
# | |||||
# This setting sets the MPD internal playlist directory. The purpose of this | |||||
# directory is storage for playlists created by MPD. The server will use | |||||
# playlist files not created by the server but only if they are in the MPD | |||||
# format. This setting defaults to playlist saving being disabled. | |||||
# | |||||
playlist_directory "~/.mpd/playlists" | |||||
# | |||||
# This setting sets the location of the MPD database. This file is used to | |||||
# load the database at server start up and store the database while the | |||||
# server is not up. This setting defaults to disabled which will allow | |||||
# MPD to accept files over ipc socket (using file:// protocol) or streaming | |||||
# files over an accepted protocol. | |||||
# | |||||
db_file "~/.mpd/database" | |||||
# | |||||
# These settings are the locations for the daemon log files for the daemon. | |||||
# These logs are great for troubleshooting, depending on your log_level | |||||
# settings. | |||||
# | |||||
# The special value "syslog" makes MPD use the local syslog daemon. This | |||||
# setting defaults to logging to syslog, otherwise logging is disabled. | |||||
# | |||||
log_file "~/.mpd/log" | |||||
# | |||||
# This setting sets the location of the file which stores the process ID | |||||
# for use of mpd --kill and some init scripts. This setting is disabled by | |||||
# default and the pid file will not be stored. | |||||
# | |||||
pid_file "~/.mpd/pid" | |||||
# | |||||
# This setting sets the location of the file which contains information about | |||||
# most variables to get MPD back into the same general shape it was in before | |||||
# it was brought down. This setting is disabled by default and the server | |||||
# state will be reset on server start up. | |||||
# | |||||
state_file "~/.mpd/state" | |||||
# | |||||
# The location of the sticker database. This is a database which | |||||
# manages dynamic information attached to songs. | |||||
# | |||||
sticker_file "~/.mpd/sticker.sql" | |||||
# | |||||
############################################################################### | |||||
# General music daemon options ################################################ | |||||
# | |||||
# This setting specifies the user that MPD will run as. MPD should never run as | |||||
# root and you may use this setting to make MPD change its user ID after | |||||
# initialization. This setting is disabled by default and MPD is run as the | |||||
# current user. | |||||
# | |||||
#user "nobody" | |||||
# | |||||
# This setting specifies the group that MPD will run as. If not specified | |||||
# primary group of user specified with "user" setting will be used (if set). | |||||
# This is useful if MPD needs to be a member of group such as "audio" to | |||||
# have permission to use sound card. | |||||
# | |||||
#group "nogroup" | |||||
# | |||||
# This setting sets the address for the daemon to listen on. Careful attention | |||||
# should be paid if this is assigned to anything other then the default, any. | |||||
# This setting can deny access to control of the daemon. | |||||
# | |||||
# For network | |||||
#bind_to_address "any" | |||||
# | |||||
# And for Unix Socket | |||||
#bind_to_address "~/.mpd/socket" | |||||
# | |||||
# This setting is the TCP port that is desired for the daemon to get assigned | |||||
# to. | |||||
# | |||||
#port "6600" | |||||
# | |||||
# This setting controls the type of information which is logged. Available | |||||
# setting arguments are "default", "secure" or "verbose". The "verbose" setting | |||||
# argument is recommended for troubleshooting, though can quickly stretch | |||||
# available resources on limited hardware storage. | |||||
# | |||||
#log_level "default" | |||||
# | |||||
# Setting "restore_paused" to "yes" puts MPD into pause mode instead | |||||
# of starting playback after startup. | |||||
# | |||||
restore_paused "yes" | |||||
# | |||||
# This setting enables MPD to create playlists in a format usable by other | |||||
# music players. | |||||
# | |||||
#save_absolute_paths_in_playlists "no" | |||||
# | |||||
# This setting defines a list of tag types that will be extracted during the | |||||
# audio file discovery process. The complete list of possible values can be | |||||
# found in the mpd.conf man page. | |||||
#metadata_to_use "artist,album,title,track,name,genre,date,composer,performer,disc" | |||||
# | |||||
# This setting enables automatic update of MPD's database when files in | |||||
# music_directory are changed. | |||||
# | |||||
auto_update "yes" | |||||
# | |||||
# Limit the depth of the directories being watched, 0 means only watch | |||||
# the music directory itself. There is no limit by default. | |||||
# | |||||
#auto_update_depth "3" | |||||
# | |||||
############################################################################### | |||||
# Symbolic link behavior ###################################################### | |||||
# | |||||
# If this setting is set to "yes", MPD will discover audio files by following | |||||
# symbolic links outside of the configured music_directory. | |||||
# | |||||
#follow_outside_symlinks "yes" | |||||
# | |||||
# If this setting is set to "yes", MPD will discover audio files by following | |||||
# symbolic links inside of the configured music_directory. | |||||
# | |||||
#follow_inside_symlinks "yes" | |||||
# | |||||
############################################################################### | |||||
# Zeroconf / Avahi Service Discovery ########################################## | |||||
# | |||||
# If this setting is set to "yes", service information will be published with | |||||
# Zeroconf / Avahi. | |||||
# | |||||
#zeroconf_enabled "yes" | |||||
# | |||||
# The argument to this setting will be the Zeroconf / Avahi unique name for | |||||
# this MPD server on the network. | |||||
# | |||||
#zeroconf_name "Music Player" | |||||
# | |||||
############################################################################### | |||||
# Permissions ################################################################# | |||||
# | |||||
# If this setting is set, MPD will require password authorization. The password | |||||
# can setting can be specified multiple times for different password profiles. | |||||
# | |||||
#password "password@read,add,control,admin" | |||||
# | |||||
# This setting specifies the permissions a user has who has not yet logged in. | |||||
# | |||||
#default_permissions "read,add,control,admin" | |||||
# | |||||
############################################################################### | |||||
# Input ####################################################################### | |||||
# | |||||
input { | |||||
plugin "curl" | |||||
# proxy "proxy.isp.com:8080" | |||||
# proxy_user "user" | |||||
# proxy_password "password" | |||||
} | |||||
# | |||||
############################################################################### | |||||
# Audio Output ################################################################ | |||||
# | |||||
# MPD supports various audio output types, as well as playing through multiple | |||||
# audio outputs at the same time, through multiple audio_output settings | |||||
# blocks. Setting this block is optional, though the server will only attempt | |||||
# autodetection for one sound card. | |||||
# | |||||
# See <http://mpd.wikia.com/wiki/Configuration#Audio_Outputs> for examples of | |||||
# other audio outputs. | |||||
# | |||||
# An example of an ALSA output: | |||||
# | |||||
# audio_output { | |||||
# type "alsa" | |||||
# name "My ALSA Device" | |||||
# options "dev=dmixer" | |||||
# device "plug:dmix" | |||||
#device "hw:0,0" # optional | |||||
# format "44100:16:2" # optional | |||||
#mixer_type "hardware" # optional | |||||
#mixer_device "default" # optional | |||||
#mixer_control "PCM" # optional | |||||
#mixer_index "0" # optional | |||||
# } | |||||
# | |||||
# An example of an OSS output: | |||||
# | |||||
#audio_output { | |||||
# type "oss" | |||||
# name "My OSS Device" | |||||
## device "/dev/dsp" # optional | |||||
## format "44100:16:2" # optional | |||||
## mixer_type "hardware" # optional | |||||
## mixer_device "/dev/mixer" # optional | |||||
## mixer_control "PCM" # optional | |||||
#} | |||||
# | |||||
# An example of a shout output (for streaming to Icecast): | |||||
# | |||||
#audio_output { | |||||
# type "shout" | |||||
# encoding "ogg" # optional | |||||
# name "My Shout Stream" | |||||
# host "localhost" | |||||
# port "8000" | |||||
# mount "/mpd.ogg" | |||||
# password "hackme" | |||||
# quality "5.0" | |||||
# bitrate "128" | |||||
# format "44100:16:1" | |||||
## protocol "icecast2" # optional | |||||
## user "source" # optional | |||||
## description "My Stream Description" # optional | |||||
## url "http://example.com" # optional | |||||
## genre "jazz" # optional | |||||
## public "no" # optional | |||||
## timeout "2" # optional | |||||
## mixer_type "software" # optional | |||||
#} | |||||
# | |||||
# An example of a recorder output: | |||||
# | |||||
#audio_output { | |||||
# type "recorder" | |||||
# name "My recorder" | |||||
# encoder "vorbis" # optional, vorbis or lame | |||||
# path "/var/lib/mpd/recorder/mpd.ogg" | |||||
## quality "5.0" # do not define if bitrate is defined | |||||
# bitrate "128" # do not define if quality is defined | |||||
# format "44100:16:1" | |||||
#} | |||||
# | |||||
# An example of a httpd output (built-in HTTP streaming server): | |||||
# | |||||
# audio_output { | |||||
# type "httpd" | |||||
# name "My HTTP Stream" | |||||
# encoder "lame" # optional, vorbis or lame | |||||
# port "8080" | |||||
# bind_to_address "0.0.0.0" # optional, IPv4 or IPv6 | |||||
# # quality "5.0" # do not define if bitrate is defined | |||||
# bitrate "128" # do not define if quality is defined | |||||
# format "44100:16:1" | |||||
# max_clients "0" # optional 0=no limit | |||||
# } | |||||
# | |||||
# An example of a pulseaudio output (streaming to a remote pulseaudio server) | |||||
# | |||||
audio_output { | |||||
type "pulse" | |||||
name "My Pulse Output" | |||||
## server "remote_server" # optional | |||||
## sink "remote_server_sink" # optional | |||||
} | |||||
# | |||||
## Example "pipe" output: | |||||
# | |||||
#audio_output { | |||||
# type "pipe" | |||||
# name "my pipe" | |||||
# command "aplay -f cd 2>/dev/null" | |||||
## Or if you're want to use AudioCompress | |||||
# command "AudioCompress -m | aplay -f cd 2>/dev/null" | |||||
## Or to send raw PCM stream through PCM: | |||||
# command "nc example.org 8765" | |||||
# format "44100:16:2" | |||||
#} | |||||
# | |||||
## An example of a null output (for no audio output): | |||||
# | |||||
#audio_output { | |||||
# type "null" | |||||
# name "My Null Output" | |||||
# mixer_type "none" # optional | |||||
#} | |||||
# | |||||
# This setting will change all decoded audio to be converted to the specified | |||||
# format before being passed to the audio outputs. By default, this setting is | |||||
# disabled. | |||||
# | |||||
#audio_output_format "44100:16:2" | |||||
# | |||||
# If MPD has been compiled with libsamplerate support, this setting specifies | |||||
# the sample rate converter to use. Possible values can be found in the | |||||
# mpd.conf man page or the libsamplerate documentation. By default, this is | |||||
# setting is disabled. | |||||
# | |||||
#samplerate_converter "Fastest Sinc Interpolator" | |||||
audio_output { | |||||
type "fifo" | |||||
name "my_fifo" | |||||
path "/tmp/mpd.fifo" | |||||
format "44100:16:2" | |||||
} | |||||
# | |||||
############################################################################### | |||||
# Normalization automatic volume adjustments ################################## | |||||
# | |||||
# This setting specifies the type of ReplayGain to use. This setting can have | |||||
# the argument "off", "album" or "track". See <http://www.replaygain.org> | |||||
# for more details. This setting is off by default. | |||||
# | |||||
#replaygain "album" | |||||
# | |||||
# This setting sets the pre-amp used for files that have ReplayGain tags. By | |||||
# default this setting is disabled. | |||||
# | |||||
#replaygain_preamp "0" | |||||
# | |||||
# This setting enables on-the-fly normalization volume adjustment. This will | |||||
# result in the volume of all playing audio to be adjusted so the output has | |||||
# equal "loudness". This setting is disabled by default. | |||||
# | |||||
#volume_normalization "no" | |||||
# | |||||
############################################################################### | |||||
# MPD Internal Buffering ###################################################### | |||||
# | |||||
# This setting adjusts the size of internal decoded audio buffering. Changing | |||||
# this may have undesired effects. Don't change this if you don't know what you | |||||
# are doing. | |||||
# | |||||
#audio_buffer_size "2048" | |||||
# | |||||
# This setting controls the percentage of the buffer which is filled before | |||||
# beginning to play. Increasing this reduces the chance of audio file skipping, | |||||
# at the cost of increased time prior to audio playback. | |||||
# | |||||
#buffer_before_play "10%" | |||||
# | |||||
############################################################################### | |||||
# Resource Limitations ######################################################## | |||||
# | |||||
# These settings are various limitations to prevent MPD from using too many | |||||
# resources. Generally, these settings should be minimized to prevent security | |||||
# risks, depending on the operating resources. | |||||
# | |||||
#connection_timeout "60" | |||||
#max_connections "10" | |||||
#max_playlist_length "16384" | |||||
#max_command_list_size "2048" | |||||
#max_output_buffer_size "8192" | |||||
# | |||||
############################################################################### | |||||
# Client TCP keep alive ####################################################### | |||||
# | |||||
# For clients connected by TCP on supported platforms. | |||||
# Allows detection of dangling connections due to clients disappearing from | |||||
# the network without closing their connections. | |||||
# | |||||
# This is not usually necessary but can be useful in cases such as wifi connectected | |||||
# clients that go in and out of network range or turn off wifi without closing their | |||||
# connections. Combined with low max_connections this can soon cause clients to not | |||||
# be able to connect. | |||||
# | |||||
# | |||||
# Enable tcp keepalive on new client connections (default is "no") | |||||
# | |||||
#tcp_keep_alive "no" | |||||
# | |||||
# Time in seconds since the last communication on the connection and before | |||||
# the keepalive probing is started. (default is 7200 seconds) | |||||
#tcp_keep_alive_idle "7200" | |||||
# | |||||
# Interval in seconds between keepalive probes, once a probe started. | |||||
# (default is 75 seconds) | |||||
#tcp_keep_alive_interval "75" | |||||
# | |||||
# Number of failed probes before the connection is pronounced dead and | |||||
# the connection is closed. (default is 9 times) | |||||
#tcp_keep_alive_count "9" | |||||
# | |||||
############################################################################### | |||||
# Character Encoding ########################################################## | |||||
# | |||||
# If file or directory names do not display correctly for your locale then you | |||||
# may need to modify this setting. | |||||
# | |||||
#filesystem_charset "UTF-8" | |||||
# | |||||
# This setting controls the encoding that ID3v1 tags should be converted from. | |||||
# | |||||
#id3v1_encoding "ISO-8859-1" | |||||
# | |||||
############################################################################### | |||||
# SIDPlay decoder ############################################################# | |||||
# | |||||
# songlength_database: | |||||
# Location of your songlengths file, as distributed with the HVSC. | |||||
# The sidplay plugin checks this for matching MD5 fingerprints. | |||||
# See http://www.c64.org/HVSC/DOCUMENTS/Songlengths.faq | |||||
# | |||||
# default_songlength: | |||||
# This is the default playing time in seconds for songs not in the | |||||
# songlength database, or in case you're not using a database. | |||||
# A value of 0 means play indefinitely. | |||||
# | |||||
# filter: | |||||
# Turns the SID filter emulation on or off. | |||||
# | |||||
#decoder { | |||||
# plugin "sidplay" | |||||
# songlength_database "/media/C64Music/DOCUMENTS/Songlengths.txt" | |||||
# default_songlength "120" | |||||
# filter "true" | |||||
#} | |||||
# | |||||
############################################################################### | |||||
@@ -0,0 +1,516 @@ | |||||
########################################################## | |||||
## this is example bindings configuration file, copy it ## | |||||
## to ~/.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, shift_tab, ctrl_a, ctrl_b, ..., ctrl_z, f1, f2, | |||||
## ..., f12, backspace, backspace_2. | |||||
## | |||||
## - 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: Both 'backspace' and 'backspace_2' are used because some | |||||
## terminals interpret backspace using keycode of 'backspace' | |||||
## and some the one of 'backspace_2'. You can get away with | |||||
## binding once if all your terminal emulators use the same | |||||
## value. | |||||
## | |||||
## 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 | |||||
## - filter_playlist_on_priorities | |||||
## | |||||
# | |||||
#def_key "mouse" | |||||
# mouse_event | |||||
# | |||||
def_key "d" | |||||
scroll_up | |||||
# | |||||
def_key "s" | |||||
scroll_down | |||||
# | |||||
#def_key "[" | |||||
# scroll_up_album | |||||
# | |||||
#def_key "]" | |||||
# scroll_down_album | |||||
# | |||||
#def_key "{" | |||||
# scroll_up_artist | |||||
# | |||||
#def_key "}" | |||||
# scroll_down_artist | |||||
# | |||||
def_key "D" | |||||
page_up | |||||
# | |||||
def_key "S" | |||||
page_down | |||||
# | |||||
#def_key "home" | |||||
# move_home | |||||
# | |||||
#def_key "end" | |||||
# move_end | |||||
# | |||||
#def_key "space" | |||||
# press_space | |||||
# | |||||
#def_key "enter" | |||||
# press_enter | |||||
# | |||||
#def_key "delete" | |||||
# delete_playlist_items | |||||
# | |||||
#def_key "delete" | |||||
# delete_browser_items | |||||
# | |||||
#def_key "delete" | |||||
# delete_stored_playlist | |||||
# | |||||
def_key "r" | |||||
next_column | |||||
# | |||||
#def_key "right" | |||||
# slave_screen | |||||
# | |||||
#def_key "right" | |||||
# volume_up | |||||
# | |||||
#def_key "+" | |||||
# volume_up | |||||
# | |||||
def_key "t" | |||||
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 "backspace_2" | |||||
# jump_to_parent_directory | |||||
# | |||||
#def_key "backspace_2" | |||||
# replay_song | |||||
# | |||||
def_key "l" | |||||
seek_forward | |||||
# | |||||
def_key "v" | |||||
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_space_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_v" | |||||
# sort_playlist | |||||
# | |||||
#def_key "ctrl_r" | |||||
# reverse_playlist | |||||
# | |||||
#def_key "ctrl_f" | |||||
# apply_filter | |||||
# | |||||
#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 "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 "m" | |||||
# toggle_media_library_sort_mode | |||||
# | |||||
#def_key "m" | |||||
# set_visualizer_sample_multiplier | |||||
# | |||||
#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" | |||||
# toggle_fetching_lyrics_in_background | |||||
# | |||||
#def_key "ctrl_l" | |||||
# toggle_screen_lock | |||||
# | |||||
#def_key "`" | |||||
# toggle_browser_sort_mode | |||||
# | |||||
#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 | |||||
# |
@@ -0,0 +1,69 @@ | |||||
# mpd related config | |||||
mpd_music_dir = ~/Documents/Musique/ | |||||
mpd_crossfade_time = "5" | |||||
# visualizer | |||||
visualizer_fifo_path = "/tmp/mpd.fifo" | |||||
visualizer_output_name = "my_fifo" | |||||
visualizer_sync_interval = "15" | |||||
visualizer_in_stereo = "no" | |||||
visualizer_type = "wave" | |||||
visualizer_look = "▮▮" | |||||
# scrolling | |||||
cyclic_scrolling = yes | |||||
mouse_list_scroll_whole_page = no | |||||
lines_scrolled = 1 | |||||
mouse_support = "yes" | |||||
header_text_scrolling = "yes" | |||||
# look | |||||
# Playlist | |||||
song_list_format = "$1$5%n$9$1▕ $1$4%a$9$1 - $1$3%t$1 $1$7(%l)$9 $R$2[%b]$9" | |||||
now_playing_prefix = "$b$1" | |||||
now_playing_suffix = "$/b" | |||||
playlist_display_mode = "classic" (classic/columns) | |||||
autocenter_mode = "yes" | |||||
centered_cursor = "yes" | |||||
# Bars | |||||
song_status_format = "$8%a $1// $8%t $1// $8%b {(Disc %d) }$1// $8%y $1" | |||||
progressbar_look = "─╼─" | |||||
titles_visibility = "no" | |||||
display_bitrate = "no" | |||||
# Browser | |||||
browser_playlist_prefix = "$2plist >$9 " | |||||
browser_display_mode = "classic" (classic/columns) | |||||
# Colors | |||||
discard_colors_if_item_is_selected = "yes" | |||||
header_window_color = "black" | |||||
volume_color = "cyan" | |||||
state_line_color = "black" | |||||
state_flags_color = "yellow" | |||||
main_window_color = "white" | |||||
color1 = "default" | |||||
color2 = "green" | |||||
#main_window_color = "default" | |||||
# main_window_highlight_color = "black" | |||||
current_item_prefix = "$(yellow)$r" | |||||
current_item_suffix = "$/r$(end)" | |||||
progressbar_color = "black" | |||||
statusbar_visibility = "yes" | |||||
header_visibility = "yes" | |||||
statusbar_color = "black" | |||||
# active_column_color = "yellow" | |||||
current_item_inactive_column_prefix = "$(black)$r" | |||||
current_item_inactive_column_suffix = "$/r$(end)" | |||||
visualizer_color = "magenta" | |||||
# Others | |||||
#song_window_title_format = "MPD: {%a > }{%t}{ [%b{ Disc %d}]}|{%f}" | |||||
search_engine_display_mode = "columns" (classic/columns) | |||||
follow_now_playing_lyrics = "no" | |||||
clock_display_seconds = "yes" |
@@ -0,0 +1,12 @@ | |||||
%n - %t | |||||
%n %a - %t | |||||
%n-%a-%t-whinar | |||||
%n-%a-%t | |||||
%a_%t | |||||
%n | |||||
%n %t | |||||
%n_%t | |||||
%t | |||||
%a - %n - %t | |||||
%n-%t | |||||
%n - %a - %t |
@@ -0,0 +1,14 @@ | |||||
#!/bin/zsh | |||||
emulate sh -c 'source /etc/profile' | |||||
export MOZ_USE_OMTC=1 | |||||
export EDITOR="nvim" | |||||
export JAVA_HOME="/usr/lib/jvm/default" | |||||
export TERMCMD="kitty" | |||||
export QT_QPA_PLATFORM_PLUGIN_PATH=/usr/lib/qt/plugins | |||||
export GTK_IM_MODULE=ibus | |||||
export XMODIFIERS=@im=ibus | |||||
export QT_IM_MODULE=ibus | |||||
export THETVDB_API_KEY=49B26BFAFD11B0F3 | |||||
export TR_AUTH=":" | |||||
export PATH=$HOME/.config/bin:/usr/local/bin:$PATH |
@@ -0,0 +1,19 @@ | |||||
#!/bin/zsh | |||||
# | |||||
# ~/.xinitrc | |||||
# | |||||
# Executed by startx (run your window manager from here) | |||||
xrdb -merge ~/.Xresources | |||||
xset -dpms | |||||
xset s off | |||||
if [ "$HOST" = "laptop" ];then | |||||
syndaemon -t -k -i 1 & | |||||
fi | |||||
ibus-daemon -drx | |||||
eval $(ssh-agent) | |||||
exec ./.bspwm-session |
@@ -0,0 +1,99 @@ | |||||
. ~/.profile | |||||
# Path to your oh-my-zsh installation. | |||||
ZSH=/usr/share/oh-my-zsh/ | |||||
# Set name of the theme to load. | |||||
# Look in ~/.oh-my-zsh/themes/ | |||||
# Optionally, if you set this to "random", it'll load a random theme each | |||||
# time that oh-my-zsh is loaded. | |||||
ZSH_THEME="bullet-train" | |||||
# Uncomment the following line to use case-sensitive completion. | |||||
# CASE_SENSITIVE="true" | |||||
# Uncomment the following line to use hyphen-insensitive completion. Case | |||||
# sensitive completion must be off. _ and - will be interchangeable. | |||||
# HYPHEN_INSENSITIVE="true" | |||||
# Uncomment the following line to disable bi-weekly auto-update checks. | |||||
DISABLE_AUTO_UPDATE="true" | |||||
# Uncomment the following line to change how often to auto-update (in days). | |||||
# export UPDATE_ZSH_DAYS=13 | |||||
# Uncomment the following line to disable colors in ls. | |||||
# DISABLE_LS_COLORS="true" | |||||
# Uncomment the following line to disable auto-setting terminal title. | |||||
# DISABLE_AUTO_TITLE="true" | |||||
# Uncomment the following line to enable command auto-correction. | |||||
ENABLE_CORRECTION="true" | |||||
# Uncomment the following line to display red dots whilst waiting for completion. | |||||
#COMPLETION_WAITING_DOTS="true" | |||||
# Uncomment the following line if you want to disable marking untracked files | |||||
# under VCS as dirty. This makes repository status check for large repositories | |||||
# much, much faster. | |||||
# DISABLE_UNTRACKED_FILES_DIRTY="true" | |||||
# Uncomment the following line if you want to change the command execution time | |||||
# stamp shown in the history command output. | |||||
# The optional three formats: "mm/dd/yyyy"|"dd.mm.yyyy"|"yyyy-mm-dd" | |||||
# HIST_STAMPS="mm/dd/yyyy" | |||||
# Would you like to use another custom folder than $ZSH/custom? | |||||
ZSH_CUSTOM=~/.oh-my-zsh | |||||
# Which plugins would you like to load? (plugins can be found in ~/.oh-my-zsh/plugins/*) | |||||
# Custom plugins may be added to ~/.oh-my-zsh/custom/plugins/ | |||||
# Example format: plugins=(rails git textmate ruby lighthouse) | |||||
# Add wisely, as too many plugins slow down shell startup. | |||||
plugins=(git adb archlinux sudo zsh-syntax-highlighting history-substring-search) | |||||
# source ~/.oh-my-zsh/plugins/zsh-autosuggestions/autosuggestions.zsh | |||||
# zle-line-init() { | |||||
# zle autosuggest-start | |||||
# } | |||||
# zle -N zle-line-init | |||||
# User configuration | |||||
# export MANPATH="/usr/local/man:$MANPATH" | |||||
# You may need to manually set your language environment | |||||
# export LANG=en_US.UTF-8 | |||||
# Preferred editor for local and remote sessions | |||||
# if [[ -n $SSH_CONNECTION ]]; then | |||||
# export EDITOR='vim' | |||||
# else | |||||
# export EDITOR='mvim' | |||||
# fi | |||||
# Compilation flags | |||||
# export ARCHFLAGS="-arch x86_64" | |||||
# ssh | |||||
# export SSH_KEY_PATH="~/.ssh/dsa_id" | |||||
# Set personal aliases, overriding those provided by oh-my-zsh libs, | |||||
# plugins, and themes. Aliases can be placed here, though oh-my-zsh | |||||
# users are encouraged to define aliases within the ZSH_CUSTOM folder. | |||||
# For a full list of active aliases, run `alias`. | |||||
# | |||||
# Example aliases | |||||
# alias zshconfig="mate ~/.zshrc" | |||||
# alias ohmyzsh="mate ~/.oh-my-zsh" | |||||
alias q='exit' | |||||
alias tmux='tmux -2' | |||||
alias v=nvim | |||||
alias color='msgcat --color=test' | |||||
ZSH_CACHE_DIR=$HOME/.oh-my-zsh-cache | |||||
if [[ ! -d $ZSH_CACHE_DIR ]]; then | |||||
mkdir $ZSH_CACHE_DIR | |||||
fi | |||||
source $ZSH/oh-my-zsh.sh |
@@ -0,0 +1 @@ | |||||
.config |
@@ -0,0 +1 @@ | |||||
stow --no-folding --ignore=_.* . |