blob: 6381b42190ca8a45782a2cf82d48e77ce1eae810 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
|
#!/usr/bin/env bash
#
# Ratpoison window manager utility.
#
# Parameters
BASENAME="`basename $0`"
ACTION="$1"
# Dispatch
if [ -z "$ACTION" ]; then
echo "usage: $BASENAME <action>"
exit 1
elif [ "$ACTION" == "workspaces" ]; then
# Spawn rpws
rpws init 9 -k -a
# Sleep, giving time for rpws to start properly
sleep 2
# Apply a workaround to display a window after rpws is initialized
ratpoison -c 'prev'
ratpoison -c 'next'
elif [ "$ACTION" == "custom" ]; then
# Sources a custom ratpoisonrc file, if present
if [ -e "$HOME/.custom/ratpoisonrc" ]; then
ratpoison -c "source $HOME/.custom/ratpoisonrc"
fi
fi
|