aboutsummaryrefslogtreecommitdiff
path: root/ratpoison
diff options
context:
space:
mode:
authorVasil Zlatanov <vasil.zlatanov@gmail.com>2015-04-12 13:04:12 +0200
committerVasil Zlatanov <vasil.zlatanov@gmail.com>2015-04-12 13:04:12 +0200
commit269e617fea39658233db38ad503030c4fe040e80 (patch)
tree6a0287e6e892d5a673b6a60d1da9b013b2257a75 /ratpoison
parentc955393cbd6e135fe351876f28993290df61fdfa (diff)
downloaddotfiles-269e617fea39658233db38ad503030c4fe040e80.tar.gz
dotfiles-269e617fea39658233db38ad503030c4fe040e80.tar.bz2
dotfiles-269e617fea39658233db38ad503030c4fe040e80.zip
Spring cleanup!
Diffstat (limited to 'ratpoison')
-rw-r--r--ratpoison/README.md41
-rwxr-xr-xratpoison/borderscript11
-rwxr-xr-xratpoison/bordtoggle12
-rwxr-xr-xratpoison/clipboard106
-rwxr-xr-xratpoison/cmusplaying1
-rwxr-xr-xratpoison/cmusvolind34
-rwxr-xr-xratpoison/create_framebin9832 -> 0 bytes
-rwxr-xr-xratpoison/exec_to_workspace12
-rwxr-xr-xratpoison/firesend2
-rw-r--r--ratpoison/functions6
-rwxr-xr-xratpoison/mpdvolind34
-rwxr-xr-xratpoison/newtab2
-rwxr-xr-xratpoison/panel/load7
-rwxr-xr-xratpoison/panel/monce25
-rwxr-xr-xratpoison/panel/music20
-rwxr-xr-xratpoison/panel/panel26
-rwxr-xr-xratpoison/panel/panel_bar123
-rw-r--r--ratpoison/panel/panel_colors33
-rw-r--r--ratpoison/panel/profile4
-rwxr-xr-xratpoison/panel/signal19
-rwxr-xr-xratpoison/paneltoggle12
-rw-r--r--ratpoison/py/color_detect.py108
-rw-r--r--ratpoison/py/colorz.py71
-rwxr-xr-xratpoison/ratcolor7
-rwxr-xr-xratpoison/ratmenubin24598 -> 0 bytes
-rw-r--r--ratpoison/ratpoisonrc.clipboard57
-rw-r--r--ratpoison/ratpoisonrc.conf350
-rwxr-xr-xratpoison/rpbarbin31106 -> 0 bytes
-rwxr-xr-xratpoison/rpbarobin31057 -> 0 bytes
-rwxr-xr-xratpoison/rpbarsendbin13793 -> 0 bytes
-rwxr-xr-xratpoison/screen_run21
-rwxr-xr-xratpoison/screenout2
-rw-r--r--ratpoison/screenrc34
-rw-r--r--ratpoison/screenrc.admin20
-rw-r--r--ratpoison/screenrc.irssi6
-rw-r--r--ratpoison/screenrc.mutt6
-rw-r--r--ratpoison/screenrc.projects11
-rw-r--r--ratpoison/screenrc.school19
-rw-r--r--ratpoison/screenrcnobar29
-rwxr-xr-xratpoison/spotlight4
-rwxr-xr-xratpoison/taskbar2
-rwxr-xr-xratpoison/time7
-rwxr-xr-xratpoison/volind32
-rwxr-xr-xratpoison/window_menu40
-rwxr-xr-xratpoison/workspace_menu24
-rwxr-xr-xratpoison/wp257
-rwxr-xr-xratpoison/xtoolwaitbin13112 -> 0 bytes
47 files changed, 0 insertions, 1637 deletions
diff --git a/ratpoison/README.md b/ratpoison/README.md
deleted file mode 100644
index 6970672..0000000
--- a/ratpoison/README.md
+++ /dev/null
@@ -1,41 +0,0 @@
-# wp
-
-wp is a small tool I use to generate color schemes from images, and manage desktop wallpapers.
-
-The color extraction scripts were taken from [this blog post](http://charlesleifer.com/blog/using-python-and-k-means-to-find-the-dominant-colors-in-images/)
- with normalization reddit user radiosilence.
-
-## Dependencies
-
-As far as I know this only relies on PIL, python image library. I was able to fulfill this dependency with the `python-pillow` package on Arch Linux.
-On other systems, `pip install Pillow`.
-
-## Usage
-
-```
-$ wp add [file]
-```
-
-Generates color files .[file].colors and .[file].Xres which can be sourced by shell
-scripts and xrdb respectivly. The color files and the image are added to the backgrounds directory.
-
-```
-$ wp change [file]
-```
-
-Changes the background image to a random image from the ~/.wallpapers directory, or the file passed, and loads the .Xres file
-into xrdb so xterm or urxvt will use the colors. It also links a script to ~/.colors. If you `source ~/.colors` in a script
-you can use the generated colors with `$COLOR0`, `$COLOR1`, ...
-
-
-```
-$ wp rm [file]
-```
-
-Removes the image and it's color files from the backgrounds directory.
-
-```
-$ wp ls
-```
-
-Lists the images in the backgrounds folder.
diff --git a/ratpoison/borderscript b/ratpoison/borderscript
deleted file mode 100755
index 1495bec..0000000
--- a/ratpoison/borderscript
+++ /dev/null
@@ -1,11 +0,0 @@
-#!/bin/bash
-
-frames=`ratpoison -c fdump | tr -d -C '(' | wc -c`
-
-if [[ $frames == 1 ]];then
-ratpoison -c "hideborder"
-ratpoison -c "hidepadding"
-else
-ratpoison -c "showborder"
-ratpoison -c "showpadding"
-fi
diff --git a/ratpoison/bordtoggle b/ratpoison/bordtoggle
deleted file mode 100755
index 4b57c17..0000000
--- a/ratpoison/bordtoggle
+++ /dev/null
@@ -1,12 +0,0 @@
-#!/bin/sh
-# This shell script is PUBLIC DOMAIN. You may do whatever you want with it.
-
-TOGGLE=$HOME/.toggle
-
-if [ ! -e $TOGGLE ]; then
- touch $TOGGLE
- ratpoison -c "hideborder"
-else
- rm $TOGGLE
- ratpoison -c "showborder"
-fi
diff --git a/ratpoison/clipboard b/ratpoison/clipboard
deleted file mode 100755
index 15968b0..0000000
--- a/ratpoison/clipboard
+++ /dev/null
@@ -1,106 +0,0 @@
-#!/bin/bash
-#
-# Clipboard menu
-#
-# usage:
-# clipboard init - clear all buffers
-# clipboard menu_paste - pop up a menu to select which buffer to paste
-# clipboard menu_set - pop up a menu to select which buffer to save
-# the current X selection to
-# clipboard paste N - N is buffer 1-9
-# clipboard set N - N is buffer 1-9
-# clipboard push - stack/queue push (push to buffer 1)
-# clipboard pop - stack pop (last in first out - pop from buffer 1)
-# clipboard pop_queue - queue pop (first in first out - pop from top of stack)
-#
-# Current stack depth is held in slot 10, and slot 0 is used as temp space for
-# stack rotation.
-#
-command=$1
-option=$2
-source ~/.colors
-
-function entries() {
- # title entry
- if [ $command = menu_paste ]; then
- echo -n "\"Paste from slot:\" /bin/true "
- else
- echo -n "\"Yank to slot:\" /bin/true "
- fi
-
- for i in $(seq 1 9); do
- repr=$(xcb -p $i | tr '\n$*?"'\''' ' ' | cut --bytes 1-59)
- if [ $command = menu_paste ]; then
- cmd_item="$0 paste $i"
- else
- cmd_item="$0 set $i"
- fi
- #printf '%q %q ' $i "$repr" "$cmd_item"
-# echo -n "\"$i: $repr\" \"$cmd_item\" "
- echo -n "\"$i:$repr \" \"$cmd_item\" "
- done
-}
-
-function menu() {
- echo ~/.ratpoison/ratmenu -label "\"clipboard $command\"" \
- -style dreary -fg \"$COLOR11\" -bg \"$COLOR0\" -io 2 $(entries) | sh
-}
-
-function get_stack_depth() {
- stack_depth=$(xcb -p 10)
- echo "stack_depth=$stack_depth" >/dev/stderr
-}
-
-function set_stack_depth() {
- echo "setting stack_depth=$1" >/dev/stderr
- echo $1 | xcb -n 11 -s 10
-}
-
-function increment_stack_depth() {
- get_stack_depth
- set_stack_depth $[ $stack_depth + 1 ]
-}
-
-function decrement_stack_depth() {
- get_stack_depth
- set_stack_depth $[ $stack_depth - 1 ]
-}
-
-if [ $command = init ]; then
- # Clear all buffers
- xcb -n 10 -s 0-9 </dev/null
- set_stack_depth 0
-elif [ $command = menu_paste -o $command = menu_set ]; then
- menu
-elif [ $command = paste ]; then
- xcb -p $option | xclip
- ~/bin/paste
-
-elif [ $command = set ]; then
- xclip -o | xcb -n 10 -s $option
-elif [ $command = push ]; then
- get_stack_depth
- if [ $stack_depth -lt 9 ]; then
- xcb -n 10 -r 1
- $0 set 1
- increment_stack_depth
- fi
-elif [ $command = pop ]; then
- get_stack_depth
- if [ $stack_depth -gt 0 ]; then
- $0 paste 1
- # Clear buffer 0 so that rotation won't put its contents into spot 9
- xcb -n 10 -s 0 < /dev/null
- xcb -n 10 -r -1
- decrement_stack_depth
- fi
-elif [ $command = pop_queue ]; then
- get_stack_depth
- if [ $stack_depth -gt 0 ]; then
- $0 paste $stack_depth
- # Clear buffer at top of stack
- xcb -n 10 -s $stack_depth < /dev/null
- decrement_stack_depth
- fi
-fi
-
diff --git a/ratpoison/cmusplaying b/ratpoison/cmusplaying
deleted file mode 100755
index 133b6f9..0000000
--- a/ratpoison/cmusplaying
+++ /dev/null
@@ -1 +0,0 @@
-echo `cmus-remote -Q | awk '/ artist/ {$1=$2=""; print $0}'` - `cmus-remote -Q 2>/dev/null | grep title | awk '{$1=$2=""; print $0}'`
diff --git a/ratpoison/cmusvolind b/ratpoison/cmusvolind
deleted file mode 100755
index 0e95e1e..0000000
--- a/ratpoison/cmusvolind
+++ /dev/null
@@ -1,34 +0,0 @@
-#!/bin/bash
-volm=`cmus-remote -Q | awk '/vol_left/ {print $3}'`
-
-if [[ "$volm" -eq "100" ]]; then
- let volm=99
-fi
-
-echo M$volm
-bottom=`echo $volm | awk '{print int($1 * 0.2 + 0.5)}'`
-top=$((20-$bottom))
-
-
-
-echo -n -e "\xE2\x94\x8C"
-echo -n -e "\xE2\x94\x80"
-echo -e "\xE2\x94\x90"
-
-while [ $top -gt 0 ]; do
- echo -n -e "\xE2\x94\x82"
- echo -n \
- echo -e "\xE2\x94\x82"
- let top=$(($top-1))
-done
-
-while [ $bottom -gt 0 ]; do
- echo -n -e "\xE2\x94\x82"
- echo -n -e "\xE2\x96\x88"
- echo -e "\xE2\x94\x82"
-
- let bottom=$(($bottom-1))
-done
-echo -n -e "\xE2\x94\x94"
-echo -n -e "\xE2\x94\x80"
-echo -e "\xE2\x94\x98"
diff --git a/ratpoison/create_frame b/ratpoison/create_frame
deleted file mode 100755
index e39f7dc..0000000
--- a/ratpoison/create_frame
+++ /dev/null
Binary files differ
diff --git a/ratpoison/exec_to_workspace b/ratpoison/exec_to_workspace
deleted file mode 100755
index 8bacd78..0000000
--- a/ratpoison/exec_to_workspace
+++ /dev/null
@@ -1,12 +0,0 @@
-#!/usr/bin/env bash
-#
-# Wrapper to executute a shell command in the background followed by a change to a
-# workspace
-#
-# $1 - workspace to change to
-# $2+ - shell command
-
-wg=$1; shift
-cmd="$@"
-bspc desktop -f $wg &
-eval $cmd &
diff --git a/ratpoison/firesend b/ratpoison/firesend
deleted file mode 100755
index ddde2ef..0000000
--- a/ratpoison/firesend
+++ /dev/null
@@ -1,2 +0,0 @@
-#!/bin/bash
-$HOME/.ratpoison/exec_to_workspace 2 firefox --new-tab $@
diff --git a/ratpoison/functions b/ratpoison/functions
deleted file mode 100644
index fe9ab02..0000000
--- a/ratpoison/functions
+++ /dev/null
@@ -1,6 +0,0 @@
-#!/bin/bash
-
-function indent {
- echo ":: $*"
-}
-
diff --git a/ratpoison/mpdvolind b/ratpoison/mpdvolind
deleted file mode 100755
index c279af8..0000000
--- a/ratpoison/mpdvolind
+++ /dev/null
@@ -1,34 +0,0 @@
-#!/bin/bash
-volm=`mpc -h 127.0.0.1 volume | perl -pe 's/^volume://' | perl -pe 's/%$//' | perl -pe 's/^ //'`
-
-if [[ "$volm" -eq "100" ]]; then
- let volm=99
-fi
-
-echo M$volm
-bottom=`echo $volm | awk '{print int($1 * 0.2 + 0.5)}'`
-top=$((20-$bottom))
-
-
-
-echo -n -e "\xE2\x94\x8C"
-echo -n -e "\xE2\x94\x80"
-echo -e "\xE2\x94\x90"
-
-while [ $top -gt 0 ]; do
- echo -n -e "\xE2\x94\x82"
- echo -n \
- echo -e "\xE2\x94\x82"
- let top=$(($top-1))
-done
-
-while [ $bottom -gt 0 ]; do
- echo -n -e "\xE2\x94\x82"
- echo -n -e "\xE2\x96\x88"
- echo -e "\xE2\x94\x82"
-
- let bottom=$(($bottom-1))
-done
-echo -n -e "\xE2\x94\x94"
-echo -n -e "\xE2\x94\x80"
-echo -e "\xE2\x94\x98"
diff --git a/ratpoison/newtab b/ratpoison/newtab
deleted file mode 100755
index 8bdaf52..0000000
--- a/ratpoison/newtab
+++ /dev/null
@@ -1,2 +0,0 @@
-#!/bin/sh
-~/.ratpoison/exec_to_workspace 2 firefox -new-tab $1
diff --git a/ratpoison/panel/load b/ratpoison/panel/load
deleted file mode 100755
index 3977bee..0000000
--- a/ratpoison/panel/load
+++ /dev/null
@@ -1,7 +0,0 @@
-#!/bin/bash
-while true; do
-cpu=`mpstat -P ALL 2 1 | grep "Average.*all" | awk '{print $3+$5}'`
-mem=`free | grep Mem | awk '{print $3/$2 * 100.0}'`
-printf "C%.*f\n" 1 $cpu
-printf "R%.*f\n" 0 $mem
-done
diff --git a/ratpoison/panel/monce b/ratpoison/panel/monce
deleted file mode 100755
index caa316c..0000000
--- a/ratpoison/panel/monce
+++ /dev/null
@@ -1,25 +0,0 @@
-#!/bin/sh
-
-
-f=1
-d=30 # width
-
-new=`mpc current`
-if [ "$old" != "$new" ];then
-f=1;
-old="$new"
-fi
-
-
-e=$(expr $f + $d)
-
-if mpc | grep -q playing; then
-symbol='p'
-else
-symbol='P'
-fi
-
-echo "$symbol`echo $new | cut --bytes $f-$e`"
-echo "K`mpc -h 127.0.0.1 volume | perl -pe 's/^volume://' | perl -pe 's/%$//' | perl -pe 's/^ //'`"
-
-
diff --git a/ratpoison/panel/music b/ratpoison/panel/music
deleted file mode 100755
index 2fb91d1..0000000
--- a/ratpoison/panel/music
+++ /dev/null
@@ -1,20 +0,0 @@
-#!/bin/sh
-
-while true;do
-
-new=`mpc current`
-
-if mpc | grep -q playing; then
-symbol='p'
-else
-symbol='P'
-fi
-
-echo "$symbol`echo $new | cut --bytes 1-30`"
-echo "K`mpc -h 127.0.0.1 volume | perl -pe 's/^volume://' | perl -pe 's/%$//' | perl -pe 's/^ //'`"
-mpc idle > /dev/null
-if [ $? -ne 0 ];then
-echo 'mpd not alive';
-sleep 30;
-fi
-done
diff --git a/ratpoison/panel/panel b/ratpoison/panel/panel
deleted file mode 100755
index 2c68f94..0000000
--- a/ratpoison/panel/panel
+++ /dev/null
@@ -1,26 +0,0 @@
-#! /bin/sh
-cd ~/.ratpoison/panel
-source ./profile
-source ~/.colors
-
-[ -e "$PANEL_FIFO" ] && rm "$PANEL_FIFO"
-mkfifo "$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" &
-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" &
-
-
-source ./panel_colors
-
-cat "$PANEL_FIFO" | ./panel_bar | bar -g x$PANEL_HEIGHT -f "$PANEL_FONT_FAMILY" -F "$COLOR_FOREGROUND" -B "$COLOR_BACKGROUND" &
-
-sleep 1;
-stalonetray --geometry 4x1-1+1 --icon-gravity E --grow-gravity E -bg $COLOR0 -i 18 &
diff --git a/ratpoison/panel/panel_bar b/ratpoison/panel/panel_bar
deleted file mode 100755
index 0b2e55e..0000000
--- a/ratpoison/panel/panel_bar
+++ /dev/null
@@ -1,123 +0,0 @@
-#! /bin/sh
-#
-# Example panel for LemonBoy's bar
-
-
-num_mon=$(bspc query -M | wc -l)
-
-source ./panel_colors
-while read -r line ; do
- case $line in
- 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-}"
-# ;;
-
- p*)
- # playing mpc
- paused=''
- playing="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} p:${line#?} %{B-}%{F-}"
- ;;
-
- P*)
- # paused mpc
- playing=''
- paused="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} P:${line#?} %{B-}%{F-}"
- ;;
- K*)
- # volume output
- musicvol="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} M:${line#?} %{B-}%{F-}"
- ;;
-
-
- B*)
- # battery output
- battery="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} B:${line#?} %{B-}%{F-}"
- ;;
-
-
- V*)
- # volume output
- volume="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} V:${line#?} %{B-}%{F-}"
- ;;
-
- E*)
- # essid output
- if [ -z ${line#?} ];then
- essid="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} E:No WiFi %{B-}%{F-}"
- else
- essid="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} E:${line#?} %{B-}%{F-}"
- fi
- ;;
-
- Z*)
- # clock output
- time_infos="%{F$COLOR_STATUS_FG}%{B$COLOR_STATUS_BG} ${line#?} %{B-}%{F-}"
- ;;
- T*)
- # xtitle output
- title="%{F$COLOR_TITLE_FG}%{B$COLOR_TITLE_BG} ${line#?} %{B-}%{F-}"
- ;;
- W*)
- # bspwm internal state
- wm_infos=""
- IFS=':'
- set -- ${line#?}
- while [ $# -gt 0 ] ; do
- item=$1
- name=${item#?}
- case $item in
- M*)
- # active monitor
- if [ $num_mon -gt 1 ] ; then
- wm_infos="$wm_infos %{F$COLOR_FOCUSED_FG}%{B$COLOR_FOCUSED_BG} ${name} %{B-}%{F-} "
- fi
- ;;
-# m*)
-# # inactive monitor
-# if [ $num_mon -gt 1 ] ; then
-# wm_infos="$wm_infos %{F$COLOR_INACTIVE_MONITOR_FG}%{B$COLOR_INACTIVE_MONITOR_BG} ${name} %{B-}%{F-} "
-# fi
-# ;;
- O*)
- # focused occupied desktop
- wm_infos="${wm_infos}%{F$COLOR_FOCUSED_FG}%{B$COLOR_FOCUSED_BG}%{U$COLOR_FOREGROUND} ${name} %{-u}%{B-}%{F-}"
- ;;
- F*)
- # focused free desktop
- wm_infos="${wm_infos}%{F$COLOR_FOCUSED_FG}%{B$COLOR_FOCUSED_BG}%{U$COLOR_FOREGROUND} ${name} %{-u}%{B-}%{F-}"
- ;;
- U*)
- # focused urgent desktop
- wm_infos="${wm_infos}%{F$COLOR_FOCUSED_FG}%{B$COLOR_FOCUSED_BG}%{U$COLOR_FOREGROUND} ${name} %{-u}%{B-}%{F-}"
- ;;
-# o*)
-# # occupied desktop
-# wm_infos="${wm_infos}%{F$COLOR_OCCUPIED_FG}%{B$COLOR_OCCUPIED_BG} ${name} %{B-}%{F-}"
-# ;;
-# f*)
-# # free desktop
-# wm_infos="${wm_infos}%{F$COLOR_FREE_FG}%{B$COLOR_FREE_BG} ${name} %{B-}%{F-}"
-# ;;
-# u*)
-# # urgent desktop
-# wm_infos="${wm_infos}%{F$COLOR_URGENT_FG}%{B$COLOR_URGENT_BG} ${name} %{B-}%{F-}"
-# ;;
-# L*)
-# # layout
-# wm_infos="$wm_infos %{F$COLOR_LAYOUT_FG}%{B$COLOR_LAYOUT_BG} ${name} %{B-}%{F-}"
-# ;;
- esac
- shift
- done
- ;;
- 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} "
-done
diff --git a/ratpoison/panel/panel_colors b/ratpoison/panel/panel_colors
deleted file mode 100644
index f436113..0000000
--- a/ratpoison/panel/panel_colors
+++ /dev/null
@@ -1,33 +0,0 @@
-source ~/.colors
-
-
-COLOR_FOREGROUND="#FF`echo $COLOR11 | cut -c 2-`"
-COLOR_BACKGROUND="#FF`echo $COLOR0 | cut -c 2-`"
-COLOR_ACTIVE_MONITOR_FG='#FF34322E'
-COLOR_ACTIVE_MONITOR_BG='#FF58C5F1'
-COLOR_INACTIVE_MONITOR_FG='#FF58C5F1'
-COLOR_INACTIVE_MONITOR_BG='#FF34322E'
-COLOR_FOCUSED_OCCUPIED_FG='#FFF6F9FF'
-COLOR_FOCUSED_OCCUPIED_BG='#FF5C5955'
-COLOR_FOCUSED_FREE_FG='#FFF6F9FF'
-COLOR_FOCUSED_FREE_BG='#FF6D561C'
-COLOR_FOCUSED_URGENT_FG='#FF34322E'
-COLOR_FOCUSED_URGENT_BG='#FFF9A299'
-COLOR_OCCUPIED_FG='#FFA3A6AB'
-COLOR_OCCUPIED_BG='#FF34322E'
-COLOR_FREE_FG='#FF6F7277'
-COLOR_FREE_BG='#FF34322E'
-COLOR_URGENT_FG='#FFF9A299'
-COLOR_URGENT_BG='#FF34322E'
-COLOR_LAYOUT_FG='#FFA3A6AB'
-COLOR_LAYOUT_BG='#FF34322E'
-
-
-COLOR_FOCUSED_FG="#FF`echo $COLOR10 | cut -c 2-`"
-COLOR_FOCUSED_BG="#FF`echo $COLOR0 | cut -c 2-`"
-
-COLOR_TITLE_FG="#FF`echo $COLOR11 | cut -c 2-`"
-COLOR_TITLE_BG="#FF`echo $COLOR0 | cut -c 2-`"
-
-COLOR_STATUS_FG="#FF`echo $COLOR12 | cut -c 2-`"
-COLOR_STATUS_BG="#FF`echo $COLOR0 | cut -c 2-`"
diff --git a/ratpoison/panel/profile b/ratpoison/panel/profile
deleted file mode 100644
index c7a3ba0..0000000
--- a/ratpoison/panel/profile
+++ /dev/null
@@ -1,4 +0,0 @@
-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
diff --git a/ratpoison/panel/signal b/ratpoison/panel/signal
deleted file mode 100755
index d494f5d..0000000
--- a/ratpoison/panel/signal
+++ /dev/null
@@ -1,19 +0,0 @@
-#!/bin/bash
-while true;do
-signal=`iwconfig $INTERFACE | grep Signal| perl -pe 's/.*level=//; s/ dBm.*//'`
-#convert to Quality
-
- if [ $signal -le -100 ];then
- quality=0;
- elif [ $signal -ge -50 ];then
- quality=100;
- elif [ -z $signal ];then
- quality=0;
- else
- quality=$(( 2 * ( $signal + 100 )));
- fi
-
-echo "S$quality";
-sleep 3;
-done
-
diff --git a/ratpoison/paneltoggle b/ratpoison/paneltoggle
deleted file mode 100755
index 5e665bb..0000000
--- a/ratpoison/paneltoggle
+++ /dev/null
@@ -1,12 +0,0 @@
-#!/bin/sh
-# This shell script is PUBLIC DOMAIN. You may do whatever you want with it.
-
-TOGGLE=$HOME/.toggle
-
-if [ ! -e $TOGGLE ]; then
- touch $TOGGLE
- ratpoison -c hidepanel
-else
- rm $TOGGLE
- ratpoison -c showpanel
-fi
diff --git a/ratpoison/py/color_detect.py b/ratpoison/py/color_detect.py
deleted file mode 100644
index 30661f8..0000000
--- a/ratpoison/py/color_detect.py
+++ /dev/null
@@ -1,108 +0,0 @@
-import sys
-import colorsys
-from colorz import colorz
-from math import sqrt
-
-try:
- import Image
-except ImportError:
- from PIL import Image
-
-if len(sys.argv) < 2:
- print "Usage: {0} FILENAME [num_colors]".format(sys.argv[0])
- sys.exit()
-
-
-print sys.argv[1]
-
-WALLPAPER = sys.argv[1]
-filename = WALLPAPER.split('/').pop()
-COLORS = ".{0}.colors".format(filename)
-XRESOURCES = ".{0}.Xres".format(filename)
-SAMPLE = ".{0}.sample.png".format(filename)
-
-cols = ''
-xres = ''
-
-def torgb(hexv):
- hexv = hexv[1:]
- r, g, b = (
- int(hexv[0:2], 16) / 256.0,
- int(hexv[2:4], 16) / 256.0,
- int(hexv[4:6], 16) / 256.0,
- )
- return r, g, b
-
-def normalize(hexv, minv=128, maxv=256):
- r, g, b = torgb(hexv)
- h, s, v = colorsys.rgb_to_hsv(r, g, b)
- minv = minv / 256.0
- maxv = maxv / 256.0
- if v < minv:
- v = minv
- if v > maxv:
- v = maxv
- r, g, b = colorsys.hsv_to_rgb(h, s, v)
- return '#{:02x}{:02x}{:02x}'.format(int(r * 256), int(g * 256), int(b * 256))
-
-def darkness(hexv):
- r, g, b = torgb(hexv)
- darkness = sqrt((255 - r) ** 2 + (255 - g) ** 2 + (255 - b) ** 2)
- return darkness
-
-def to_hsv(c):
- r, g, b = torgb(c)
- h, s, v = colorsys.rgb_to_hsv(r, g, b)
- return h, s, v
-
-def hex_color_to_rgb(color):
- color = color[1:] if color[0]=="#" else color
- return (
- int(color[:2], 16),
- int(color[2:4], 16),
- int(color[4:], 16)
- )
-
-def create_sample(f, colors):
- im = Image.new("RGB", (1000, 100), "white")
- pix = im.load()
-
- width_sample = im.size[0]/len(colors)
-
- for i, c in enumerate(colors):
- for j in range(width_sample*i, width_sample*i+width_sample):
- for k in range(0, 100):
- pix[j, k] = hex_color_to_rgb(c)
-
- im.save(f)
-
-if __name__ == '__main__':
- if len(sys.argv) == 2:
- n = 16
- else:
- n = int(sys.argv[2])
-
-
- i = 0
- # sort by value, saturation, then hue
- colors = colorz(WALLPAPER, n=n)
- colors.sort(key=lambda x:darkness(x), reverse=True)
- for c in colors:
- if i == 0:
- c = normalize(c, minv=0, maxv=32)
- elif i == 8:
- c = normalize(c, minv=128, maxv=192)
- elif i < 8:
- c = normalize(c, minv=160, maxv=224)
- else:
- c = normalize(c, minv=200, maxv=256)
- c = normalize(c, minv=32, maxv=224)
- xres += """*color{}: {}\n""".format(i, c)
- cols += """export COLOR{}="{}"\n""".format(i, c)
- i += 1
-
- create_sample(SAMPLE, colors)
- with open(XRESOURCES, 'w') as f:
- f.write(xres)
- with open(COLORS, 'w') as f:
- f.write(cols)
diff --git a/ratpoison/py/colorz.py b/ratpoison/py/colorz.py
deleted file mode 100644
index 8c00f0c..0000000
--- a/ratpoison/py/colorz.py
+++ /dev/null
@@ -1,71 +0,0 @@
-from collections import namedtuple
-from math import sqrt
-import random
-try:
- import Image
-except ImportError:
- from PIL import Image
-
-Point = namedtuple('Point', ('coords', 'n', 'ct'))
-Cluster = namedtuple('Cluster', ('points', 'center', 'n'))
-
-def get_points(img):
- points = []
- w, h = img.size
- for count, color in img.getcolors(w * h):
- points.append(Point(color, 3, count))
- return points
-
-rtoh = lambda rgb: '#%s' % ''.join(('%02x' % p for p in rgb))
-
-def colorz(filename, n=3):
- img = Image.open(filename)
- img.thumbnail((200, 200))
- w, h = img.size
-
- points = get_points(img)
- clusters = kmeans(points, n, 1)
- rgbs = [map(int, c.center.coords) for c in clusters]
- return map(rtoh, rgbs)
-
-def euclidean(p1, p2):
- return sqrt(sum([
- (p1.coords[i] - p2.coords[i]) ** 2 for i in range(p1.n)
- ]))
-
-def calculate_center(points, n):
- vals = [0.0 for i in range(n)]
- plen = 0
- for p in points:
- plen += p.ct
- for i in range(n):
- vals[i] += (p.coords[i] * p.ct)
- return Point([(v / plen) for v in vals], n, 1)
-
-def kmeans(points, k, min_diff):
- clusters = [Cluster([p], p, p.n) for p in random.sample(points, k)]
-
- while 1:
- plists = [[] for i in range(k)]
-
- for p in points:
- smallest_distance = float('Inf')
- for i in range(k):
- distance = euclidean(p, clusters[i].center)
- if distance < smallest_distance:
- smallest_distance = distance
- idx = i
- plists[idx].append(p)
-
- diff = 0
- for i in range(k):
- old = clusters[i]
- center = calculate_center(plists[i], old.n)
- new = Cluster(plists[i], center, old.n)
- clusters[i] = new
- diff = max(diff, euclidean(old.center, new.center))
-
- if diff < min_diff:
- break
-
- return clusters
diff --git a/ratpoison/ratcolor b/ratpoison/ratcolor
deleted file mode 100755
index 97cd406..0000000
--- a/ratpoison/ratcolor
+++ /dev/null
@@ -1,7 +0,0 @@
-#!/bin/bash
-source ~/.colors
-ratpoison -c "set bgcolor $COLOR0"
-ratpoison -c "set bwcolor $COLOR0"
-ratpoison -c "set fgcolor $COLOR11"
-ratpoison -c "set fwcolor $COLOR11"
-
diff --git a/ratpoison/ratmenu b/ratpoison/ratmenu
deleted file mode 100755
index d8ec195..0000000
--- a/ratpoison/ratmenu
+++ /dev/null
Binary files differ
diff --git a/ratpoison/ratpoisonrc.clipboard b/ratpoison/ratpoisonrc.clipboard
deleted file mode 100644
index dd4bc29..0000000
--- a/ratpoison/ratpoisonrc.clipboard
+++ /dev/null
@@ -1,57 +0,0 @@
-# Use xcb to build a better cut and paste clipboard.
-#
-# C-t y # - paste selection buffer # (and sets the current X PRIMARY selection to it)
-# C-t p # - set selection buffer # using current X PRIMARY selection
-
-# C-t y a - pop selection (treat buffers as a stack with 1 being the bottom)
-# C-t y q - pop selection (queue pop)
-# C-t p a - push selection (treat buffers as a stack with 1 being the bottom)
-
-# C-t y y - paste selection menu
-# C-t p p - set selection menu
-
-# C-t p C - clear all buffers
-
-# change directory to $HOME
-chdir
-
-newkmap clipboard_paste
-newkmap clipboard_set
-exec ~/.ratpoison/clipboard init
-
-bind p readkey clipboard_paste
-bind y readkey clipboard_set
-
-# Menu version of paste and set
-definekey clipboard_paste p exec ~/.ratpoison/clipboard menu_paste
-definekey clipboard_set y exec ~/.ratpoison/clipboard menu_set
-
-# Clear buffers
-definekey clipboard_set C exec ~/.ratpoison/clipboard init
-
-# Push/pop
-definekey clipboard_paste a exec ~/.ratpoison/clipboard pop
-definekey clipboard_set a exec ~/.ratpoison/clipboard push
-# pop queue
-definekey clipboard_paste q exec ~/.ratpoison/clipboard pop_queue
-
-definekey clipboard_paste 1 exec ~/.ratpoison/clipboard paste 1
-definekey clipboard_paste 2 exec ~/.ratpoison/clipboard paste 2
-definekey clipboard_paste 3 exec ~/.ratpoison/clipboard paste 3
-definekey clipboard_paste 4 exec ~/.ratpoison/clipboard paste 4
-definekey clipboard_paste 5 exec ~/.ratpoison/clipboard paste 5
-definekey clipboard_paste 6 exec ~/.ratpoison/clipboard paste 6
-definekey clipboard_paste 7 exec ~/.ratpoison/clipboard paste 7
-definekey clipboard_paste 8 exec ~/.ratpoison/clipboard paste 8
-definekey clipboard_paste 9 exec ~/.ratpoison/clipboard paste 9
-
-definekey clipboard_set 1 exec ~/.ratpoison/clipboard set 1
-definekey clipboard_set 2 exec ~/.ratpoison/clipboard set 2
-definekey clipboard_set 3 exec ~/.ratpoison/clipboard set 3
-definekey clipboard_set 4 exec ~/.ratpoison/clipboard set 4
-definekey clipboard_set 5 exec ~/.ratpoison/clipboard set 5
-definekey clipboard_set 6 exec ~/.ratpoison/clipboard set 6
-definekey clipboard_set 7 exec ~/.ratpoison/clipboard set 7
-definekey clipboard_set 8 exec ~/.ratpoison/clipboard set 8
-definekey clipboard_set 9 exec ~/.ratpoison/clipboard set 9
-
diff --git a/ratpoison/ratpoisonrc.conf b/ratpoison/ratpoisonrc.conf
deleted file mode 100644
index f46677e..0000000
--- a/ratpoison/ratpoisonrc.conf
+++ /dev/null
@@ -1,350 +0,0 @@
-# info: C=control, M=meta/alt, s=super, S=shift, H = Hyper
-# xnest for testing
-escape grave
-definekey top s-grave meta
-definekey top Arabic_dammatan meta
-
-#unmanage Nautilus Desktop
-unmanage Desktop
-
-#find files script
-bind f exec ~/.ratpoison/spotlight
-
-# set font with unicode support
-#set font -*-terminus-medium-r-normal-*-14-*-*-*-*-*-*-*
-set font "DejaVu Sans Mono"
-
-#Style message box
-set bgcolour #fdf6e3
-set fgcolor #657b83
-
-# Enable xcb copy/paste
-source .ratpoison/ratpoisonrc.clipboard
-
-# Make tab switch to the next screen
-bind Tab nextscreen
-
-#have windows centered
-set wingravity center
-
-# Use the name of the program rather than the title in the window list
-set winname title
-
-#Pest control.
-banish
-#exec unclutter -idle 1 -jitter 2 -root
-#warp on
-#addhook switchwin banish
-
-#No more startup message
-startup_message off
-
-#fix mouse
-exec xsetroot -cursor_name left_ptr
-
-#Effects & Background
-#exec xcompmgr -c -f &
-
-#exec nitrogen --restore
-
-#Border & Padding
-alias showpadding set padding 10 10 10 10
-alias hidepadding set padding 0 0 0 0
-showpadding
-
-barinpadding 0
-alias showborder set border 3
-alias hideborder set border 0
-showborder
-
-set fwcolor #657b83
-set bwcolor #839496
-
-######################################
-# Panel
-######################################
-alias rpbarsend exec ~/.ratpoison/rpbarsend
-
-# tell ratpoison to ignore rpbar
-unmanage rpbar
-
-# hooks
-#addhook switchwin rpbarsend
-#addhook switchframe rpbarsend
-#addhook switchgroup rpbarsend
-#addhook deletewindow rpbarsend
-## RP versions >= 1.4.6 (from the git repo) have these hooks.
-## Recommended!
-#addhook titlechanged rpbarsend
-#addhook newwindow rpbarsend
-
-unmanage conky
-unmanage xfce4-panel
-unmanage ratbar.pl
-alias showpanel set padding 0 27 0 0
-alias hidepanel set padding 0 0 0 0
-#showpanel
-#-------------------------------------------------------------
-# Workspaces
-#-------------------------------------------------------------
-
-
-# Switcher window
-alias workspace_menu exec .ratpoison/workspace_menu
-bind W workspace_menu
-
-
-#Get F-keys to switch windows now in /usr/bin/rpws
-definekey top F1 exec rpws 1 #&& ratpoison -c bordscript
-definekey top F2 exec rpws 2 #&& ratpoison -c bordscript
-definekey top F3 exec rpws 3
-definekey top F4 exec rpws 4 #&& ratpoison -c bordscript
-definekey top F5 exec rpws 5 #&& ratpoison -c bordscript
-definekey top F6 exec rpws 6 #&& ratpoison -c bordscript
-definekey top F7 exec rpws 7 #&& ratpoison -c bordscript
-definekey top F8 exec rpws 8 #&& ratpoison -c bordscript
-definekey top F9 exec rpws 9 #&& ratpoison -c bordscript
-definekey top F10 exec xset -led 3 & exec ratpoison -c "exec rpws 10"
-definekey top F11 exec rpws 11 #3&& ratpoison -c bordscript
-definekey top F12 exec rpws 12 #3&& ratpoison -c bordscript
-
-definekey top M-F1 rpwsm1
-definekey top M-F2 rpwsm2
-definekey top M-F3 rpwsm3
-definekey top M-F4 rpwsm4
-definekey top M-F5 rpwsm5
-definekey top M-F6 rpwsm6
-definekey top M-F7 rpwsm7
-definekey top M-F8 rpwsm8
-definekey top M-F9 rpwsm9
-definekey top M-F10 rpwsm10
-definekey top M-F11 rpwsm11
-definekey top M-F12 rpwsm12
-
-definekey top S-F1 exec rpws 13
-definekey top S-F2 exec rpws 14
-definekey top S-F3 exec rpws 15
-definekey top S-F4 exec rpws 16
-definekey top S-F5 exec rpws 17
-definekey top S-F6 exec rpws 18
-definekey top S-F7 exec rpws 19
-definekey top S-F8 exec rpws 20
-definekey top S-F9 exec rpws 21
-definekey top S-F10 exec rpws 22
-definekey top S-F11 exec rpws 23
-definekey top S-F12 exec rpws 24
-
-#definekey top s-F1 exec ratpoison -c 'meta F1'
-#definekey top s-F2 exec ratpoison -c 'meta F2'
-#definekey top s-F3 exec ratpoison -c 'meta F3'
-#definekey top s-F4 exec ratpoison -c 'meta F4'
-#definekey top s-F5 exec ratpoison -c 'meta F5'
-#definekey top s-F6 exec ratpoison -c 'meta F6'
-#definekey top s-F7 exec ratpoison -c 'meta F7'
-#definekey top s-F8 exec ratpoison -c 'meta F8'
-#definekey top s-F9 exec ratpoison -c 'meta F9'
-#definekey top s-F10 exec ratpoison -c 'meta F10'
-#definekey top s-F11 exec ratpoison -c 'meta F11'
-#definekey top s-F12 exec ratpoison -c 'meta F12'
-
-
-
-definekey top S-F12 exec rpws 13
-definekey top M-S-F12 rpwsm13
-
-
-#-------------------------------------------------------------
-#Bindings
-#-------------------------------------------------------------
-
-alias window_menu exec .ratpoison/window_menu
-
-bind h focusleft
-bind l focusright
-bind j focusdown
-bind k focusup
-bind H exchangeleft
-bind L exchangeright
-bind J exchangedown
-bind K exchangeup
-
-bind w window_menu
-bind a title
-bind t time
-definekey top s-l exec i3lock -n -i ~/.wallpaper.png
-definekey top s-s exec ~/bin/sus
-definekey top s-L redisplay
-bind C exec ~/.ratpoison/wp change
-bind v hsplit
-bind V hsplit 2/3
-bind s vsplit
-bind S vsplit 2/3
-bind d remove
-bind space exec urxvt
-bind o only
-bind semicolon colon
-bind e exec
-bind u undo
-bind x delete
-bind X kill
-bind Escape abort
-bind m exec xfce4-popup-applicationsmenu
-
-#Paste goodness
-bind g exec ~/bin/imgur
-bind P exec xclip -o | curl -F 'sprunge=<-' http://sprunge.us | xclip
-
-
-alias bordtoggle exec ~/.ratpoison/bordtoggle
-alias bordscript exec ~/.ratpoison/borderscript
-alias paneltoggle exec ~/.ratpoison/paneltoggle
-
-
-
-
-#addhook key bordscript
-
-definekey top s-b bordtoggle
-definekey top s-p paneltoggle
-
-
-
-# b : Open url
-alias browse_cmd exec .ratpoison/exec_to_workspace 2 firefox -new-tab
-alias browse colon browse_cmd
-bind b browse
-# B : open a new firefox tab and browse to the X clipboard selection
-alias browse_selection exec .ratpoison/exec_to_workspace 2 firefox -new-tab `ratpoison -c getsel`
-bind B browse_selection
-
-# Paste with X selection
-alias insert_X_selection meta S-Insert
-bind i insert_X_selection
-
-
-#-------------------------------------------------------------
-#Application Shortcuts
-#-------------------------------------------------------------
-
-definekey top s-f exec firefox
-definekey top s-u exec uzbl-browser
-definekey top s-m exec /home/vasko/.ratpoison/pentfocus
-definekey top s-v exec vlc
-definekey top s-g exec gvim
-#definekey top s-l exec libreoffice
-
-#-----------------------------------------------------
-# Voice control
-#-----------------------------------------------------
-definekey top KP_Enter exec ~/Dropbox/speech/run-duplex.sh
-
-#-------------------------------------------------------------
-# Volume Control
-#-------------------------------------------------------------
-# Up
-alias volup exec amixer -q set Master 5+ && ratpoison -c "echo `$HOME/.ratpoison/volind`"
-
-defivhave`havhave`nekey top XF86AudioRaiseVolume volup
-definekey top s-Prior volup
-
-# Down
-alias voldown exec amixer -q set Master 5- && ratpoison -c "echo `$HOME/.ratpoison/volind`"
-
-definekey top XF86AudioLowerVolume voldown
-definekey top s-Next voldown
-
-# Mute
-alias voltoggle exec amixer -D pulse set Master toggle && ratpoison -c "echo Sound: `amixer get Master|awk '/Mono:/ {print $6}'`"
-
-definekey top XF86AudioMute voltoggle
-definekey top s-Pause voltoggle
-
-#-------------------------------------------------------------
-# Brightness Control
-#-------------------------------------------------------------
-alias brightup exec xbacklight -inc 10
-alias brightdown exec xbacklight -dec 2
-
-definekey top XF86MonBrightnessUp brightup
-definekey top XF86MonBrightnessDown brightdown
-
-#-------------------------------------------------------------
-# Cmus (Music) Control
-#-------------------------------------------------------------
-# Aliases
-alias playinfo exec ratpoison -c "echo Music: `mpc -h 127.0.0.1 | head -2 | tail -1 | awk '{print $1}'`"
-alias volinfo exec ratpoison -c "echo `$HOME/.ratpoison/mpdvolind`"
-alias songinfo exec ratpoison -c "echo Music: `mpc -h 127.0.0.1 | head -1`"
-#alias volinfo exec ratpoison -c "echo `$HOME/.ratpoison/cmusvolind`"
-#alias playinfo exec ratpoison -c "echo Music: `cmus-remote -Q | awk '/status/ {print $2}'`"
-#alias songinfo exec ratpoison -c "echo Playing:`cmus-remote -Q | awk '/ artist/ {$1=$2=""; print $0}'` - `cmus-remote -Q 2>/dev/null | grep title | awk '{$1=$2=""; print $0}'`"
-
-
-# Play/Pause and Volume
-definekey top s-space exec mpc -h 127.0.0.1 toggle && ratpoison -c 'playinfo'
-definekey top s-Right exec mpc -h 127.0.0.1 next && ratpoison -c "songinfo"
-definekey top s-Left exec mpc -h 127.0.0.1 prev && ratpoison -c "songinfo"
-definekey top s-Up exec mpc -h 127.0.0.1 volume +5 && ratopison -c "volinfo"
-definekey top s-Up exec mpc -h 127.0.0.1 volume +5 && ratpoison -c 'volinfo'
-definekey top s-Down exec mpc -h 127.0.0.1 volume -5 && ratpoison -c 'volinfo'
-
-# Old cmus controls
-#definekey top s-space exec cmus-remote -u && ratpoison -c "playinfo"
-#definekey top s-Right exec cmus-remote -n && ratpoison -c "songinfo"
-#definekey top s-Left exec cmus-remote -r && ratpoison -c "songinfo"
-#definekey top s-Up exec cmus-remote -v +5% && ratpoison -c "volinfo"
-#definekey top s-Down exec cmus-remote -v -5% && ratpoison -c "volinfo"
-
-# Show song that is playing
-definekey top Print songinfo
-
-#-------------------------------------------------------------
-# Unbindings
-#-------------------------------------------------------------
-unbind Q
-unbind C-A
-unbind C-a
-unbind C-p
-unbind C-apostrophe
-unbind C-i
-unbind C-Return
-unbind C-n
-unbind C-m
-unbind C-c
-unbind C-k
-unbind C-l
-unbind C-K
-unbind C-exclam
-unbind C-grave
-unbind C-u
-unbind C-g
-unbind C-space
-unbind C-v
-unbind C-s
-unbind C-Right
-unbind C-Up
-unbind C-Down
-unbind C-x
-unbind C-f
-unbind C-V
-unbind C-S
-unbind C-w
-unbind C-b
-#-------------------------------------------------------------
-# Layout saving
-#-------------------------------------------------------------
-
-# bind M-! to store the current frame layout in slot #1
-bind M-exclam exec ratpoison -c "setenv fs1 `ratpoison -c 'fdump'`"
-
-#bind M-1 to restore the frame layout in slot #1
-bind M-1 exec ratpoison -c "frestore `ratpoison -c 'getenv fs1'`"
-
-# Do the same for slot #2 and bind it to M-@ and M-2, respectively.
-bind M-at exec ratpoison -c "setenv fs2 `ratpoison -c 'fdump'`"
-bind M-2 exec ratpoison -c "frestore `ratpoison -c 'getenv fs2'`"
-
-# Give ourselves another slot on M-# and M-3, respectively.
-bind M-numbersign exec ratpoison -c "setenv fs3 `ratpoison -c 'fdump'`"
-bind M-3 exec ratpoison -c "frestore `ratpoison -c 'getenv fs3'`"
-
diff --git a/ratpoison/rpbar b/ratpoison/rpbar
deleted file mode 100755
index 3b90f35..0000000
--- a/ratpoison/rpbar
+++ /dev/null
Binary files differ
diff --git a/ratpoison/rpbaro b/ratpoison/rpbaro
deleted file mode 100755
index cb4b1f0..0000000
--- a/ratpoison/rpbaro
+++ /dev/null
Binary files differ
diff --git a/ratpoison/rpbarsend b/ratpoison/rpbarsend
deleted file mode 100755
index e1b7b05..0000000
--- a/ratpoison/rpbarsend
+++ /dev/null
Binary files differ
diff --git a/ratpoison/screen_run b/ratpoison/screen_run
deleted file mode 100755
index 07ba780..0000000
--- a/ratpoison/screen_run
+++ /dev/null
@@ -1,21 +0,0 @@
-#!/usr/bin/env bash
-#
-# Connect to a named screen session if it exists, otherwise create it
-# If creating a new screen session, use the file screenrc.$session
-# in the .ratpoison directory.
-#
-screen_dir=$HOME/.ratpoison
-session=$1
-function die() {
- echo "$0 error: $*"
- exit 1
-}
-[ $# -ne 1 ] && die "$0 requires 1 argument (screen session name)"
-if screen -ls | grep $session; then
- # This session exists, connect to it
- screen -r $session
-else
- session_config=$screen_dir/screenrc.$session
- [ -f $session_config ] || die "config ($session_config) not found for $session"
- screen -c $screen_dir/screenrc.$session -S $session
-fi
diff --git a/ratpoison/screenout b/ratpoison/screenout
deleted file mode 100755
index 6687b44..0000000
--- a/ratpoison/screenout
+++ /dev/null
@@ -1,2 +0,0 @@
-#!/bin/sh
-cat /tmp/screen-exchange | xclip
diff --git a/ratpoison/screenrc b/ratpoison/screenrc
deleted file mode 100644
index 7917907..0000000
--- a/ratpoison/screenrc
+++ /dev/null
@@ -1,34 +0,0 @@
-#escape \\m
-defscrollback 5000
-vbell off
-startup_message off
-altscreen on
-
-
-#multiuser
-multiuser on
-acladd vasko
-
-# look and feel
-#caption always "%{= bb}%{+b w}%n %h %=%t %c"
-caption always "%{= bb}%{+b w}%n %{+b y}%H %=%{+b w}%t %c"
-hardstatus alwayslastline "%-Lw%{= BW}%50>%n%f* %t%{-}%+Lw%<"
-
-activity "Activity in %t(%n)"
-
-# bind keys
-bind 'l' lastmsg
-bind 'q' meta
-bind ' ' screen
-bind 'a' title
-bind 'h' split -h
-bind 'v' split -v
-bind 'x' remove
-bind 'o' only
-bind 'r' resize
-
-# bind buffer
-bufferfile
-bind b eval writebuf "exec !!! $HOME/.ratpoison/screenout"
-
-
diff --git a/ratpoison/screenrc.admin b/ratpoison/screenrc.admin
deleted file mode 100644
index dc60e36..0000000
--- a/ratpoison/screenrc.admin
+++ /dev/null
@@ -1,20 +0,0 @@
-# change to home directory and source screenrc from ratpoison directory
-chdir
-source .ratpoison/screenrc
-
-screen -t Admin0 0
-screen -t Admin1 1
-screen -t Admin2 2
-screen -t Admin3 3
-screen -t Admin4 4
-screen -t Root0 5
-select 5
-exec su
-screen -t Root1 6
-select 6
-exec su
-screen -t Root2 7
-select 7
-exec su
-
-select 0
diff --git a/ratpoison/screenrc.irssi b/ratpoison/screenrc.irssi
deleted file mode 100644
index 0be6047..0000000
--- a/ratpoison/screenrc.irssi
+++ /dev/null
@@ -1,6 +0,0 @@
-# change to home directory and source screenrc from ratpoison directory
-chdir
-source .ratpoison/screenrcnobar
-
-screen -t Irc 0
-exec irssi
diff --git a/ratpoison/screenrc.mutt b/ratpoison/screenrc.mutt
deleted file mode 100644
index 338dc05..0000000
--- a/ratpoison/screenrc.mutt
+++ /dev/null
@@ -1,6 +0,0 @@
-# change to home directory and source screenrc from ratpoison directory
-chdir
-source .ratpoison/screenrcnobar
-
-screen -t Mail 0
-exec mutt
diff --git a/ratpoison/screenrc.projects b/ratpoison/screenrc.projects
deleted file mode 100644
index 6850687..0000000
--- a/ratpoison/screenrc.projects
+++ /dev/null
@@ -1,11 +0,0 @@
-# change to home directory and source screenrc from ratpoison directory
-chdir
-source .ratpoison/screenrc
-
-screen -t Projects1 0
-screen -t Projects1 1
-screen -t Projects2 2
-screen -t Projects3 3
-screen -t Projects4 4
-
-select 1
diff --git a/ratpoison/screenrc.school b/ratpoison/screenrc.school
deleted file mode 100644
index ef0df42..0000000
--- a/ratpoison/screenrc.school
+++ /dev/null
@@ -1,19 +0,0 @@
-# change to home directory and source screenrc from ratpoison directory
-chdir
-source .ratpoison/screenrc
-
-screen -t Calculator 0
-exec qalc
-screen -t Math 1
-exec vim $HOME/Dropbox/Notes/math.txt
-screen -t English 2
-exec vim $HOME/Dropbox/Notes/english.txt
-screen -t Physics 3
-exec vim $HOME/Dropbox/Notes/physics.txt
-screen -t Chemistry 4
-exec vim $HOME/Dropbox/Notes/chemistry.txt
-screen -t Biology 4
-exec vim $HOME/Dropbox/Notes/biology.txt
-screen -t Arbitrary 5
-exec vim $HOME/Dropbox/Notes/random.txt
-select 0
diff --git a/ratpoison/screenrcnobar b/ratpoison/screenrcnobar
deleted file mode 100644
index 57fccbf..0000000
--- a/ratpoison/screenrcnobar
+++ /dev/null
@@ -1,29 +0,0 @@
-#escape \\m
-defscrollback 5000
-vbell off
-startup_message off
-altscreen on
-
-#multiuser
-multiuser on
-acladd vasko
-
-# look and feel
-
-activity "Activity in %t(%n)"
-
-# bind keys
-bind 'l' lastmsg
-bind 'q' meta
-bind ' ' screen
-bind 'a' title
-bind 'h' split -h
-bind 'v' split -v
-bind 'x' remove
-bind 'o' only
-bind 'r' resize
-
-# bind buffer
-bind b eval writebuf "exec !!! $HOME/.ratpoison/screenout"
-
-
diff --git a/ratpoison/spotlight b/ratpoison/spotlight
deleted file mode 100755
index 24cdc87..0000000
--- a/ratpoison/spotlight
+++ /dev/null
@@ -1,4 +0,0 @@
-#!/bin/sh
-source ~/.colors
-locate ~/ | dmenu -i -l 20 -sb $COLOR0 -nb $COLOR0 -nf $COLOR11 -sf $COLOR3 | xargs urxvt -e rifle -p0
-exit 0
diff --git a/ratpoison/taskbar b/ratpoison/taskbar
deleted file mode 100755
index 46bb43f..0000000
--- a/ratpoison/taskbar
+++ /dev/null
@@ -1,2 +0,0 @@
-#!/bin/sh
-echo "`rpws current`} | `ratpoison -c "windows" | awk '{printf "%s | ",$0} END {print ""}'`"
diff --git a/ratpoison/time b/ratpoison/time
deleted file mode 100755
index 4e3cbfc..0000000
--- a/ratpoison/time
+++ /dev/null
@@ -1,7 +0,0 @@
-#!/bin/bash
-for i in {1..5}
-do
- ratpoison -c "echo `ratpoison -c "time"`"
- sleep 1
-done
-ratpoison -c "echo ` `"
diff --git a/ratpoison/volind b/ratpoison/volind
deleted file mode 100755
index c562ef6..0000000
--- a/ratpoison/volind
+++ /dev/null
@@ -1,32 +0,0 @@
-#!/bin/bash
-volm=`amixer get Master|awk '/Mono:/ {print $4}'| awk '{print substr($0, 2, length() - 3)}'`
-bottom=`echo $volm | awk '{print int($1 * 0.2 + 0.5)}'`
-top=$((20-$bottom))
-
-if [[ "$volm" -eq "100" ]]; then
- let volm=99
-fi
-
-
-echo G$volm
-echo -n -e "\xE2\x94\x8C"
-echo -n -e "\xE2\x94\x80"
-echo -e "\xE2\x94\x90"
-
-while [ $top -gt 0 ]; do
- echo -n -e "\xE2\x94\x82"
- echo -n \
- echo -e "\xE2\x94\x82"
- let top=$(($top-1))
-done
-
-while [ $bottom -gt 0 ]; do
- echo -n -e "\xE2\x94\x82"
- echo -n -e "\xE2\x96\x88"
- echo -e "\xE2\x94\x82"
-
- let bottom=$(($bottom-1))
-done
-echo -n -e "\xE2\x94\x94"
-echo -n -e "\xE2\x94\x80"
-echo -e "\xE2\x94\x98"
diff --git a/ratpoison/window_menu b/ratpoison/window_menu
deleted file mode 100755
index 416ee12..0000000
--- a/ratpoison/window_menu
+++ /dev/null
@@ -1,40 +0,0 @@
-#!/usr/bin/env bash
-
-# Lets you switch between all windows in a way that minimizes keystrokes.
-
-# Two ways to order:
-# - If order=last, the windows are listed in the order that you last visited them in.
-# - If order=sequential, the windows are listed in number order.
-order=sequential
-ratmenu="~/.ratpoison/ratmenu"
-
-source ~/.colors
-
-# Yes, bash is really necessary, because it's version of printf makes this
-# script possible. Regular bourne shell printf does NOT.
-
-window_index_str=$(ratpoison -c "info" | sed 's/^.*\([0-9]\)(.*$/\1/')
-if [ "$window_index_str" = "No window." ]; then
- group_index=$($HOME/.ratpoison/workspace current)
- $ratmenu -style dreary -fg \"$COLOR0\" -bg \"$COLOR0\" "No windows in group $group_index"
-/bin/true
-else
- ratpoison -c "echo $window_index_str"
- echo "$window_index_str">/tmp/log
- window_index=$[ $window_index_str + 1 ]
- if [ $order = sequential ]; then
- ( printf "$ratmenu -style dreary -fg \"$COLOR11\" -bg \"$COLOR0\" -io $window_index \
- ";
- ratpoison -c "windows %n %n %t" | sort -n | while read w x z; do
- a=$(printf "%3q" $x); b="ratpoison -c \"select $x\"";
- printf " %q\\ %q %q" "$a" "$z" "$b";
- done; echo \;) | sh
- elif [ $order = last ]; then
- ( printf "$ratmenu -style dreary -fg \"$COLOR11\" -bg \"$COLOR0\" -io $window_index \
- ";
- ratpoison -c "windows %l %n %t" | sort -rn | while read w x z; do
- a=$(printf "%3q" $x); b="ratpoison -c \"select $x\"";
- printf " %q\\ %q %q" "$a" "$z" "$b";
- done; echo \;) | sh
- fi
-fi
diff --git a/ratpoison/workspace_menu b/ratpoison/workspace_menu
deleted file mode 100755
index dc3b723..0000000
--- a/ratpoison/workspace_menu
+++ /dev/null
@@ -1,24 +0,0 @@
-#!/usr/bin/env bash
-
-# Lets you switch between all workspaces in a way that minimizes keystrokes.
-# The current workspace is selected.
-
-# Yes, bash is really necessary, because it's version of printf makes this
-# script possible. Regular bourne shell printf does NOT.
-
-workspace_command="/usr/bin/rpws"
-ratmenu="~/.ratpoison/ratmenu"
-
-( printf "$ratmenu -style dreary -fg \"$COLOR11\" -bg \"$COLOR0\" -io $[ $($workspace_command current) + 1 ]";
- ratpoison -c "groups" | while read s; do
- n=$(echo $s | sed 's/\([0-9]\+\).*/\1/');
-# w=$(echo $s | sed 's/[0-9]\+.\(.*\)/\1/');
- w=$(ratpoison -c "gselect $(($n-1))" -c "windows %t" -c "gprev")
- a=$(printf "%3q %q" $n $w); b="$workspace_command $n";
- if [ $n -ne 0 ];then
- printf " %q %q" "$a" "$b";
- else
- printf " %q %q" "Go to workspace:" "/bin/true";
- fi
- done; echo \;) | sh
-
diff --git a/ratpoison/wp b/ratpoison/wp
deleted file mode 100755
index 072cf77..0000000
--- a/ratpoison/wp
+++ /dev/null
@@ -1,257 +0,0 @@
-#!/bin/bash
-
-function main {
-
- # Snippet from SO user Dave Dopson http://stackoverflow.com/questions/59895/can-a-bash-script-tell-what-directory-its-stored-in
- SOURCE="${BASH_SOURCE[0]}"
- # resolve $SOURCE until the file is no longer a symlink
- while [ -h "$SOURCE" ]; do
- DIR="$( cd -P "$( dirname "$SOURCE" )" && pwd )"
- SOURCE="$(readlink "$SOURCE")"
- # if $SOURCE was a relative symlink, we need to resolve it
- # relative to the path where the symlink file was located
- [[ $SOURCE != /* ]] && SOURCE="$DIR/$SOURCE"
- done
- DIR="$( cd -P "$( dirname "$SOURCE" )" && pwd )"
- K_MEANS=16
- WALLPAPER_DIR=${WALLPAPER_DIR:-~/.wallpapers/}
-
- while test $# -gt 0; do
- case "$1" in
- usage | -h | --help)
- shift
- usage
- ;;
- n | -n)
- shift
- K_MEANS=$1
- shift
- ;;
- add | -a | --add)
- shift
- add $*
- ;;
- rm | remove | -rm | --remove)
- shift
- remove $*
- ;;
- change)
- shift
- change $*
- ;;
- current)
- shift
- current $*
- ;;
- ls | list | -l | --list)
- shift
- list $*
- ;;
- colors)
- shift
- colors
- ;;
- slideshow)
- shift
- slideshow $*
- ;;
- *)
- shift
- indent "$1 is not a recognised directive"
- ;;
- esac
- done
-}
-
-#:: Prety print function
-function indent {
- echo ":: $*"
-}
-
-#:: Confirm user input
-function confirm {
- indent $1
- read -sn 1 ans
- case "$ans" in
- y|Y|yes|YES|Yes) return 0 ;;
- *) return 1 ;;
- esac
-}
-
-#:: Directives
-
-function add {
- if [ 0 = $# ]; then
- indent "No file argument provided"
- exit 1
- fi
-
- files=$*
-
- for file in $files; do
- if [ ! -f $file ]; then
- indent "File '$file' doesn't exist"
- exit 1
- fi
- done
-
- cp $files $WALLPAPER_DIR
- cd $WALLPAPER_DIR
-
- for file in $*; do
- echo ":: Generating .$file.colors and .$file.Xres in $PWD"
- python2 $DIR/py/color_detect.py $file $K_MEANS
- done
-}
-
-function remove {
- if [ 0 = $# ]; then
- if confirm "Delete current background? [Y/n]"; then
- remove $(basename $(get_current))
- else
- echo "exiting"
- exit 1
- fi
- fi
-
- for file in $*; do
- indent "Removing $file"
- rm ${WALLPAPER_DIR}/${file}
- rm ${WALLPAPER_DIR}/.${file}.{colors,Xres}
- done
-}
-
-function change {
- #:: Select a random background from WALLPAPER_DIR, or use the passed background
- if [ -z $1 ]; then
- background=$(find $WALLPAPER_DIR -type f \( ! -iname ".*" \) | shuf -n1)
- else
- background=$WALLPAPER_DIR/$1
-
- if [ ! -f $background ]; then
- indent "$1 does not exist in $WALLPAPER_DIR"
- exit 1
- fi
- fi
-
- if [ -f ${background}.Xres ] || [ -f ${background}.colors ]; then
- indent "Could not find ${background}.Xres or ${background}.colors"
- exit 1
- fi
-
- filename=$(basename $background)
- dirname=$(dirname $background)
-
- #:: Set the background
- feh --bg-fill $background
-
- #:: Record the current background
- set_current $background
-
- if [ $? -ne 0 ]; then
- indent "Failed to set $background as background"
- else
- indent "Set $background as background"
-
- #:: Set the colorscheme
- ln -f ${dirname}/.${filename}.colors ~/.colors
- xrdb -merge ${dirname}/.${filename}.Xres
- fi
-}
-
-function slideshow {
- if [ -z $2 ]; then
- PAPERS=$(list)
- elif [ -e $2 ]; then
- PAPERS=$(cat $2)
- else
- PAPERS=$2
- fi
-
- for img in $PAPERS; do
- change $img
- if [ ! -z "$1" ]; then
- /bin/bash -c "$1"
- fi
- sleep 7
- done
-}
-
-function current {
- indent $(get_current)
-}
-
-function get_current {
- readlink -f $WALLPAPER_DIR/.current
-}
-
-function set_current {
- ln -sf $1 $WALLPAPER_DIR/.current
-}
-
-function list {
- ls $* $WALLPAPER_DIR
-}
-
-function colors {
- # Original: http://frexx.de/xterm-256-notes/
- # http://frexx.de/xterm-256-notes/data/colortable16.sh
- # Modified by Aaron Griffin
- # and further by Kazuo Teramoto
- FGNAMES=(' black ' ' red ' ' green ' ' yellow' ' blue ' 'magenta' ' cyan ' ' white ')
- BGNAMES=('DFT' 'BLK' 'RED' 'GRN' 'YEL' 'BLU' 'MAG' 'CYN' 'WHT')
-
- echo " ┌──────────────────────────────────────────────────────────────────────────┐"
- for b in {0..8}; do
- ((b>0)) && bg=$((b+39))
-
- echo -en "\033[0m ${BGNAMES[b]} │ "
-
- for f in {0..7}; do
- echo -en "\033[${bg}m\033[$((f+30))m ${FGNAMES[f]} "
- done
-
- echo -en "\033[0m │"
- echo -en "\033[0m\n\033[0m │ "
-
- for f in {0..7}; do
- echo -en "\033[${bg}m\033[1;$((f+30))m ${FGNAMES[f]} "
- done
-
- echo -en "\033[0m │"
- echo -e "\033[0m"
-
- ((b<8)) &&
- echo " ├──────────────────────────────────────────────────────────────────────────┤"
- done
- echo " └──────────────────────────────────────────────────────────────────────────┘"
-}
-
-function usage {
- printf "%b" " $0 [action] [options]
-
-Actions
-- usage: Print this help message.
-- n [number] : Number of colors to gather.
-- add [file]...: Add file, or files, to the wallpaper database.
-- rm [file]...: Remove file, or files, from the wallpaper database.
-- change [file]: Set the wallpaper to file, or a random wallpaper
- from the wallpaper database.
-- slideshow [cmd file]: Rotate through wallpapers, optionally
- running cmd each time and using only
- wallpapers listed in the file.
-- current: List the current background
-- ls: List all wallpapers in the database.
-- colors: Display the current set of colors.
-"
-}
-
-#:: End function declaration, begin executing
-main $*
-~/.config/bspwm/colors
-pkill panel
-pkill stalone
-~/bin/panel & disown
-source ~/.colors
-#convert -font DejaVuSansB -pointsize 30 -stroke $COLOR0 -strokewidth 1 -fill $COLOR11 -draw 'text 70,60 "Vasil Zlatanov -> +46 723537981 vasil.zlatanov@gmail.com" ' $background ~/.wallpaper.png &
-convert $background ~/.wallpaper.png &
diff --git a/ratpoison/xtoolwait b/ratpoison/xtoolwait
deleted file mode 100755
index 6d07668..0000000
--- a/ratpoison/xtoolwait
+++ /dev/null
Binary files differ