Qutebrowser, CUDA, pass & more

crash2
Geoffrey Frogeye 2017-11-26 08:53:39 +01:00
parent 441bd6b9a3
commit f513500c29
8 changed files with 1095 additions and 14 deletions

View File

@ -38,7 +38,7 @@ bindsym button2 kill
bindsym $mod+F2 exec --no-startup-id ~/.config/i3/dmenu_run
bindsym Mod1+F2 exec --no-startup-id ~/.config/i3/dmenu_run
bindsym $mod+c exec --no-startup-id ~/.config/i3/passmenu
bindsym $mod+c exec --no-startup-id ~/.config/i3/passmenu --type
#bindsym $mod+x exec --no-startup-id ~/.config/i3/clipmenu
bindsym $mod+asterisk exec --no-startup-id ~/.config/i3/sshmenu
bindsym $mod+dollar exec --no-startup-id ~/.config/i3/sshmenu root
@ -356,7 +356,6 @@ bindsym $mod+F5 exec --no-startup-id xautolock -enable
# Autostart applications
exec --no-startup-id autorandr --change # Screen configuration and everything that depends on it
exec --no-startup-id /usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1 # Password remembering
exec --no-startup-id gnome-keyring-daemon # Password remembering
exec --no-startup-id numlockx on # Activate Num lock
@ -367,6 +366,7 @@ exec --no-startup-id dunst # Notifications
exec --no-startup-id keynav # Keyboard cursor controller
#exec --no-startup-id $HOME/.config/i3/clipmenud # Clipboard manager
exec --no-startup-id mpd # Music Player Daemon
exec --no-startup-id autorandr --change # Screen configuration and everything that depends on it
set $ignore #ff00000

View File

@ -8,17 +8,23 @@ if [[ $1 == "--type" ]]; then
shift
fi
prefix=${PASSWORD_STORE_DIR-~/.password-store}
password_files=( "$prefix"/**/*.gpg )
password_files=( "${password_files[@]#"$prefix"/}" )
password_files=( "${password_files[@]%.gpg}" )
if PASS=$(which gopass 2> /dev/null); then
password_files="$($PASS ls --flat)"
elif PASS=$(which pass 2> /dev/null); then
prefix=${PASSWORD_STORE_DIR-~/.password-store}
password_files=( "$prefix"/**/*.gpg )
password_files=( "${password_files[@]#"$prefix"/}" )
password_files=( "${password_files[@]%.gpg}" )
else
exit
fi
password=$(printf '%s\n' "${password_files[@]}" | $HOME/.config/i3/dmenu_cmd -p "Passwords" "$@")
[[ -n $password ]] || exit
if [[ $typeit -eq 0 ]]; then
pass show -c "$password" 2>/dev/null
$PASS show -c "$password"
else
xdotool - <<<"type --clearmodifiers -- $(pass show "$password" | head -n 1)"
xdotool - <<<"type --clearmodifiers -- $($PASS show "$password" | head -n 1)"
fi

5
config/i3/test Normal file
View File

@ -0,0 +1,5 @@
prefix=${PASSWORD_STORE_DIR-~/.password-store}
password_files=( "$prefix"/**/*.gpg )
password_files=( "${password_files[@]#"$prefix"/}" )
password_files=( "${password_files[@]%.gpg}" )
echo -e "${password_files[@]}"

View File

@ -76,7 +76,7 @@ enable-ipc = true
inherit = bar/base
modules-center = mpd
modules-right = eth wlan xbacklight volume battery date
modules-right = vpncheck eth wlan bbswitch xbacklight volume battery date
tray-position = right
tray-padding = 2
@ -84,7 +84,7 @@ tray-transparent = false
[bar/secondary]
inherit = bar/base
modules-right = cpu memory temperature ethMore wlanMore filesystem xbacklight volume date
modules-right = cpu memory temperature vpncheck ethMore wlanMore filesystem bbswitch xbacklight volume date
[module/filesystem]
@ -174,6 +174,14 @@ icon-repeatone = 1
toggle-on-foreground = ${theme.foreground}
toggle-off-foreground = #55
[module/bbswitch]
type = custom/script
exec = grep -o '\w\+$' /proc/acpi/bbswitch | sed 's/OFF//' | sed 's/ON//'
exec-if = file /proc/acpi/bbswitch
interval = 5
format-prefix = 
format-foreground = ${theme.redF}
format-prefix-foreground = ${theme.redF}
[module/xbacklight]
type = internal/xbacklight
@ -212,6 +220,13 @@ interval = 2
format-foreground = ${theme.greenF}
label =  %gb_free%
[module/vpncheck]
type = custom/script
exec = echo 
exec-if = pgrep openvpn
interval = 5
format-foreground = ${theme.blueF}
[module/eth]
type = internal/network
interface = ${env:ethI:eth0}

12
scripts/cudarun Executable file
View File

@ -0,0 +1,12 @@
#!/usr/bin/env bash
if [ -z $DISPLAY ]
then
sudo tee /proc/acpi/bbswitch <<< ON
"$@"
rmmod nvidia_uvm
rmmod nvidia
sudo tee /proc/acpi/bbswitch <<< OFF
else
PATH="/opt/cuda/bin:$PATH" LD_LIBRARY_PATH="/opt/cuda/lib64:$LD_LIBRARY_PATH" VBLANK=0 VGL_READBACK=pbo optirun -c yuv "$@"
fi

View File

@ -180,7 +180,7 @@ if [ $TERMUX == 1 ]; then
inst tsu
fi
fi
inst moreutils screen ncdu lsof htop proxytunnel pv curl wget sshfs netcat mosh bash-completion rsync
inst moreutils screen ncdu lsof htop proxytunnel pv curl wget sshfs netcat mosh bash-completion rsync pwgen
if [ $ARCH == 1 ]; then
inst bash-completion
altInst gopass
@ -332,11 +332,11 @@ if [ $EXTRA == 1 ]; then
# Extra GUI
if [ $GUI == 1 ]; then
inst vlc gimp mpd thunar
inst vlc gimp mpd thunar noto-fonts-emoji musescore
if [ $ARCH == 1 ]; then
inst simplescreenrecorder
altInst pacmixer xcursor-menda-git menda-themes-git menda-maia-icon-theme vimpc-git
altInst pacmixer xcursor-menda-git menda-themes-git menda-maia-icon-theme vimpc-git mpc
fi
fi

1043
scripts/package-lock.json generated Normal file

File diff suppressed because it is too large Load Diff

View File

@ -38,7 +38,7 @@ do
if [[ $dry == 0 ]]; then
echo "$src" → "$dst"
else
mv "$src" "$dst"
mv -- "$src" "$dst"
fi
done