aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--bash_aliases4
-rw-r--r--bashrc2
-rw-r--r--config/sxhkd/sxhkdrc11
-rwxr-xr-xmutt/notify.sh4
-rw-r--r--muttrc2
-rwxr-xr-xtools/panel/panel10
-rwxr-xr-xtools/panel/panel_bar71
-rwxr-xr-x[-rw-r--r--]tools/panel/profile7
-rwxr-xr-xxinitrc2
-rw-r--r--zshrc2
10 files changed, 87 insertions, 28 deletions
diff --git a/bash_aliases b/bash_aliases
index a92723d..f3330f4 100644
--- a/bash_aliases
+++ b/bash_aliases
@@ -8,7 +8,7 @@
alias sdr='gqrx-alsa'
# Disable mouse
alias remouse='sudo modprobe -r bcm5974'
-alias enmouse='sudo modprobe bcm5974'
+alias enmouse='sudo modprobe bcm5974 & ~/bin/mousefix'
# Notes
alias physics='vim ~/Sync/Notes/Physics/physics.txt'
@@ -77,7 +77,7 @@ alias aria2c='aria2c -c -x5 -s10 -m0'
alias msfconsole="msfconsole --quiet -x \"db_connect ${USER}@msf\""
# Screen
-alias scradmin='$HOME/.ratpoison/screen_run admin'
+alias scradmin='$HOME/.tools/screen_run admin'
alias scrschool='$HOME/.ratpoison/screen_run school'
diff --git a/bashrc b/bashrc
index d78accc..fed088c 100644
--- a/bashrc
+++ b/bashrc
@@ -118,6 +118,6 @@ shopt -s cdspell
export GPGKEY="B54608CC"
export PATH="$HOME/bin:$HOME/bin/perl6:$PATH"
-export EDITOR="nvim"
+export EDITOR="vim"
export PENTADACTYL_RUNTIME="$HOME/.pentadactyl"
export LD_LIBRARY_PATH=/usr/local/lib
diff --git a/config/sxhkd/sxhkdrc b/config/sxhkd/sxhkdrc
index 7e592a4..e3a7464 100644
--- a/config/sxhkd/sxhkdrc
+++ b/config/sxhkd/sxhkdrc
@@ -85,12 +85,15 @@ grave ; {1-9}
grave ; ctrl + {1-9}
bspc window -r 0.{1-9}
-{_,alt + }{F1,F2,F3,F4,F5,F6,F7,F8,F9,F11,F12}
- bspc {desktop -f,window -d} ^{1-9,11,12}
+{_,alt + }{F1,F2,F3,F4,F5,F6,F7,F8,F11,F12}
+ bspc {desktop -f,window -d} ^{1-8,11,12}
+
+{_,alt + } F9
+ bspc {desktop -f,window -d} ^9 & echo 'Ixlear' > /tmp/panel-fifo
-{_,alt + } F10
- bspc {desktop -f,window -d} ^10 && xset -led named "Scroll Lock"
+{_,alt + } F10
+ bspc {desktop -f,window -d} ^10 & xset -led named "Scroll Lock" & echo 'Iclear' > /tmp/panel-fifo
{_,alt + } shift + F12
bspc {desktop -f,window -d} ^13
diff --git a/mutt/notify.sh b/mutt/notify.sh
index 4dbc0f6..a628c52 100755
--- a/mutt/notify.sh
+++ b/mutt/notify.sh
@@ -14,9 +14,9 @@
echo "$1"
echo "$1" | grep -q "New" > /dev/null 2>&1
+status=$?
-if [ $? -eq 0 ];
-then
+if [ $status -eq 0 ];then
xset led 1
touch ~/.mutt/newmail
else
diff --git a/muttrc b/muttrc
index 3b82f72..74cbf87 100644
--- a/muttrc
+++ b/muttrc
@@ -16,7 +16,7 @@ set mbox = "+dove/Archive"
set postponed = "+dove/Drafts"
set record = "+dove/Sent"
-mailboxes +INBOX
+mailboxes +Inbox
# View good/bad mails
diff --git a/tools/panel/panel b/tools/panel/panel
index a9e5567..472b180 100755
--- a/tools/panel/panel
+++ b/tools/panel/panel
@@ -4,23 +4,25 @@ source ./profile
source ~/.colors
[ -e "$PANEL_FIFO" ] && rm "$PANEL_FIFO"
-mkfifo "$PANEL_FIFO"
+mkfifo -m 777 "$PANEL_FIFO"
+
bspc config top_padding $PANEL_HEIGHT
bspc control --subscribe > "$PANEL_FIFO" &
xtitle -sf 'T%s' > "$PANEL_FIFO" &
volume -f 'V%i' > "$PANEL_FIFO" &
-battery -i 60 -sf 'B%i' > "$PANEL_FIFO" &
+battery -i 60 -sf 'B%s %i' > "$PANEL_FIFO" &
clock -i 60 -sf 'Z%d %a %H:%M' > "$PANEL_FIFO" &
./music > "$PANEL_FIFO" &
#./load > "$PANEL_FIFO" &
#essid -sf 'E%s' -i 30 -w wlp2s0 > "$PANEL_FIFO" &
# ./signal > "$PANEL_FIFO" &
+unbuffer alsactl monitor | grep --line-buffered 'Headphone Jack' | while read line; do volume -f 'V%i' > $PANEL_FIFO;done &
source ./panel_colors
-cat "$PANEL_FIFO" | ./panel_bar | lemonbar -g x$PANEL_HEIGHT -f "$PANEL_FONT_FAMILY" -F "$COLOR_FOREGROUND" -B "$COLOR_BACKGROUND" &
+cat "$PANEL_FIFO" | ./panel_bar | lemonbar -f "$FONT_FONT" -f "$ICON_FONT" -g x$PANEL_HEIGHT -F "$COLOR_FOREGROUND" -B "$COLOR_BACKGROUND" &
sleep 1;
-stalonetray --geometry 4x1-1+1 --icon-gravity E --grow-gravity E -bg $COLOR0 -i 18 &
+stalonetray --geometry 1x1-415+2 --icon-gravity E --grow-gravity E -bg $COLOR0 -i 18 &
diff --git a/tools/panel/panel_bar b/tools/panel/panel_bar
index 0b2e55e..779c5bb 100755
--- a/tools/panel/panel_bar
+++ b/tools/panel/panel_bar
@@ -6,14 +6,55 @@
num_mon=$(bspc query -M | wc -l)
source ./panel_colors
+source ./icons
while read -r line ; do
case $line in
- C*)
- cpu="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} C:${line#?} %{B-}%{F-}"
+ Imail)
+ mbsync -a > /dev/null
+ if bspc control --get-status | grep OIX > /dev/null;then
+ mail=''
+ else
+ mail="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} ${ICON_MAIL} %{B-}%{F-}"
+ fi
;;
- R*)
- ram="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} R:${line#?} %{B-}%{F-}"
+
+ Iface)
+ if bspc control --get-status | grep OX > /dev/null;then
+ face=''
+ else
+ face="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} ${ICON_FACE} %{B-}%{F-}"
+ fi
+ ;;
+
+ Ipub)
+ if bspc control --get-status | grep OX > /dev/null;then
+ pub=''
+ else
+ pub="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} ${ICON_PUB} %{B-}%{F-}"
+ fi
+ ;;
+
+ Ipriv)
+ if bspc control --get-status | grep OX > /dev/null;then
+ priv=''
+ else
+ priv="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} ${ICON_PRIV} %{B-}%{F-}"
+ fi
+ ;;
+ Iclear)
+ priv=""
+ pub=""
+ face=""
;;
+ Ixlear)
+ mail=''
+ ;;
+# C*)
+# cpu="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} C:${line#?} %{B-}%{F-}"
+# ;;
+# R*)
+# ram="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} R:${line#?} %{B-}%{F-}"
+# ;;
# S*)
# signal="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} S:${line#?} %{B-}%{F-}"
@@ -22,29 +63,39 @@ while read -r line ; do
p*)
# playing mpc
paused=''
- playing="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} p:${line#?} %{B-}%{F-}"
+ playing="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} ${ICON_PLAY} ${line#?} %{B-}%{F-}"
;;
P*)
# paused mpc
playing=''
- paused="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} P:${line#?} %{B-}%{F-}"
+ paused="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} ${ICON_PAUSE} ${line#?} %{B-}%{F-}"
;;
K*)
# volume output
- musicvol="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} M:${line#?} %{B-}%{F-}"
+ musicvol="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} ${ICON_MUSIC} ${line#?} %{B-}%{F-}"
;;
B*)
# battery output
- battery="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} B:${line#?} %{B-}%{F-}"
+ if [[ ${line#?} =~ Discharging ]];then
+ percent=`echo ${line#?} | cut -d' ' -f2`
+ battery="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} ${ICON_PWR} ${percent} %{B-}%{F-}";
+ else
+ percent=`echo ${line#?} | cut -d' ' -f2`
+ battery="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} ${ICON_PLUG} ${percent} %{B-}%{F-}";
+ fi
;;
V*)
# volume output
- volume="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} V:${line#?} %{B-}%{F-}"
+ if amixer contents | head -12 | tail -1 | grep on > /dev/null;then
+ volume="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} ${ICON_HPHONES} ${line#?} %{B-}%{F-}"
+ else
+ volume="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} ${ICON_VOLUME_UP} ${line#?} %{B-}%{F-}";
+ fi
;;
E*)
@@ -119,5 +170,5 @@ while read -r line ; do
;;
esac
# printf "%s\n" "%{l}${wm_infos}${title}%{r}${playing}${paused}${cpu}${ram}${essid}${signal}${volume}${musicvol}${battery}${time_infos} "
- printf "%s\n" "%{l}${wm_infos}${title}%{r}${playing}${paused}${cpu}${ram}${volume}${musicvol}${battery}${time_infos} "
+ printf "%s\n" "%{l}${wm_infos}${title}%{r}${face}${priv}${pub}${mail}${playing}${paused}${cpu}${ram}${volume}${musicvol}${battery}${time_infos}"
done
diff --git a/tools/panel/profile b/tools/panel/profile
index c7a3ba0..c8b6807 100644..100755
--- a/tools/panel/profile
+++ b/tools/panel/profile
@@ -1,4 +1,7 @@
PANEL_FIFO=/tmp/panel-fifo
PANEL_HEIGHT=24
-PANEL_FONT_FAMILY="-misc-fixed-medium-r-normal--13-120-75-75-c-70-iso10646-1"
-export PANEL_FIFO PANEL_HEIGHT PANEL_FONT_FAMILY
+
+FONT_FONT="fixed"
+ICON_FONT="FontAwesome-9"
+
+export PANEL_FIFO PANEL_HEIGHT PANEL_FONT_FAMILY FONT_FONT ICON_FONT
diff --git a/xinitrc b/xinitrc
index b15bb8e..b3a5676 100755
--- a/xinitrc
+++ b/xinitrc
@@ -67,7 +67,7 @@ xrdb -merge ~/.Xdefaults
#dropbox start
~/bin/offline-run &
#xflux -z 24531 -l 56 -g 13
-nm-applet &
+#nm-applet &
#Disable annoying point tap
synclient PalmDetect=1
diff --git a/zshrc b/zshrc
index 51d5e1d..455185b 100644
--- a/zshrc
+++ b/zshrc
@@ -23,7 +23,7 @@ source ~/.bash_aliases
export GPGKEY="895134C5"
export PATH="$HOME/bin:$PATH"
-export EDITOR="nvim"
+export EDITOR="vim"
export BROWSER="~/.ratposon/firesend"
export LD_LIBRARY_PATH=/usr/local/lib
export wiki_browser='firefox'