From f6512906cbb6f26f68106adb79cfc44ad0134797 Mon Sep 17 00:00:00 2001 From: natemaia Date: Tue, 1 May 2018 21:57:34 -0700 Subject: [PATCH] Cleanup configs for no DM, fix gksu issues, add addditional configs --- etc/lightdm/pantheon-greeter.conf | 9 ---- home/.Xresources | 26 ++++-------- home/.config/jgmenu/jgmenurc | 2 +- home/.config/ob-autostart/config | 4 +- home/.config/openbox/menu-static.xml | 7 +--- home/.config/openbox/rc.xml | 19 ++++----- home/.vimrc | 61 ++++++++++++++++++++++++++++ home/.xinitrc | 45 ++++++-------------- home/.zprofile | 9 ++++ 9 files changed, 104 insertions(+), 78 deletions(-) delete mode 100644 etc/lightdm/pantheon-greeter.conf create mode 100644 home/.vimrc create mode 100644 home/.zprofile diff --git a/etc/lightdm/pantheon-greeter.conf b/etc/lightdm/pantheon-greeter.conf deleted file mode 100644 index 301e9355..00000000 --- a/etc/lightdm/pantheon-greeter.conf +++ /dev/null @@ -1,9 +0,0 @@ -[greeter] -activate-numlock=false -default-wallpaper=/usr/share/backgrounds/archlabs/archlabs.png -gtk-theme=ArchLabs-Dark -icon-theme=ArchLabs-Light -cursor-theme=ArchLabs-Dark -high-contrast=false -onscreen-keyboard=false -screensaver-timeout=60 diff --git a/home/.Xresources b/home/.Xresources index a18ebea8..b5142f23 100644 --- a/home/.Xresources +++ b/home/.Xresources @@ -1,7 +1,4 @@ -! ------------------------------------------------------------------------------ -! theme colors -! ------------------------------------------------------------------------------ -! special +! Base colors *.foreground: #c0c5ce *.background: #2b303b *.cursorColor: #c0c5ce @@ -24,9 +21,14 @@ *.color14: #96b5b4 *.color15: #F6F6F6 -! ------------------------------------------------------------------------------ +! Rofi +rofi.font: Ubuntu Mono 12 +rofi.color-enabled: true +rofi.color-window: #2b303b, #2b303b, #2b303b +rofi.color-normal: #2b303b, #c0c5ce, #2b303b, #8fa1b3, #2b303b +rofi.separator-style: solid + ! xterm -! ------------------------------------------------------------------------------ xterm*font: Ubuntu Mono xterm*faceName: Ubuntu Mono:size=11:antialias=false xterm*loginShell: true @@ -36,9 +38,7 @@ xterm*charClass: 33:48,35:48,37:48,43:48,45-47:48,64:48,95:48,126:48 xterm*termName: xterm-256color xterm*eightBitInput: false -! ------------------------------------------------------------------------------ ! URxvt -! ----------------------------------------------------------------------------- URxvt*saveline: 15000 URxvt*termName: rxvt-256color URxvt*iso14755: false @@ -65,9 +65,7 @@ URxvt.tabbed.tab-fg: 15 URxvt.tabbed.tab-bg: 4 URxvt*buffered: false -! ------------------------------------------------------------------------------ ! UXTerm -! ------------------------------------------------------------------------------ UXTerm*termName: xterm-256color UXTerm*cursorColor: white UXTerm*VT100.geometry: 90x30 @@ -85,11 +83,3 @@ UXTerm*jumpScroll: true UXTerm*multiScroll: true UXTerm*toolBar: false -! ------------------------------------------------------------------------------ -! Rofi -! ------------------------------------------------------------------------------ -rofi.font: Ubuntu Mono 12 -rofi.color-enabled: true -rofi.color-window: #2b303b, #2b303b, #2b303b -rofi.color-normal: #2b303b, #c0c5ce, #2b303b, #8fa1b3, #2b303b -rofi.separator-style: solid diff --git a/home/.config/jgmenu/jgmenurc b/home/.config/jgmenu/jgmenurc index 50f0ce9c..52c3c61d 100644 --- a/home/.config/jgmenu/jgmenurc +++ b/home/.config/jgmenu/jgmenurc @@ -2,7 +2,7 @@ stay_alive = 1 #hide_on_startup = 0 -csv_cmd = lx +csv_cmd = pmenu tint2_look = 1 at_pointer = 0 terminal_exec = termite diff --git a/home/.config/ob-autostart/config b/home/.config/ob-autostart/config index b59d6f4d..e314240a 100644 --- a/home/.config/ob-autostart/config +++ b/home/.config/ob-autostart/config @@ -1,5 +1,5 @@ # OB_Autostart config LAUNCH_LIST = [ - ("Enable window snapping","opensnap --daemon -c /etc/opensnap","0","*"), - ("Enable skippy-xd window switcher","skippy-xd --config $HOME/.config/skippy-xd/skippy-xd.rc --start-daemon","1","*"), + ("Window snapping","opensnap --daemon -c /etc/opensnap","0","*"), + ("Window switcher","skippy-xd --config $HOME/.config/skippy-xd/skippy-xd.rc --start-daemon","1","*"), ] diff --git a/home/.config/openbox/menu-static.xml b/home/.config/openbox/menu-static.xml index b703db4b..ca48b66e 100644 --- a/home/.config/openbox/menu-static.xml +++ b/home/.config/openbox/menu-static.xml @@ -171,14 +171,9 @@ termite --exec=pacli - - - gksu thunar - - - gksu gparted + gparted diff --git a/home/.config/openbox/rc.xml b/home/.config/openbox/rc.xml index be4ea272..eea5010d 100644 --- a/home/.config/openbox/rc.xml +++ b/home/.config/openbox/rc.xml @@ -159,7 +159,7 @@ - + @@ -176,14 +176,13 @@ - - + - + - + -15 @@ -192,7 +191,7 @@ 47% - + 15 @@ -233,7 +232,7 @@ -15 - + 15 @@ -242,7 +241,7 @@ 32% - + 34% @@ -251,7 +250,7 @@ 32% - + -17 @@ -398,7 +397,7 @@ geany - + xfce4-settings-manager diff --git a/home/.vimrc b/home/.vimrc new file mode 100644 index 00000000..c9c72cb5 --- /dev/null +++ b/home/.vimrc @@ -0,0 +1,61 @@ +" A few sane defaults for use in ArchLabs + +" load Arch Linux defaults +runtime! archlinux.vim + +" system clipboard (requires +clipboard) +set clipboard^=unnamedplus + +" enable line numbers +set number + +" ask confirmation for some things, like save when quiting, etc. +set confirm + +" Tab completion menu when using command mode +set wildmenu + +set expandtab " Tab key inserts spaces not tabs +set softtabstop=4 " spaces to enter for each tab +set shiftwidth=4 " amount of spaces for indentation +set shortmess+=aAcIws " Hide or shorten certain messages + +" enable mouse.. sgr is better but not every term supports it +set mouse=a +if has('mouse_sgr') + set ttymouse=sgr +endif + +" syntax highlighting with true colors in the terminal +syntax enable +if has('termguicolors') && $DISPLAY !=? '' + set termguicolors +endif + +" paste while in insert mode +inoremap :set pastea+:set nopastea + +" changed default mappings +nnoremap 0 ^ +nnoremap Y y$ +nnoremap n nzzzv +nnoremap N Nzzzv +nnoremap ==j + +" gj/k but preserve numbered jumps ie. 12j or 30k +nnoremap j v:count ? 'j' : 'gj' +nnoremap k v:count ? 'k' : 'gk' + +" Reload changes if file changed outside of vim +" requires autoread (enabled by default) +augroup load_changed_file + autocmd! + autocmd FocusGained,BufEnter * if mode() !=? 'c' | checktime | endif + autocmd FileChangedShellPost * echo "Changes loaded from file" +augroup END + +" when quitting, save cursor position +augroup save_cursor_position + autocmd! + autocmd BufReadPost * call setpos(".", getpos("'\"")) +augroup END diff --git a/home/.xinitrc b/home/.xinitrc index b042b43c..24f8ef80 100755 --- a/home/.xinitrc +++ b/home/.xinitrc @@ -3,30 +3,7 @@ # this file is executed when calling startx # To run different WM, run: -# startx ~/.xinitrc SESSION -# eg. startx ~/.xinitrc openbox - -# Commands for autologin with Systemd & Arch -# No editing files or messing about required -#--------------------------------------# -# This copies the default getty service file so we can modify it -# 1. sudo cp /usr/lib/systemd/system/getty@.service /etc/systemd/system/autologin@.service - -# This removes the existing link and creates a link to the file copied above -# 2. sudo rm -f /etc/systemd/system/getty.target.wants/getty@tty1.service && sudo ln -s /etc/systemd/system/autologin@.service /etc/systemd/system/getty.target.wants/getty@tty1.service - -# This command sets your user as the autologin user -# 3. sudo sed -i "/ExecStart/ c ExecStart=-/sbin/agetty -a ${USER} %I \$TERM" /etc/systemd/system/autologin@.service - -# This command will back up existing ~/.zprofile or ~/.bash_profile -# 4. for f in $HOME/.{zprofile,bash_profile}; do if [[ -f $f ]]; then mv $f $HOME/${f}.bak; fi; done - -# This command creates a new ~/.zprofile & ~/.bash_profile.. you can delete the one you don't need -# 5. for x in $HOME/.{zprofile,bash_profile}; do echo -e "# $x\n\nif [[ \$DISPLAY ]] && [[ -n \$XDG_VTNR ]] && [[ \$XDG_VTNR -eq 1 ]]; then\n exec startx\nfi\n" > $x; done - -# Finish up -# 6. Remove Your Current Display Manager and Reboot!! -#--------------------------------------# +# startx ~/.xinitrc WM # Session to run if none given @@ -38,7 +15,6 @@ export WM="$session" # bspwm requires this to be set export XDG_CONFIG_HOME=$HOME/.config - # Default Arch xinit scripts if [ -d /etc/X11/xinit/xinitrc.d ]; then for f in /etc/X11/xinit/xinitrc.d/*.sh; do @@ -63,11 +39,16 @@ if [ -f ~/.xprofile ]; then source ~/.xprofile fi -# keyring for storing passwords -gnome-keyring-daemon --start --components=pkcs11 & -# run policy kit -lxpolkit & +if hash gnome-keyring &>/dev/null; then + # keyring for storing passwords + gnome-keyring-daemon --start --components=pkcs11 & +fi + +if [ -x "/usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1" ]; then + # run policy kit + /usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1 & +fi # keyboard repeat rate kbdrate -d 400 -r 50 @@ -79,9 +60,6 @@ xset s 3600 3600 # Do NOT put code below this case statement case $session in - dwm) - exec dwm - ;; i3|i3wm) exec i3 ;; @@ -94,6 +72,9 @@ case $session in openbox) exec openbox-session ;; + dwm) + exec dwm + ;; *) exec "$1" # Unknown, try running it esac diff --git a/home/.zprofile b/home/.zprofile new file mode 100644 index 00000000..be8db225 --- /dev/null +++ b/home/.zprofile @@ -0,0 +1,9 @@ +# .zprofile +# sourced by zsh when used as a login shell + +# Uncomment below to autologin startx +# also see comments in ~/.xinitrc for more info + +if [[ -z $DISPLAY ]] && [[ -n $XDG_VTNR ]] && [[ $XDG_VTNR -eq 1 ]]; then + exec startx -- vt1 &> /dev/null +fi