Compare commits

..

No commits in common. "8cbf1c2b69df72ca893c6cb90f750d4e3b3d30f0" and "ad0a6beb92275683755c27059c7d6dca8815f7a6" have entirely different histories.

8 changed files with 34 additions and 24 deletions

View File

@ -26,7 +26,7 @@ URxvt*saveLines: 65500
URxvt*loginShell: false
!URxvt*termName: screen-256color
{{- if (or (eq .chezmoi.hostname "jnielandt") (eq .chezmoi.hostname "zaptorjezus")) }}
{{- if eq .chezmoi.hostname "zaptorjezus" }}
URxvt.font: xft:Fura Code Nerd Font Mono:size=10:antialias=true
URxvt.boldfont: xft:Fura Code Nerd Font Mono:bold:size=10
{{- else }}

View File

@ -103,7 +103,7 @@ bottom = false
;border-right-size = 16
;unused modules - mpd xbacklight backlight-acpi alsa
modules-left = i3
modules-center = temperature battery xkeyboard memory cpu filesystem updates-aurhelper reboot-check xbacklight top-process
modules-center = temperature battery xkeyboard memory cpu filesystem updates-arch reboot-check xbacklight top-process
modules-right = net wifi0 vpn powermenu
; TRAY MANAGEMENT
@ -390,10 +390,15 @@ type = custom/script
exec = ~/.dotfiles/polybar/polybar-scripts/polybar-scripts/updates-pacman/updates-pacman.sh
interval = 600
[module/updates-aurhelper]
; this one was fased out, DEPRECATED
[module/updates-arch]
type = custom/script
exec = ~/.dotfiles/polybar/polybar-scripts/polybar-scripts/updates-aurhelper/updates-aurhelper.sh
exec = ~/.config/polybar/polybar-scripts/polybar-scripts/updates-arch/updates-arch.sh
format-prefix = "ﮮ "
format-prefix-foreground = ${colors.bright_green}
;format-underline = ${colors.light3}
interval = 600
label = "%output%"
[module/reboot-check]
type = custom/script

4
dot_dotfiles/rofi/config Normal file
View File

@ -0,0 +1,4 @@
rofi.combi-modi: window,drun,ssh
rofi.font: Fura Code 12
rofi.modi: combi
rofi.theme: ~/.config/rofi/gruvbox-dark-mod.rasi

View File

@ -1,6 +0,0 @@
configuration {
combi-modi: "window,drun,ssh";
font: "Fura Code 12";
modi: "run,combi";
theme: "gruvbox-dark-mod.rasi";
}

View File

