summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuke Shumaker <LukeShu@sbcglobal.net>2012-08-21 22:47:23 -0400
committerLuke Shumaker <LukeShu@sbcglobal.net>2012-08-21 22:47:23 -0400
commit510fea7116c6bd01824af38b4e516b6e19fded81 (patch)
tree99bc145f164a450b95c9a35a1b2e0315ca1d98bb
parent69e7a06e976bbad54684b8c650853020c8352adb (diff)
parent6368f5b020f65de535ce74ad69bf64702daddb48 (diff)
Merge branch 'hp-dv6426us-par'
-rw-r--r--.config/vlc/vlcrc200
-rw-r--r--.emacs175
-rw-r--r--.emacs.d/.gitignore4
-rw-r--r--.emacs.d/custom.el4
-rwxr-xr-x.local/bin/notifyd14
-rw-r--r--.profile8
-rwxr-xr-x.wmii/autostart1
-rwxr-xr-x.wmii/exec2
-rw-r--r--.wmii/include.sh70
-rwxr-xr-x.wmii/quit3
-rwxr-xr-x.wmii/rbar_battery10
-rwxr-xr-x.wmii/rbar_clock10
-rwxr-xr-x.wmii/rbar_cpu13
-rwxr-xr-x.wmii/rbar_wifi10
-rwxr-xr-x.wmii/wmiirc115
-rw-r--r--.xinitrc2
16 files changed, 270 insertions, 371 deletions
diff --git a/.config/vlc/vlcrc b/.config/vlc/vlcrc
index 35d4eab..21a90e4 100644
--- a/.config/vlc/vlcrc
+++ b/.config/vlc/vlcrc
@@ -1,5 +1,5 @@
###
-### vlc 2.0.1
+### vlc 2.0.3
###
###
@@ -1923,19 +1923,19 @@
[spatializer] # Audio Spatializer
# Room size (float)
-#spatializer-roomsize=1.050000
+#spatializer-roomsize=0.850000
# Room width (float)
-#spatializer-width=10.000000
+#spatializer-width=1.000000
# Wet (float)
-#spatializer-wet=3.000000
+#spatializer-wet=0.400000
# Dry (float)
-#spatializer-dry=2.000000
+#spatializer-dry=0.500000
# Damp (float)
-#spatializer-damp=1.000000
+#spatializer-damp=0.500000
[a52tofloat32] # ATSC A/52 (AC-3) audio decoder
@@ -1951,22 +1951,22 @@
#compressor-rms-peak=0.000000
# Attack time (float)
-compressor-attack=1.400000
+#compressor-attack=25.000000
# Release time (float)
-compressor-release=1.900000
+#compressor-release=100.000000
# Threshold level (float)
-compressor-threshold=0.000000
+#compressor-threshold=-11.000000
# Ratio (float)
-compressor-ratio=1.000000
+#compressor-ratio=8.000000
# Knee radius (float)
-compressor-knee=1.000000
+#compressor-knee=2.500000
# Makeup gain (float)
-compressor-makeup-gain=0.000000
+#compressor-makeup-gain=7.000000
[samplerate] # Secret Rabbit Code (libsamplerate) resampler
@@ -1985,7 +1985,7 @@ compressor-makeup-gain=0.000000
#equalizer-2pass=0
# Global gain (float)
-equalizer-preamp=0.000000
+#equalizer-preamp=12.000000
[theora] # Theora video decoder
@@ -2647,10 +2647,10 @@ equalizer-preamp=0.000000
[skins2] # Skinnable Interface
# Skin to use (string)
-skins2-last=/usr/share/vlc/skins2/default.vlt
+#skins2-last=
# Config of last used skin (string)
-skins2-config=[aboutwin aboutwinwin-main 0 0 330 171 0][eqwin eqwin-main 0 0 330 171 0][fullscreenController fsc_normal 30 30 500 500 1][main normal 0 0 500 350 1][plwin plwin-normal 0 0 500 350 0]
+#skins2-config=
# Enable transparency effects (boolean)
#skins2-transparency=0
@@ -3425,7 +3425,7 @@ qt-privacy-ask=0
#audio=1
# Default audio volume (integer)
-volume=224
+volume=263
# Audio output volume step (integer)
#volume-step=32
@@ -3623,7 +3623,7 @@ volume=224
#sub-autodetect-fuzzy=3
# Subtitle autodetection paths (string)
-#sub-autodetect-path=./Subtitles, ./subtitles
+#sub-autodetect-path=./Subtitles, ./subtitles, ./Subs, ./subs
# Force subtitle position (integer)
#sub-margin=0
@@ -3929,7 +3929,7 @@ volume=224
#auto-preparse=1
# Album art policy (integer)
-album-art=2
+#album-art=0
# Services discovery modules (string)
#services-discovery=
@@ -4618,167 +4618,3 @@ album-art=2
# Playlist bookmark 10 (string)
#bookmark10=
-[fluidsynth] # FluidSynth MIDI synthesizer
-# Sound fonts (string)
-#soundfont=
-# Synthesis gain (float)
-#synth-gain=0.800000
-[snapshot] # Snapshot output
-# Snapshot width (integer)
-#vout-snapshot-width=320
-# Snapshot height (integer)
-#vout-snapshot-height=200
-# Chroma (string)
-#vout-snapshot-chroma=RV32
-# Cache size (number of images) (integer)
-#vout-snapshot-cache-size=50
-[oldtelnet] # VLM remote control interface
-# Host (string)
-#telnet-host=localhost
-# Port (integer)
-#telnet-port=4212
-# Password (string)
-#telnet-password=admin
-[oldhttp] # HTTP remote control interface
-# Host address (string)
-#http-host=
-# Source directory (string)
-#http-src=
-# Handlers (string)
-#http-handlers=
-# Export album art as /art (boolean)
-#http-album-art=0
-# Certificate file (string)
-#http-intf-cert=
-# Private key file (string)
-#http-intf-key=
-# Root CA file (string)
-#http-intf-ca=
-# CRL file (string)
-#http-intf-crl=
-[crop] # Crop video filter
-# Crop geometry (pixels) (string)
-#crop-geometry=
-# Automatic cropping (boolean)
-#autocrop=0
-# Ratio max (x 1000) (integer)
-#autocrop-ratio-max=2405
-# Manual ratio (integer)
-#crop-ratio=0
-# Number of images for change (integer)
-#autocrop-time=25
-# Number of lines for change (integer)
-#autocrop-diff=16
-# Number of non black pixels (integer)
-#autocrop-non-black-pixels=3
-# Skip percentage (%) (integer)
-#autocrop-skip-percent=17
-# Luminance threshold (integer)
-#autocrop-luminance-threshold=40
-[fake] # Fake video decoder
-# Image file (string)
-#fake-file=
-# Reload image file (integer)
-#fake-file-reload=0
-# Video width (integer)
-#fake-width=0
-# Video height (integer)
-#fake-height=0
-# Keep aspect ratio (boolean)
-#fake-keep-ar=0
-# Background aspect ratio (string)
-#fake-aspect-ratio=
-# Deinterlace video (boolean)
-#fake-deinterlace=0
-# Deinterlace module (string)
-#fake-deinterlace-module=deinterlace
-# Chroma used (string)
-#fake-chroma=I420
-[invmem] # Memory video decoder
-# Width (integer)
-#invmem-width=0
-# Height (integer)
-#invmem-height=0
-# Lock function (string)
-#invmem-lock=0
-# Unlock function (string)
-#invmem-unlock=0
-# Callback data (string)
-#invmem-data=0
-# Chroma (string)
-#invmem-chroma=RV24
-[dvb] # DVB input with v4l2 support
-# Caching value in ms (integer)
-#dvb-caching=300
-# Adapter card to tune (integer)
-#dvb-adapter=0
-# Device number to use on adapter (integer)
-#dvb-device=0
-# Transponder/multiplex frequency (integer)
-#dvb-frequency=0
-# Inversion mode (integer)
-#dvb-inversion=2
-# Probe DVB card for capabilities (boolean)
-#dvb-probe=1
-# Budget mode (boolean)
-#dvb-budget-mode=0
-# Satellite number in the Diseqc system (integer)
-#dvb-satno=0
-# LNB voltage (integer)
-#dvb-voltage=13
-# High LNB voltage (boolean)
-#dvb-high-voltage=0
-# 22 kHz tone (integer)
-#dvb-tone=-1
-# Transponder FEC (integer)
-#dvb-fec=9
-# Transponder symbol rate in kHz (integer)
-#dvb-srate=27500000
-# Antenna lnb_lof1 (kHz) (integer)
-#dvb-lnb-lof1=0
-# Antenna lnb_lof2 (kHz) (integer)
-#dvb-lnb-lof2=0
-# Antenna lnb_slof (kHz) (integer)
-#dvb-lnb-slof=0
-# Modulation type (integer)
-#dvb-modulation=0
-# Terrestrial high priority stream code rate (FEC) (integer)
-#dvb-code-rate-hp=9
-# Terrestrial low priority stream code rate (FEC) (integer)
-#dvb-code-rate-lp=9
-# Terrestrial bandwidth (integer)
-#dvb-bandwidth=0
-# Terrestrial guard interval (integer)
-#dvb-guard=0
-# Terrestrial transmission mode (integer)
-#dvb-transmission=0
-# Terrestrial hierarchy mode (integer)
-#dvb-hierarchy=0
-# HTTP Host address (string)
-#dvb-http-host=
-# HTTP user name (string)
-#dvb-http-user=
-# HTTP password (string)
-#dvb-http-password=
-# HTTP ACL (string)
-#dvb-http-acl=
-# Certificate file (string)
-#dvb-http-intf-cert=
-# Private key file (string)
-#dvb-http-intf-key=
-# Root CA file (string)
-#dvb-http-intf-ca=
-# CRL file (string)
-#dvb-http-intf-crl=
-[access_fake] # Fake video input
-# Caching value in ms (integer)
-#fake-caching=300
-# Framerate (float)
-#fake-fps=25.000000
-# ID (integer)
-#fake-id=0
-# Duration in ms (integer)
-#fake-duration=-1
-[access_mmap] # Memory-mapped file input
-# Use file memory mapping (boolean)
-#file-mmap=0
diff --git a/.emacs b/.emacs
index 99bdf77..0637377 100644
--- a/.emacs
+++ b/.emacs
@@ -1,132 +1,81 @@
-(set-face-attribute 'default nil :height 80)
+;; Preliminary settings ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+(set-face-attribute 'default nil :height 80)
+(setq notify-method 'notify-via-libnotify)
+(add-to-list 'load-path "~/.emacs.d/")
+(add-to-list 'load-path "~/.emacs.d/el-get/el-get")
(setq custom-file "~/.emacs.d/custom.el")
-(load custom-file 'noerror)
-(defun load-identica-mode ()
- (when (require 'netrc nil t)
- (autoload 'identica-mode "identica-mode" nil t)
- (let ((identica (netrc-machine (netrc-parse "~/.netrc") "identi.ca" t)))
- (setq identica-password (netrc-get identica "password"))
- (setq identica-username (netrc-get identica "login"))
- )
- )
-)
+; derived from ELPA installation
+; http://tromey.com/elpa/install.html
+(defun eval-url (url)
+ (let ((buffer (url-retrieve-synchronously url)))
+ (save-excursion
+ (set-buffer buffer)
+ (goto-char (point-min))
+ (re-search-forward "^$" nil 'move)
+ (eval-region (point) (point-max))
+ (kill-buffer (current-buffer)))))
+
+ ;; ELPA stuff ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+
+(unless (require 'package nil t)
+ (eval-url "http://tromey.com/elpa/package-install.el"))
(setq package-archives '(("ELPA" . "http://tromey.com/elpa/")
("marmalade" . "http://marmalade-repo.org/packages/")
("gnu" . "http://elpa.gnu.org/packages/")))
+;; el-get stuff ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-(add-to-list 'load-path "~/.emacs.d/")
-(add-to-list 'load-path "~/.emacs.d/el-get/el-get")
+(setq el-get-install-branch "master") ;; live life on the edge
(unless (require 'el-get nil t)
- (url-retrieve
- "https://github.com/dimitri/el-get/raw/master/el-get-install.el"
- (lambda (s)
- (end-of-buffer)
- (eval-print-last-sexp))))
-
-(setq el-get-sources
- '((:name scss-mode
- :url "git://github.com/antonj/scss-mode.git"
- :after (lambda ()
- (setq scss-compile-at-save nil)))
- (:name color-theme
- :after (lambda ()
- (color-theme-tty-dark)))
- (:name color-theme-solarized
- :after (lambda ()
- (add-hook 'after-make-frame-functions
- (lambda (frame)
- (set-variable 'color-theme-is-global nil)
- (select-frame frame)
- (if window-system
- (color-theme-solarized-dark)
- (color-theme-tty-dark))))))
- (:name org-mode
- :after (lambda ()
- (require 'org-checklist)
- (setq org-hide-leading-stars t)
- (setq org-log-done 'time)))
- (:name identica-mode
- :type http-tar
- :options ("xzf")
- :url "http://git.savannah.gnu.org/cgit/identica-mode.git/snapshot/identica-mode-1.1.tar.gz"
- :load "identica-mode.el"
- :after (lambda ()
- (load-identica-mode)))
- (:name nginx-mode
- :description "Major mode for editing Nginx configuration files"
- :type git
- :url "git://github.com/ajc/nginx-mode.git")
- (:name autopair
- :after (lambda ()
- (autopair-global-mode 1)
- (setq autopair-autowrap t)))
- ))
+ (eval-url "https://github.com/dimitri/el-get/raw/master/el-get-install.el"))
+
+(setq el-get-sources '(
+ (:name nxhtml
+ :type http
+ :url "http://ourcomments.org/Emacs/DL/elisp/nxhtml/zip/nxhtml-2.08-100425.zip"
+ :build ("unzip nxhtml-2.08-100425.zip")
+ :load "nxhtml/autostart.el")
+ ))
-(setq lts-el-get-packages
+(setq my-el-get-packages
'(el-get
- package
- rainbow-delimiters
- php-mode-improved
- mmm-mode
- dtrt-indent
- coffee-mode
- folding
- apel flim semi wanderlust
- scss-mode
- color-theme color-theme-solarized
- org-mode
- identica-mode
+; nxhtml
smarttabs
- markdown-mode
- autopair
- nginx-mode
))
-(when (require 'el-get nil t)
- (el-get 'sync lts-el-get-packages))
+;; Now load all of that ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-(add-hook 'text-mode-hook 'turn-on-auto-fill)
-(add-hook 'after-make-frame-functions
- (lambda (frame)
- (set-variable 'term-default-fg-color
- (face-foreground 'default))
- (set-variable 'term-default-bg-color
- (face-background 'default)))
- t)
+;; ELPA
+(package-initialize)
+;; el-get
+(when (require 'el-get nil t) (el-get 'sync my-el-get-packages))
+;; custom
+(load custom-file 'noerror)
+
+;; General settings ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;(load "mdmua")
(load "emacsutils")
(tool-bar-mode -1)
(ido-mode t)
(show-paren-mode 1)
-
-(defun toggle-fullscreen (&optional f)
- (interactive)
- (let ((current-value (frame-parameter nil 'fullscreen)))
- (set-frame-parameter nil 'fullscreen
- (if (equal 'fullboth current-value)
- (if (boundp 'old-fullscreen) old-fullscreen nil)
- (progn (setq old-fullscreen current-value)
- 'fullboth)))))
-(global-set-key [f11] 'toggle-fullscreen)
+(setq org-hide-leading-stars t)
+(setq org-log-done 'time)
+;(xclip-mode 1)
(load "whitespace")
-(global-set-key "\C-cw" 'global-whitespace-mode)
(setq whitespace-style '(
-; face
-; tabs
tab-mark
-; spaces
space-mark
-; newline
newline-mark
empty
))
+
;; These are my preferred settings; we let dtrt-indent detect when we play with other's files
(setq-default tab-width 8)
(setq-default c-basic-offset 8)
@@ -135,7 +84,7 @@
(setq
backup-by-copying t ;; don't clobber symlinks
- backup-directory-alist '(("." . "~/.saves")) ;; don't litter my fs tree
+ backup-directory-alist '(("." . "~/.emacs.d/saves")) ;; don't litter my fs tree
delete-old-versions t
kept-new-versions 6
kept-old-versions 2
@@ -152,6 +101,34 @@
(setq browse-url-generic-program (executable-find "v-www-browser")
browse-url-browser-function 'browse-url-generic)
+
+(defun toggle-fullscreen (&optional f)
+ (interactive)
+ (let ((current-value (frame-parameter nil 'fullscreen)))
+ (set-frame-parameter nil 'fullscreen
+ (if (equal 'fullboth current-value)
+ (if (boundp 'old-fullscreen) old-fullscreen nil)
+ (progn (setq old-fullscreen current-value)
+ 'fullboth)))))
+
+;; Custom keybindings ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+
+(global-set-key [f11] 'toggle-fullscreen)
+(global-set-key "\C-cw" 'global-whitespace-mode)
+
+;; mode-hooks ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+
+(add-hook 'text-mode-hook 'turn-on-auto-fill)
+
+; for term-mode
+;; (add-hook 'after-make-frame-functions
+;; (lambda (frame)
+;; (set-variable 'term-default-fg-color
+;; (face-foreground 'default))
+;; (set-variable 'term-default-bg-color
+;; (face-background 'default)))
+;; t)
+
(add-hook 'lisp-mode-hook
'(lambda ()
(set (make-local-variable 'indent-tabs-mode) nil)
diff --git a/.emacs.d/.gitignore b/.emacs.d/.gitignore
index 675a8be..ef4ec20 100644
--- a/.emacs.d/.gitignore
+++ b/.emacs.d/.gitignore
@@ -1,7 +1,9 @@
auto-save-list/*
el-get/*
-server/*
elmo/*
+elpa/*
image-dired/*
+server/*
session.*
+tramp
url/*
diff --git a/.emacs.d/custom.el b/.emacs.d/custom.el
index 0d4cf4a..ee82309 100644
--- a/.emacs.d/custom.el
+++ b/.emacs.d/custom.el
@@ -3,7 +3,11 @@
;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
+ '(custom-enabled-themes (quote (wombat)))
+ '(custom-safe-themes (quote ("71b172ea4aad108801421cc5251edb6c792f3adbaecfa1c52e94e3d99634dee7" "fc5fcb6f1f1c1bc01305694c59a1a861b008c534cae8d0e48e4d5e81ad718bc6" default)))
'(erc-nick "lukeshu")
+ '(explicit-shell-file-name "/bin/bash")
+ '(inhibit-startup-screen t)
'(mdmua-maildir "~/Maildir")
'(ruby-deep-arglist nil)
'(ruby-deep-indent-paren nil)
diff --git a/.local/bin/notifyd b/.local/bin/notifyd
new file mode 100755
index 0000000..ddd5971
--- /dev/null
+++ b/.local/bin/notifyd
@@ -0,0 +1,14 @@
+#!/bin/bash
+
+connected_to_x_server() {
+ xdpyinfo &>/dev/null
+ return $?
+}
+
+start_backend() {
+ /usr/lib/xfce4/notifyd/xfce4-notifyd
+}
+
+while connected_to_x_server; do
+ start_backend
+done
diff --git a/.profile b/.profile
index d05ae5e..f394fbd 100644
--- a/.profile
+++ b/.profile
@@ -42,6 +42,7 @@ _JAVA_OPTIONS=''
_JAVA_OPTIONS+=' -Dawt.useSystemAAFontSettings=on'
_JAVA_OPTIONS+=' -Dswing.aatext=true'
_JAVA_OPTIONS+=' -Dswing.defaultlaf=com.sun.java.swing.plaf.gtk.GTKLookAndFeel'
+_JAVA_OPTIONS+=" -Djava.io.tmpdir=$TMPDIR"
export _JAVA_OPTIONS
# ALSA
@@ -54,6 +55,13 @@ if [ -z "$XAUTHORITY" ]; then
export XAUTHORITY=$HOME/.Xauthority
fi
+# D-Bus
+if [ -z "$DBUS_SESSION_BUS_ADDRESS" ]; then
+ eval `dbus-launch`
+ export DBUS_SESSION_BUS_ADDRESS
+ export DBUS_SESSION_BUS_PID
+fi
+
# Start background programs ##########################################
if [ -f "$HOME/.login-daemons" ]; then
. "$HOME/.login-daemons"
diff --git a/.wmii/autostart b/.wmii/autostart
index b44ade8..aae23f4 100755
--- a/.wmii/autostart
+++ b/.wmii/autostart
@@ -1,3 +1,4 @@
#!/bin/bash
daemon lxpanel &> /dev/null
daemon wicd-client -t &> /dev/null
+daemon notifyd &> /dev/null
diff --git a/.wmii/exec b/.wmii/exec
deleted file mode 100755
index c83d790..0000000
--- a/.wmii/exec
+++ /dev/null
@@ -1,2 +0,0 @@
-#!/bin/bash
-echo exec "$@" >> $WMII_DIR/ctl
diff --git a/.wmii/include.sh b/.wmii/include.sh
new file mode 100644
index 0000000..36f8f3e
--- /dev/null
+++ b/.wmii/include.sh
@@ -0,0 +1,70 @@
+#!/bin/bash
+
+if [ -z "$WMII_NAMESPACE" ]; then
+ export WMII_NAMESPACE=`wmiir namespace`
+fi
+if [ -z "$WMII_DIR" ]; then
+ export WMII_DIR=$WMII_NAMESPACE/mnt
+fi
+
+# a -- a work-around for buggy IO append in 9pfuse
+# useing '|a' should be just like using '>>', but will work
+# when 9pfuse decides to bug out.
+a() {
+ f="${1/#${WMII_DIR}/}"
+ if [ "$f" = "$1" ]; then
+ cat >> "$1"
+ else
+ if wmiir ls "$f" &>/dev/null; then
+ wmiir write "$f"
+ else
+ wmiir create "$f"
+ fi
+ fi
+}
+
+# I like wmiir's setsid better than linux-utils'
+setsid() { wmiir setsid "$@"; }
+
+path_ls() {
+ find -L `echo "$@"|sed 'y/:/ /'` -maxdepth 1 -type f -executable -printf '%f\n' 2>/dev/null| sort -u
+}
+
+path_which() {
+ mypath=$1
+ prog=$2
+ which=`which which`
+ PATH="$mypath" "$which" -- "$prog" 2>/dev/null
+}
+
+
+lstags() {
+ ls $WMII_DIR/tag | sed '/^sel$/d'
+}
+
+scansection() {
+ file=`path_which "$WMII_CONFPATH" wmiirc`
+ sec=$1
+ tmp=`mktemp`
+ if [ -n "$sec" ]; then
+ < "$file" sed -n "/^\s*$sec\s*()/,/##\s*End $sec/p" | sed '1d;$d'> $tmp
+ else
+ < "$file" sed "/\s*}\s*##\s*End\s/d" > $tmp
+ fi
+ < $tmp sed -n '/##/p'|sed -r 's/^\s*(.*)\)\s*## ?/\t\1\t/;s/\s*## ?//'
+ rm $tmp
+}
+
+conffile() {
+ echo "$HOME/.wmii/$@"
+}
+
+Action() {
+ prog=`path_which "$WMII_CONFPATH" $1`; shift
+ if [ -n "$prog" ]; then
+ "$prog" "$@"
+ return $?
+ else
+ return 1
+ fi
+}
diff --git a/.wmii/quit b/.wmii/quit
index d7a55c3..54f64e7 100755
--- a/.wmii/quit
+++ b/.wmii/quit
@@ -1,2 +1,3 @@
#!/bin/bash
-echo quit >> $WMII_DIR/ctl
+. "$HOME/.wmii/include.sh"
+echo quit |a $WMII_DIR/ctl
diff --git a/.wmii/rbar_battery b/.wmii/rbar_battery
new file mode 100755
index 0000000..7a7f24f
--- /dev/null
+++ b/.wmii/rbar_battery
@@ -0,0 +1,10 @@
+#!/bin/bash
+. "$HOME/.wmii/include.sh"
+
+priority=$1
+
+set -e
+while true; do
+ acpi -b |a "$WMII_DIR/rbar/${priority}_battery"
+ sleep 1
+done
diff --git a/.wmii/rbar_clock b/.wmii/rbar_clock
new file mode 100755
index 0000000..8e7d2a4
--- /dev/null
+++ b/.wmii/rbar_clock
@@ -0,0 +1,10 @@
+#!/bin/bash
+. "$HOME/.wmii/include.sh"
+
+priority=$1
+
+set -e
+while true; do
+ date |a "$WMII_DIR/rbar/${priority}_clock"
+ sleep .5
+done
diff --git a/.wmii/rbar_cpu b/.wmii/rbar_cpu
new file mode 100755
index 0000000..7f891da
--- /dev/null
+++ b/.wmii/rbar_cpu
@@ -0,0 +1,13 @@
+#!/bin/bash
+. "$HOME/.wmii/include.sh"
+
+priority=$1
+
+set -e
+while true; do
+ # This doesn't work for me, it shows capacity
+ #echo -n 'Core MHz:' $(cat /proc/cpuinfo | grep 'cpu MHz' | sed 's/.*: //g; s/\..*//g;') |a "$WMII_DIR/rbar/${priority}_cpu"
+ # This actually displays %idle
+ echo 'CPU: [ '$(tail -n3 ~/tmp/cputime|sed -ur 's/\s\s+/\t/g'|cut -f2,11|sed 's/\t\(.*\)/(\1)/')' ]' |a "$WMII_DIR/rbar/${priority}_cpu"
+ sleep 1
+done
diff --git a/.wmii/rbar_wifi b/.wmii/rbar_wifi
new file mode 100755
index 0000000..608b164
--- /dev/null
+++ b/.wmii/rbar_wifi
@@ -0,0 +1,10 @@
+#!/bin/bash
+. "$HOME/.wmii/include.sh"
+
+priority=$1
+
+set -e
+while true; do
+ echo 'Wlan0:' $(iwconfig wlan0 | sed 's/ /\n/g' | grep Quality) |a "$WMII_DIR/rbar/${priority}_wifi"
+ sleep 1
+done
diff --git a/.wmii/wmiirc b/.wmii/wmiirc
index f211d7f..82c424b 100755
--- a/.wmii/wmiirc
+++ b/.wmii/wmiirc
@@ -1,95 +1,30 @@
#!/bin/bash
# Let any running instances of wmiirc know that we're starting
-
-echo ' ==> Starting wmiirc'
wmiir xwrite /event Start
-export WMII_NAMESPACE=`wmiir namespace`
-mount9p=/opt/plan9/bin/9pfuse
+. "$HOME/.wmii/include.sh"
+echo ' ==> Starting wmiirc'
+mount9p=/opt/plan9/bin/9pfuse
mkdir -p $WMII_NAMESPACE/mnt
$mount9p $WMII_NAMESPACE/{wmii,mnt}
-export WMII_DIR=$WMII_NAMESPACE/mnt
-
-# a -- a work-around for buggy IO append in 9pfuse
-# useing '|a' should be just like using '>>', but will work
-# when 9pfuse decides to bug out.
-a() {
- f="${1/#${WMII_DIR}/}"
- if [ "$f" = "$1" ]; then
- cat >> "$1"
- else
- if wmiir ls "$f" &>/dev/null; then
- wmiir write "$f"
- else
- wmiir create "$f"
- fi
- fi
-}
-# I like wmiir's setsid better than linux-utils'
-setsid() { wmiir setsid "$@"; }
-WMII_FONT='xft:Monospace-8'
-WMII_TERM=x-terminal-emulator
-
-. $HOME/.wmii/wmiirc_local
-# Configuration Variables
+
+MODKEY=Mod4 # super
UP=p
DOWN=n
LEFT=b
RIGHT=f
# Colors tuples: "<text> <background> <border>"
-. $HOME/.wmii/theme-solarized-dark
+. `conffile theme-solarized-dark`
# Menu history
-hist="${WMII_CONFPATH%%:*}/history"
+hist="`conffile history`"
# Tagging Rules
-echo '/Emacs|Navigator/ -> +sel' |a $WMII_DIR/tagrules
-echo '/panel/ -> /.*/' |a $WMII_DIR/tagrules
-
-if [ -f "${WMII_CONFPATH%%:*}/wmiirc_local" ]; then
- . "${WMII_CONFPATH%%:*}/wmiirc_local"
-fi
-
-path_ls() {
- find -L `echo "$@"|sed 'y/:/ /'` -maxdepth 1 -type f -executable -printf '%f\n' 2>/dev/null| sort -u
-}
-
-path_which() {
- mypath=$1
- prog=$2
- which=`which which`
- PATH="$mypath" "$which" -- "$prog" 2>/dev/null
-}
-
-
-lstags() {
- ls $WMII_DIR/tag | sed '/^sel$/d'
-}
-
-scansection() {
- file=`path_which "$WMII_CONFPATH" wmiirc`
- sec=$1
- tmp=`mktemp`
- if [ -n "$sec" ]; then
- < "$file" sed -n "/^\s*$sec\s*()/,/##\s*End $sec/p" | sed '1d;$d'> $tmp
- else
- < "$file" sed "/\s*}\s*##\s*End\s/d" > $tmp
- fi
- < $tmp sed -n '/##/p'|sed -r 's/^\s*(.*)\)\s*## ?/\t\1\t/;s/\s*## ?//'
- rm $tmp
-}
-
-Action() {
- prog=`path_which "$WMII_CONFPATH" $1`; shift
- if [ -n "$prog" ]; then
- "$prog" "$@"
- return $?
- else
- return 1
- fi
-}
+echo '/Emacs|Navigator/ -> +sel' >> $WMII_DIR/tagrules
+echo '/Eclipse/ -> +sel' >> $WMII_DIR/tagrules
+echo '/panel/ -> /.*/' >> $WMII_DIR/tagrules
Event() {
event=$1; shift;
@@ -107,10 +42,14 @@ Event() {
## WMII-meta events
Quit) ## No args
- fusermount -u $WMII_DIR
- exit $?;;
+ echo ' ==> Stopping wmiirc'
+ echo " -> unmounting WMII_DIR=$WMII_DIR..."
+ # might complain about /etc/mtab if the x server has already stopped
+ fusermount -u "$WMII_DIR" 2>>/dev/null
+ echo " -> rmdir'ing WMII_DIR=$WMII_DIR..."
+ rmdir "$WMII_DIR";;
Warning) ## $@=string
- notify-send "wmii warning: $@";;
+ notify-send "wmii warning: $*";;
Key) ## $1=keystroke
Key "$@";;
@@ -171,7 +110,7 @@ Event() {
## Tag events
CreateTag) ## $1=tag
- echo "$WMII_NORMCOLORS" $@ |a $WMII_DIR/lbar/$1;;
+ echo "$WMII_NORMCOLORS" $@ |a $WMII_DIR/lbar/$1;;
DestroyTag) ## $1=tag
rm $WMII_DIR/lbar/$1;;
FocusTag) ## $1=tag
@@ -264,7 +203,7 @@ Key() {
$MODKEY-x) ## Open program menu
setsid $(wimenu -h "${hist}.progs" -n 5000 <$progsfile) & ;;
$MODKEY-Return) ## Launch a terminal
- setsid $WMII_TERM & ;;
+ setsid x-terminal-emulator & ;;
## Other
$MODKEY-Control-t) ## Toggle all other key bindings
@@ -293,11 +232,11 @@ Key() {
} ## End Key
# WM Configuration
-echo font $WMII_FONT |a $WMII_DIR/ctl
+echo font xft:Monospace-8 |a $WMII_DIR/ctl
echo focuscolors $WMII_FOCUSCOLORS |a $WMII_DIR/ctl
-echo normcolors $WMII_NORMCOLORS |a $WMII_DIR/ctl
-echo grabmod $MODKEY |a $WMII_DIR/ctl
-echo border 1 |a $WMII_DIR/ctl
+echo normcolors $WMII_NORMCOLORS |a $WMII_DIR/ctl
+echo grabmod $MODKEY |a $WMII_DIR/ctl
+echo border 1 |a $WMII_DIR/ctl
xsetroot -solid "$WMII_BACKGROUND" &
progsfile=$WMII_NAMESPACE/.proglist
@@ -319,7 +258,13 @@ done
Action autostart 2>/dev/null &
+if [ -f "`conffile wmiirc_local`" ]; then
+ . "`conffile wmiirc_local`"
+fi
+
+trap "Event Quit" EXIT
+
# use wmiir so it doesn't look like an open file
-wmiir read /event | while read event; do
+wmiir read /event 2>/dev/null | while read event; do
Event $event
done
diff --git a/.xinitrc b/.xinitrc
index 203a5cb..9c5ce55 100644
--- a/.xinitrc
+++ b/.xinitrc
@@ -11,7 +11,7 @@ if [ -d /etc/X11/xinit/xinitrc.d ]; then
[ -x "$f" ] && "$f" &
done
unset f
- echo ' -> done'
+ echo ' -> done'
fi
usermodmap="$HOME/.xmodmap"