From: Amin Bandali Date: Thu, 27 Apr 2017 13:20:32 +0000 (-0400) Subject: New setup X-Git-Url: https://git.shemshak.org/gitweb.cgi/~bandali/configs/commitdiff_plain/855ca24386a69957e9449ba3d53e549cfeb11c87?ds=inline;hp=5ee38ac2b3d22d617605185087c74db0f6a40091 New setup This was sitting uncommitted locally for a while, thought it was time to commit it and push it. --- diff --git a/bspwm/.config/bspwm/bspwmrc b/bspwm/.config/bspwm/bspwmrc index c7ffee5..a992a82 100755 --- a/bspwm/.config/bspwm/bspwmrc +++ b/bspwm/.config/bspwm/bspwmrc @@ -1,22 +1,24 @@ #! /bin/sh sxhkd & -# sleep .25 xfce4-panel -d & connman-gtk & pnmixer & sh ~/.fehbg & +compton & -bspc monitor -d I II III IV V VI VII VIII IX X +bspc monitor eDP-1 -d I II III IV V +bspc monitor HDMI-1 -d VI VII VIII IX X bspc config border_width 2 -bspc config window_gap 10 -#bspc config bottom_padding 32 +bspc config window_gap 12 -# bspc config split_ratio 0.52 +bspc config top_padding 28 + +bspc config split_ratio 0.52 bspc config borderless_monocle true -bspc config click_to_focus true bspc config gapless_monocle true +bspc config click_to_focus true bspc rule -a Firefox desktop='^1' follow=on bspc rule -a Emacs desktop='^2' state=tiled follow=on @@ -27,3 +29,8 @@ bspc rule -a Connman-gtk state=floating bspc rule -a Xfce4-panel state=floating bspc rule -a TelegramDesktop state=floating bspc rule -a Ec state=floating +bspc rule -a Pavucontrol state=floating +bspc rule -a Eog state=floating +bspc rule -a Seahorse state=floating +bspc rule -a mpv state=floating +bspc rule -a Evince state=floating diff --git a/sxhkd/.config/sxhkd/sxhkdrc b/sxhkd/.config/sxhkd/sxhkdrc index 07ab0e0..78dd17d 100644 --- a/sxhkd/.config/sxhkd/sxhkdrc +++ b/sxhkd/.config/sxhkd/sxhkdrc @@ -3,73 +3,65 @@ # # terminal emulator -super + Return - urxvt -super + shift + Return - urxvt -name tiled +super + {_,shift} + Return + urxvt{_, -name tiled} # program launcher super + space - rofi -show run -font "Inconsolata 13" + rofi -show run -# rofi-pass +# window finder +super + backslash + rofi -show window + +# password manager super + shift + space rofi-pass -# teiler -super + shift + s - teiler - -super + z ; t - urxvt - -super + z ; f - firefox-nightly - # firefox #super + r # firefox # chromium #super + c -# chromium +# chromium -incognito # emacs super + e emacs -# emacs -Q -l src/elisp/oremacs/init.el - -# stalonetray -#super + minus -# toggle_tray& -# volume up -XF86AudioRaiseVolume - pamixer --allow-boost --increase 5 +# make sxhkd reload its configuration files: +super + Escape + pkill -USR1 -x sxhkd -# volume down -XF86AudioLowerVolume - pamixer --allow-boost --decrease 5 +# volume {up,down} +XF86Audio{Raise,Lower}Volume + pamixer --allow-boost --{in,de}crease 5 # mute XF86AudioMute pamixer --toggle-mute +# Xfce log out +super + shift + q + xfce4-session-logout + +# Toggle keyboard layout +XF86LaunchA + toggle-layout + +# Toggle Xfce presentation mode +XF86LaunchB + toggle-presentation-mode + # monitor brightness #XF86MonBrightness{Up,Down} -# xbacklight -time 0 {+5,-5} +# light -s mba6x_backlight -{A,U} 10 # keyboard brightness #XF86KbdBrightness{Up,Down} # kbdlight {up,down} -XF86LaunchA - /home/amin/.local/bin/toggle-layout - -# make sxhkd reload its configuration files: -super + Escape - pkill -USR1 -x sxhkd - # # bspwm hotkeys # @@ -118,13 +110,13 @@ super + {_,shift + }{h,j,k,l} super + {p,b,comma,period} bspc node -f @{parent,brother,first,second} -# focus the next/previous node -super + {_,shift + }slash - bspc node -f {next,prev} +# focus the next/previous node in the current desktop +super + {_,shift + }c + bspc node -f {next,prev}.local -# focus the next/previous desktop +# focus the next/previous desktop in the current monitor super + bracket{left,right} - bspc desktop -f {prev,next} + bspc desktop -f {prev,next}.local # send to next/prev desktop super + shift + bracket{left,right} diff --git a/sxhkd/.local/bin/toggle-presentation-mode b/sxhkd/.local/bin/toggle-presentation-mode new file mode 100755 index 0000000..00279bd --- /dev/null +++ b/sxhkd/.local/bin/toggle-presentation-mode @@ -0,0 +1,3 @@ +#!/bin/bash + +xfconf-query -c xfce4-power-manager -p /xfce4-power-manager/presentation-mode -T diff --git a/x/.Xresources b/x/.Xresources index 3dd91e4..5d23a38 100644 --- a/x/.Xresources +++ b/x/.Xresources @@ -1,47 +1,4 @@ -URxvt.scrollBar: false -!URxvt.font: -*-termsyn-medium-*-*-*-14-*-*-*-*-*-*-* -!URxvt.boldFont: -*-termsyn-bold-*-*-*-14-*-*-*-*-*-*-* - -!! Sauce Code Pro -URxvt.font: xft:Source Code Pro-11:hinting=True;antialias:True,xft:Meslo LG M for Powerline-10:medium;antialias=False,xft:DejaVu Sans Mono for Powerline-10:medium;antialias=True,xft:Unifont-10:medium;antialias:True -URxvt.boldFont: xft:Source Code Pro-11:bold;hinting=True;antialias:True,xft:Meslo LG M for Powerline-10:bold;antialias=False,xft:DejaVu Sans Mono for Powerline-10:bold;antialias=True,xft:Unifont-10:bold;antialias:True -URxvt.letterSpace: -1 -!-*-{ Xft settings -Xft*dpi: 96 -Xft*antialias: True -Xft*hinting: Full -!-*-} - -URxvt.depth: 0 -URxvt.loginShell: true -URxvt.saveLines: 1000 -URxvt.internalBorder: 3 -URxvt.lineSpace: 0 -URxvt.scrollStyle: rxvt - -URxvt.perl-ext-common: default,clipboard,url-select,font-size -URxvt.url-select.launcher: firefox -URxvt.url-select.underline: true -URxvt.keysym.M-u: perl:url-select:select_next -URxvt.url-launcher: /usr/bin/firefox -URxvt.matcher.button: 1 -URxvt.iso14755 : false -URxvt.keysym.M-c: perl:clipboard:copy -URxvt.keysym.M-v: perl:clipboard:paste -URxvt.keysym.C-A-V: perl:clipboard:paste_escaped - -URxvt.iconFile: /usr/share/icons/Moka/96x96/apps/utilities-terminal.png -!URxvt.iconFile: /home/amin/.icons/Moka/96x96/apps/utilities-terminal.png - -URxvt.keysym.C-Up: perl:font-size:increase -URxvt.keysym.C-Down: perl:font-size:decrease -!URxvt.keysym.C-S-Up: perl:font-size:incglobal -!URxvt.keysym.C-S-Down: perl:font-size:decglobal -!URxvt.iso14755: false -!URxvt.iso14755_52: false - -! Xcursor -------------------------------------------------------------------- - -!Xcursor.theme: Vanilla-DMZ-AA -!Xcursor.size: 22 - +#include ".Xresources.d/fonts" +#include ".Xresources.d/colors" +#include ".Xresources.d/emacs" +#include ".Xresources.d/rxvt-unicode" diff --git a/x/.Xresources.d/colors b/x/.Xresources.d/colors new file mode 100644 index 0000000..9b1136e --- /dev/null +++ b/x/.Xresources.d/colors @@ -0,0 +1,3 @@ +#include "gruvbox-light.xresources" +! #include "gruvbox-dark.xresources" +#include "gruvbox-urxvt256.xresources" diff --git a/x/.Xresources.d/emacs b/x/.Xresources.d/emacs new file mode 100644 index 0000000..8269961 --- /dev/null +++ b/x/.Xresources.d/emacs @@ -0,0 +1,15 @@ +! Emacs stuff +Emacs.menuBar: off +Emacs.toolBar: off +Emacs.verticalScrollBars: off +Emacs.cursorBlink: off +Emacs.FontBackend: xft,x +Emacs.font: Ubuntu Mono-10.5 +! Emacs.font: Ubuntu Mono-12 +! Emacs.font: Iosevka-11 + +! Emacs.font: Fira Mono:size=15 +! Emacs.font: DejaVu Sans Mono:size=15 +! Emacs.font: Inconsolata:size=17 +! Emacs.font: Source Code Pro-10 +! Emacs.font: Iosevka:size=16 diff --git a/x/.Xresources.d/fonts b/x/.Xresources.d/fonts new file mode 100644 index 0000000..05c96ae --- /dev/null +++ b/x/.Xresources.d/fonts @@ -0,0 +1,7 @@ +Xft.lcdfilter: lcddefault +Xft.antialias: true +Xft.autohint: 0 +Xft.hinting: true +Xft.hintstyle: hintslight +Xft.rgba: rgb +Xft.dpi: 96 \ No newline at end of file diff --git a/x/.Xresources.d/gruvbox-dark.xresources b/x/.Xresources.d/gruvbox-dark.xresources new file mode 100644 index 0000000..5beeba2 --- /dev/null +++ b/x/.Xresources.d/gruvbox-dark.xresources @@ -0,0 +1,36 @@ +! ----------------------------------------------------------------------------- +! File: gruvbox-dark.xresources +! Description: Retro groove colorscheme generalized +! Author: morhetz +! Source: https://github.com/morhetz/gruvbox-generalized +! Last Modified: 6 Sep 2014 +! ----------------------------------------------------------------------------- + +! hard contrast: *background: #1d2021 +*background: #282828 +! soft contrast: *background: #32302f +*foreground: #ebdbb2 +! Black + DarkGrey +*color0: #282828 +*color8: #928374 +! DarkRed + Red +*color1: #cc241d +*color9: #fb4934 +! DarkGreen + Green +*color2: #98971a +*color10: #b8bb26 +! DarkYellow + Yellow +*color3: #d79921 +*color11: #fabd2f +! DarkBlue + Blue +*color4: #458588 +*color12: #83a598 +! DarkMagenta + Magenta +*color5: #b16286 +*color13: #d3869b +! DarkCyan + Cyan +*color6: #689d6a +*color14: #8ec07c +! LightGrey + White +*color7: #a89984 +*color15: #ebdbb2 diff --git a/x/.Xresources.d/gruvbox-light.xresources b/x/.Xresources.d/gruvbox-light.xresources new file mode 100644 index 0000000..738848d --- /dev/null +++ b/x/.Xresources.d/gruvbox-light.xresources @@ -0,0 +1,36 @@ +! ----------------------------------------------------------------------------- +! File: gruvbox-light.xresources +! Description: Retro groove colorscheme generalized +! Author: morhetz +! Source: https://github.com/morhetz/gruvbox-generalized +! Last Modified: 6 Sep 2014 +! ----------------------------------------------------------------------------- + +! hard contrast: *background: #f9f5d7 +*background: #fbf1c7 +! soft contrast: *background: #f2e5bc +*foreground: #3c3836 +! Black + DarkGrey +*color0: #fdf4c1 +*color8: #928374 +! DarkRed + Red +*color1: #cc241d +*color9: #9d0006 +! DarkGreen + Green +*color2: #98971a +*color10: #79740e +! DarkYellow + Yellow +*color3: #d79921 +*color11: #b57614 +! DarkBlue + Blue +*color4: #458588 +*color12: #076678 +! DarkMagenta + Magenta +*color5: #b16286 +*color13: #8f3f71 +! DarkCyan + Cyan +*color6: #689d6a +*color14: #427b58 +! LightGrey + White +*color7: #7c6f64 +*color15: #3c3836 diff --git a/x/.Xresources.d/gruvbox-urxvt256.xresources b/x/.Xresources.d/gruvbox-urxvt256.xresources new file mode 100644 index 0000000..52f58d9 --- /dev/null +++ b/x/.Xresources.d/gruvbox-urxvt256.xresources @@ -0,0 +1,38 @@ +! ----------------------------------------------------------------------------- +! File: gruvbox-urxvt256.xresources +! Description: Retro groove colorscheme generalized +! Author: morhetz +! Source: https://github.com/morhetz/gruvbox-generalized +! Last Modified: 13 Dec 2013 +! ----------------------------------------------------------------------------- + +URxvt.color24: #076678 +URxvt.color66: #427b58 +URxvt.color88: #9d0006 +URxvt.color96: #8f3f71 +URxvt.color100: #79740e +URxvt.color108: #8ec07c +URxvt.color109: #83a598 +URxvt.color130: #af3a03 +URxvt.color136: #b57614 +URxvt.color142: #b8bb26 +URxvt.color167: #fb4934 +URxvt.color175: #d3869b +URxvt.color208: #fe8019 +URxvt.color214: #fabd2f +URxvt.color223: #ebdbb2 +URxvt.color228: #f2e5bc +URxvt.color229: #fbf1c7 +URxvt.color230: #f9f5d7 +URxvt.color234: #1d2021 +URxvt.color235: #282828 +URxvt.color236: #32302f +URxvt.color237: #3c3836 +URxvt.color239: #504945 +URxvt.color241: #665c54 +URxvt.color243: #7c6f64 +URxvt.color244: #928374 +URxvt.color245: #928374 +URxvt.color246: #a89984 +URxvt.color248: #bdae93 +URxvt.color250: #d5c4a1 diff --git a/x/.Xresources.d/rxvt-unicode b/x/.Xresources.d/rxvt-unicode new file mode 100644 index 0000000..eacb397 --- /dev/null +++ b/x/.Xresources.d/rxvt-unicode @@ -0,0 +1,85 @@ +URxvt.xftAntialias: true +URxvt.letterSpace: 0 + +! Fira Mono +! URxvt.font: xft:Fira Mono:pixelsize=15:antialias=true:hinting=true, xft:dejavu sans mono:pixelsize=15:antialias=true:hinting=true +! URxvt.boldFont: xft:Fira Mono:pixelsize=15:antialias=true:hinting=true:bold, xft:dejavu sans mono:pixelsize=15:antialias=true:hinting=true:bold +! URxvt.italicFont: xft:Fira Mono:pixelsize=15:antialias=true:hinting=true:italic, xft:dejavu sans mono:pixelsize=15:antialias=true:hinting=true:italic +! URxvt.bolditalicFont: xft:Fira Mono:pixelsize=15:antialias=true:hinting=true:bold:italic, xft:dejavu sans mono:pixelsize=15:antialias=true:hinting=true:bolditalic + +! Inconsolata +! URxvt.font: xft:inconsolata:pixelsize=14:antialias=true:hinting=true, xft:dejavu sans mono:pixelsize=14:antialias=true:hinting=true +! URxvt.boldFont: xft:inconsolata:pixelsize=14:antialias=true:hinting=true:bold, xft:dejavu sans mono:pixelsize=14:antialias=true:hinting=true:bold +! URxvt.italicFont: xft:inconsolata:pixelsize=14:antialias=true:hinting=true:italic, xft:dejavu sans mono:pixelsize=14:antialias=true:hinting=true:italic +! URxvt.bolditalicFont: xft:inconsolata:pixelsize=14:antialias=true:hinting=true:bold:italic, xft:dejavu sans mono:pixelsize=14:antialias=true:hinting=true:bolditalic + +! Ubuntu Mono +! URxvt.font: xft:ubuntu mono:pixelsize=17:antialias=true:hinting=true, xft:dejavu sans mono:pixelsize=15:antialias=true:hinting=true +! URxvt.boldFont: xft:ubuntu mono:pixelsize=17:antialias=true:hinting=true:bold, xft:dejavu sans mono:pixelsize=15:antialias=true:hinting=true:bold +! URxvt.italicFont: xft:ubuntu mono:pixelsize=17:antialias=true:hinting=true:italic, xft:dejavu sans mono:pixelsize=15:antialias=true:hinting=true:italic +! URxvt.bolditalicFont: xft:ubuntu mono:pixelsize=17:antialias=true:hinting=true:bold:italic, xft:dejavu sans mono:pixelsize=15:antialias=true:hinting=true:bolditalic + +! Ubuntu Mono +URxvt.font: xft:ubuntu mono-10.5:antialias=true:hinting=true, xft:dejavu sans mono:pixelsize=15:antialias=true:hinting=true +URxvt.boldFont: xft:ubuntu mono-10.5:antialias=true:hinting=true:bold, xft:dejavu sans mono:pixelsize=15:antialias=true:hinting=true:bold +URxvt.italicFont: xft:ubuntu mono-10.5:antialias=true:hinting=true:italic, xft:dejavu sans mono:pixelsize=15:antialias=true:hinting=true:italic +URxvt.bolditalicFont: xft:ubuntu mono-10.5:antialias=true:hinting=true:bold:italic, xft:dejavu sans mono:pixelsize=15:antialias=true:hinting=true:bolditalic + +! Iosevka +!URxvt.font: xft:iosevka-11:antialias=true:hinting=true, xft:dejavu sans mono:pixelsize=15:antialias=true:hinting=true +!URxvt.boldFont: xft:iosevka-11:antialias=true:hinting=true:bold, xft:dejavu sans mono:pixelsize=15:antialias=true:hinting=true:bold +!URxvt.italicFont: xft:iosevka-11:antialias=true:hinting=true:italic, xft:dejavu sans mono:pixelsize=15:antialias=true:hinting=true:italic +!URxvt.bolditalicFont: xft:iosevka-11:antialias=true:hinting=true:bold:italic, xft:dejavu sans mono:pixelsize=15:antialias=true:hinting=true:bolditalic + +!URxvt.font: xft:iosevka-12:pixelsize=14:antialias=true:hinting=true, xft:dejavu sans mono:pixelsize=15:antialias=true:hinting=true +!URxvt.boldFont: xft:iosevka-12:pixelsize=14:antialias=true:hinting=true:bold, xft:dejavu sans mono:pixelsize=15:antialias=true:hinting=true:bold +!URxvt.italicFont: xft:iosevka-12:pixelsize=14:antialias=true:hinting=true:italic, xft:dejavu sans mono:pixelsize=15:antialias=true:hinting=true:italic +!URxvt.bolditalicFont: xft:iosevka-12:pixelsize=14:antialias=true:hinting=true:bold:italic, xft:dejavu sans mono:pixelsize=15:antialias=true:hinting=true:bolditalic + +! DejaVu Sans Mono +! URxvt.font: xft:dejavu sans mono:pixelsize=15:antialias=true:hinting=true +! URxvt.boldFont: xft:dejavu sans mono:pixelsize=15:antialias=true:hinting=true:bold +! URxvt.italicFont: xft:dejavu sans mono:pixelsize=15:antialias=true:hinting=true:italic +! URxvt.bolditalicFont: xft:dejavu sans mono:pixelsize=15:antialias=true:hinting=true:bolditalic + +! Source Code Pro +! URxvt.font: xft:source code pro:pixelsize=15:antialias=true:hinting=true, xft:dejavu sans mono:pixelsize=15:antialias=true:hinting=true +! URxvt.boldFont: xft:source code pro:pixelsize=15:antialias=true:hinting=true:bold, xft:dejavu sans mono:pixelsize=15:antialias=true:hinting=true:bold +! URxvt.italicFont: xft:source code pro:pixelsize=15:antialias=true:hinting=true:italic, xft:dejavu sans mono:pixelsize=15:antialias=true:hinting=true:italic +! URxvt.bolditalicFont: xft:source code pro:pixelsize=15:antialias=true:hinting=true:bold:italic, xft:dejavu sans mono:pixelsize=15:antialias=true:hinting=true:bolditalic + +URxvt.depth: 0 +URxvt.loginShell: true +URxvt.saveLines: 100000 +URxvt.internalBorder: 3 +URxvt.lineSpace: 0 +URxvt.scrollBar: false +URxvt.scrollStyle: rxvt +URxvt*scrollTtyOutput: false +URxvt*scrollWithBuffer: true +URxvt*scrollTtyKeypress: true +URxvt.keysym.Shift-Up: command:\033]720;1\007 +URxvt.keysym.Shift-Down: command:\033]721;1\007 + +URxvt.perl-ext-common: default,clipboard,url-select,keyboard-select,font-size +URxvt.url-select.launcher: firefox +URxvt.url-select.underline: true +URxvt.keysym.M-u: perl:url-select:select_next +URxvt.keysym.M-Escape: perl:keyboard-select:activate +URxvt.keysym.M-s: perl:keyboard-select:search +URxvt.url-launcher: /usr/bin/firefox +URxvt.matcher.button: 1 +URxvt.iso14755: false +URxvt.iso14755_53: false +URxvt.keysym.M-c: perl:clipboard:copy +URxvt.keysym.M-v: perl:clipboard:paste +URxvt.keysym.C-A-V: perl:clipboard:paste_escaped +URxvt.keysym.C-Up: font-size:increase +URxvt.keysym.C-Down: font-size:decrease +URxvt.keysym.C-S-Up: font-size:incglobal +URxvt.keysym.C-S-Down: font-size:decglobal +URxvt.keysym.C-equal: font-size:reset +URxvt.keysym.C-question: font-size:show + +! URxvt.iconFile: /usr/share/icons/Moka/96x96/apps/utilities-terminal.png +URxvt.iconFile: /usr/share/icons/elementary-xfce/apps/128/utilities-terminal.svg diff --git a/x/.xprofile b/x/.xprofile old mode 100755 new mode 100644 index 83428bd..3117fc7 --- a/x/.xprofile +++ b/x/.xprofile @@ -1,87 +1,8 @@ -#!/bin/sh -# -# ~/.xinitrc -# -# Executed by startx (run your window manager from here) +setxkbmap -option ctrl:nocaps +#setxkbmap -option compose:ralt -if [ -d /etc/X11/xinit/xinitrc.d ]; then - for f in /etc/X11/xinit/xinitrc.d/*; do - [ -x "$f" ] && . "$f" - done - unset f -fi - -# workaround for some java apps, when running a non-reparenting window manager +source ~/.zprofile export _JAVA_AWT_WM_NONREPARENTING=1 +export _JAVA_OPTIONS='-Dawt.useSystemAAFontSettings=on -Dswing.aatext=true' -xrdb -merge ~/.Xresources -# xrdb -merge ~/.base16-tomorrow.dark.256.xresources -xrdb -merge ~/.gotham.xresources -# xrdb -merge ~/.hybrid.xresources -# xrdb -merge ~/.dawn.xresources -# xrdb -merge ~/.zenburn.xresources -# xrdb -merge ~/.solarized-dark.xresources - -# set the cursor icon -# xsetroot -cursor_name left_ptr & - -# set the wallpaper -# sh ~/.fehbg & - -# font stuff -# xset +fp /usr/share/fonts/local -# xset +fp ~/.fonts -# xset fp rehash -# xset b off - -# the compositor -#compton & - -# xbacklight -set 50 - -# synaptics (touchpad) configs -#synclient TapButton2=3 -#synclient TapButton3=2 -synclient TapButton1=1 -synclient TapButton2=0 -synclient TapButton3=0 -synclient HorizTwoFingerScroll=1 -synclient VertScrollDelta=-237 -synclient HorizScrollDelta=-237 - -# swap caps lock and esc -setxkbmap -option caps:swapescape - -# MPD daemon start (if no other instance exists) -[ -z $(pidof mpd) ] && mpd & - -# screen powersave -# xset +dpms -# xset dpms 0 0 300 - -# lock the screen using lightdm after 5 minutes -# xautolock -time 5 -locker "slimlock" & - -# adjust the keypress delays -xset r rate 200 20 - -# exec gnome-session -# exec startkde -# exec startxfce4 -# ...or the Window Manager of your choice -# source ~/.profile -xfsettingsd & -xfdesktop --disable-wm-check & -xfce4-panel --disable-wm-check & bspwm & -sxhkd & -#emacs --daemon & -sleep 2 && pnmixer & -# panel & - -# DEFAULTSESSION=bspwm -# case "$1" in -# i3) exec i3;; -# bspwm) exec bspwm;; -# *) exec $DEFAULTSESSION ;; -# esac diff --git a/xdg/.config/user-dirs.dirs b/xdg/.config/user-dirs.dirs new file mode 100644 index 0000000..82d4b02 --- /dev/null +++ b/xdg/.config/user-dirs.dirs @@ -0,0 +1,8 @@ +XDG_DESKTOP_DIR="$HOME/Desktop" +XDG_DOCUMENTS_DIR="$HOME/usr/docs" +XDG_DOWNLOAD_DIR="$HOME/usr/dls" +XDG_MUSIC_DIR="$HOME/usr/music" +XDG_PICTURES_DIR="$HOME/usr/img" +XDG_PUBLICSHARE_DIR="$HOME/usr/Public" +XDG_TEMPLATES_DIR="$HOME/usr/Templates" +XDG_VIDEOS_DIR="$HOME/usr/vids" diff --git a/zsh/.zimrc b/zsh/.zimrc new file mode 100644 index 0000000..96eab18 --- /dev/null +++ b/zsh/.zimrc @@ -0,0 +1,94 @@ + + +################# +# CORE SETTINGS # +################# + +# +# Zim settings +# + +# Select what modules you would like enabled. +# The second line of modules may depend on options set by modules in the first line. +# These dependencies are noted on the respective module's README.md. +zmodules=(directory environment git history input ssh utility meta custom \ + prompt syntax-highlighting history-substring-search completion) + + +################### +# MODULE SETTINGS # +################### + +# +# Prompt +# + +# Set your desired prompt here +zprompt_theme='pure' +PURE_PROMPT_SYMBOL=λ + +# +# Completion +# + +# set an optional host-specific filename for the completion cache file +# if none is provided, the default '.zcompdump' is used. +#zcompdump_file=".zcompdump-${HOST}-${ZSH_VERSION}" + +# +# Utility +# + +# Uncomment to enable command correction prompts +# See: http://zsh.sourceforge.net/Doc/Release/Options.html#Input_002fOutput +setopt CORRECT + +# +# Environment +# + +# Set the string below to the desired terminal title format string. +# The terminal title is redrawn upon directory change, however, variables like +# ${PWD} are only evaluated once. Use prompt expansion strings for dynamic data: +# http://zsh.sourceforge.net/Doc/Release/Prompt-Expansion.html#Simple-Prompt-Escapes +# The example below uses the following format: 'username@host:/current/directory' +ztermtitle='%n@%m:%~' + +# +# Input +# + +# Uncomment to enable double-dot expansion. +# This appends '../' to your input for each '.' you type after an initial '..' +#zdouble_dot_expand='true' + +# +# Syntax-Highlighting +# + +# This determines what highlighters will be used with the syntax-highlighting module. +# Documentation of the highlighters can be found here: +# https://github.com/zsh-users/zsh-syntax-highlighting/blob/master/docs/highlighters.md +# For (u)rxvt, termite and gnome-terminal users, +# removing the 'cursor' highlighter will fix the disappearing cursor problem +#zhighlighters=(main brackets cursor) +zhighlighters=(main brackets pattern) + + +# +# SSH +# + +# Load these ssh identities with the ssh module +zssh_ids=(id_rsa plasma_id_rsa id_ed25519 id_rsa_aur) + + +# +# Pacman +# + +# Set (optional) pacman front-end. +zpacman_frontend='pacaur' + +# Load any helper scripts as defined here +#zpacman_helper=(aur) diff --git a/zsh/.zlogin b/zsh/.zlogin new file mode 100644 index 0000000..d8b5b0a --- /dev/null +++ b/zsh/.zlogin @@ -0,0 +1,59 @@ + + +# +# startup file read in interactive login shells +# +# The following code helps us by optimizing the existing framework. +# This includes zcompile, zcompdump, etc. +# + +( + # Function to determine the need of a zcompile. If the .zwc file + # does not exist, or the base file is newer, we need to compile. + # These jobs are asynchronous, and will not impact the interactive shell + zcompare() { + if [[ -s ${1} && ( ! -s ${1}.zwc || ${1} -nt ${1}.zwc) ]]; then + zcompile ${1} + fi + } + + zim_mods=${ZDOTDIR:-${HOME}}/.zim/modules + setopt EXTENDED_GLOB + + # zcompile the completion cache; siginificant speedup. + for file in ${ZDOTDIR:-${HOME}}/.zcomp^(*.zwc)(.); do + zcompare ${file} + done + + # zcompile .zshrc + zcompare ${ZDOTDIR:-${HOME}}/.zshrc + + # zcompile some light module init scripts + zcompare ${zim_mods}/git/init.zsh + zcompare ${zim_mods}/utility/init.zsh + zcompare ${zim_mods}/pacman/init.zsh + zcompare ${zim_mods}/spectrum/init.zsh + zcompare ${zim_mods}/completion/init.zsh + zcompare ${zim_mods}/fasd/init.zsh + + # zcompile all .zsh files in the custom module + for file in ${zim_mods}/custom/**/^(README.md|*.zwc)(.); do + zcompare ${file} + done + + # zcompile all autoloaded functions + for file in ${zim_mods}/**/functions/^(*.zwc)(.); do + zcompare ${file} + done + + # syntax-highlighting + for file in ${zim_mods}/syntax-highlighting/external/highlighters/**/*.zsh; do + zcompare ${file} + done + zcompare ${zim_mods}/syntax-highlighting/external/zsh-syntax-highlighting.zsh + + # zsh-histery-substring-search + zcompare ${zim_mods}/history-substring-search/external/zsh-history-substring-search.zsh + + +) &! \ No newline at end of file diff --git a/zsh/.zprofile b/zsh/.zprofile new file mode 100644 index 0000000..656d599 --- /dev/null +++ b/zsh/.zprofile @@ -0,0 +1,8 @@ +export PATH=$HOME/.local/bin:$HOME/.cabal/bin:$HOME/.cargo/bin:$PATH +export XDG_CONFIG_HOME=$HOME/.config +export XDG_DATA_HOME=$HOME/.local/share +export XDG_DATA_DIRS=/usr/local/share:/usr/share +export MAILDIR="$HOME/mail" +export CVS_RSH=ssh +export MATHMODELS=$HOME/src/eiffel/mathmodels +export RUST_SRC_PATH=~/.multirust/toolchains/stable-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/src diff --git a/zsh/.zshenv b/zsh/.zshenv new file mode 100644 index 0000000..c23f284 --- /dev/null +++ b/zsh/.zshenv @@ -0,0 +1,4 @@ +# Ensure that a non-login, non-interactive shell has a defined environment. +if [[ "$SHLVL" -eq 1 && ! -o LOGIN && -s "${ZDOTDIR:-$HOME}/.zprofile" ]]; then + source "${ZDOTDIR:-$HOME}/.zprofile" +fi diff --git a/zsh/.zshrc b/zsh/.zshrc new file mode 100644 index 0000000..635bffb --- /dev/null +++ b/zsh/.zshrc @@ -0,0 +1,26 @@ +# Bash-like navigation +#export WORDCHARS='*?_-.[]~=&;!#$%^(){}<>' +export WORDCHARS='*?[]~=&;!#$%^(){}<>' + +fpath+=~/.zfunc + +# rehash if last command was pacaur or pacman +# (so that zsh picks up changes in $PATH immediately) +TRAPUSR1() { rehash}; precmd() { [[ $history[$[ HISTCMD -1 ]] == *(pacaur|pacman)* ]] && killall -USR1 zsh } + + + +# +# User configuration sourced by interactive shells +# + +# Source zim +if [[ -s ${ZDOTDIR:-${HOME}}/.zim/init.zsh ]]; then + source ${ZDOTDIR:-${HOME}}/.zim/init.zsh +fi + + +ZSH_HIGHLIGHT_PATTERNS+=('rm -rf *' 'fg=white,bold,bg=red') +#ZSH_HIGHLIGHT_STYLES[unknown-token]='fg=red,bold' + +source ~/.zsh/zsh-autosuggestions/zsh-autosuggestions.zsh