@ -145,7 +145,7 @@ __fzf_generic_path_completion() {
leftover=${leftover/#\/}
[ -z "$dir" ] && dir='.'
[ "$dir" != "/" ] && dir="${dir/%\//}"
matches=$(eval "$compgen $(printf %q "$dir")" | FZF_DEFAULT_OPTS="--height ${FZF_TMUX_HEIGHT:-40%} --reverse --bind=ctrl-z:ignore $FZF_DEFAULT_OPTS $FZF_COMPLETION_OPTS" __fzf_comprun "$cmd" ${(Q)${(Z+n+)fzf_opts}} -q "$leftover" | while read item; do
matches=$(eval "$compgen $(printf %q "$dir")" | FZF_DEFAULT_OPTS="--height ${FZF_TMUX_HEIGHT:-40%} --reverse $FZF_DEFAULT_OPTS $FZF_COMPLETION_OPTS" __fzf_comprun "$cmd" ${(Q)${(Z+n+)fzf_opts}} -q "$leftover" | while read item; do
echo -n "${(q)item}$suffix "
done)
matches=${matches% }
@ -207,10 +207,11 @@ _fzf_complete() {
type $post > /dev/null 2>&1 || post=cat
_fzf_feed_fifo "$fifo"
matches=$(FZF_DEFAULT_OPTS="--height ${FZF_TMUX_HEIGHT:-40%} --reverse --bind=ctrl-z:ignore $FZF_DEFAULT_OPTS $FZF_COMPLETION_OPTS $str_arg" __fzf_comprun "$cmd" "${args[@]}" -q "${(Q)prefix}" < "$fifo" | $post | tr '\n' ' ')
matches=$(FZF_DEFAULT_OPTS="--height ${FZF_TMUX_HEIGHT:-40%} --reverse $FZF_DEFAULT_OPTS $FZF_COMPLETION_OPTS $str_arg" __fzf_comprun "$cmd" "${args[@]}" -q "${(Q)prefix}" < "$fifo" | $post | tr '\n' ' ')
if [ -n "$matches" ]; then
LBUFFER="$lbuf$matches"
fi
zle reset-prompt
command rm -f "$fifo"
}
@ -224,7 +225,7 @@ _fzf_complete_telnet() {
_fzf_complete_ssh() {
_fzf_complete +m -- "$@" < <(
setopt localoptions nonomatch
command cat <(command tail -n +1 ~/.ssh/config ~/.ssh/config.d/* /etc/ssh/ssh_config 2> /dev/null | command grep -i '^\s*host\(name\)\? ' | awk '{for (i = 2; i <= NF; i++) print $1 " " $i}' | command grep -v '[*?]') \
command cat <(cat ~/.ssh/config ~/.ssh/config.d/* /etc/ssh/ssh_config 2> /dev/null | command grep -i '^\s*host\(name\)\? ' | awk '{for (i = 2; i <= NF; i++) print $1 " " $i}' | command grep -v '[*?]') \
<(command grep -oE '^[[a-z0-9.,:-]+' ~/.ssh/known_hosts | tr ',' '\n' | tr -d '[' | awk '{ print $1 " " $1 }') \
<(command grep -v '^\s*\(#\|$\)' /etc/hosts | command grep -Fv '0.0.0.0') |
awk '{if (length($2) > 0) {print $2}}' | sort -u
@ -301,7 +302,6 @@ fzf-completion() {
if eval "type _fzf_complete_${cmd} > /dev/null"; then
prefix="$prefix" eval _fzf_complete_${cmd} ${(q)lbuf}
zle reset-prompt
elif [ ${d_cmds[(i)$cmd]} -le ${#d_cmds} ]; then
_fzf_dir_completion "$prefix" "$lbuf"
else

View File

@ -45,8 +45,7 @@ __fsel() {
-o -type d -print \
-o -type l -print 2> /dev/null | cut -b3-"}"
setopt localoptions pipefail no_aliases 2> /dev/null
local item
eval "$cmd" | FZF_DEFAULT_OPTS="--height ${FZF_TMUX_HEIGHT:-40%} --reverse --bind=ctrl-z:ignore $FZF_DEFAULT_OPTS $FZF_CTRL_T_OPTS" $(__fzfcmd) -m "$@" | while read item; do
eval "$cmd" | FZF_DEFAULT_OPTS="--height ${FZF_TMUX_HEIGHT:-40%} --reverse $FZF_DEFAULT_OPTS $FZF_CTRL_T_OPTS" $(__fzfcmd) -m "$@" | while read item; do
echo -n "${(q)item} "
done
local ret=$?
@ -68,22 +67,30 @@ fzf-file-widget() {
zle -N fzf-file-widget
bindkey '^T' fzf-file-widget
# Ensure precmds are run after cd
fzf-redraw-prompt() {
local precmd
for precmd in $precmd_functions; do
$precmd
done
zle reset-prompt
}
zle -N fzf-redraw-prompt
# ALT-C - cd into the selected directory
fzf-cd-widget() {
local cmd="${FZF_ALT_C_COMMAND:-"command find -L . -mindepth 1 \\( -path '*/\\.*' -o -fstype 'sysfs' -o -fstype 'devfs' -o -fstype 'devtmpfs' -o -fstype 'proc' \\) -prune \
-o -type d -print 2> /dev/null | cut -b3-"}"
setopt localoptions pipefail no_aliases 2> /dev/null
local dir="$(eval "$cmd" | FZF_DEFAULT_OPTS="--height ${FZF_TMUX_HEIGHT:-40%} --reverse --bind=ctrl-z:ignore $FZF_DEFAULT_OPTS $FZF_ALT_C_OPTS" $(__fzfcmd) +m)"
local dir="$(eval "$cmd" | FZF_DEFAULT_OPTS="--height ${FZF_TMUX_HEIGHT:-40%} --reverse $FZF_DEFAULT_OPTS $FZF_ALT_C_OPTS" $(__fzfcmd) +m)"
if [[ -z "$dir" ]]; then
zle redisplay
return 0
fi
zle push-line # Clear buffer. Auto-restored on next prompt.
BUFFER="cd ${(q)dir}"
zle accept-line
local ret=$?
cd "$dir"
unset dir # ensure this doesn't end up appearing in prompt expansion
zle reset-prompt
local ret=$?
zle fzf-redraw-prompt
return $ret
}
zle -N fzf-cd-widget
@ -93,8 +100,8 @@ bindkey '\ec' fzf-cd-widget
fzf-history-widget() {
local selected num
setopt localoptions noglobsubst noposixbuiltins pipefail no_aliases 2> /dev/null
selected=( $(fc -rl 1 | perl -ne 'print if !$seen{(/^\s*[0-9]+\**\s+(.*)/, $1)}++' |
FZF_DEFAULT_OPTS="--height ${FZF_TMUX_HEIGHT:-40%} $FZF_DEFAULT_OPTS -n2..,.. --tiebreak=index --bind=ctrl-r:toggle-sort,ctrl-z:ignore $FZF_CTRL_R_OPTS --query=${(qqq)LBUFFER} +m" $(__fzfcmd)) )
selected=( $(fc -rl 1 | perl -ne 'print if !$seen{(/^\s*[0-9]+\s+(.*)/, $1)}++' |
FZF_DEFAULT_OPTS="--height ${FZF_TMUX_HEIGHT:-40%} $FZF_DEFAULT_OPTS -n2..,.. --tiebreak=index --bind=ctrl-r:toggle-sort $FZF_CTRL_R_OPTS --query=${(qqq)LBUFFER} +m" $(__fzfcmd)) )
local ret=$?
if [ -n "$selected" ]; then
num=$selected[1]