Topic: HOWTO: Basic Ratpoison (rp) Configuration
HOWTO: Ratpoison (rp) Basic Configuration
This howto is based on the fine blog article written by Dione Moult. Please read it.
http://thinkmoult.com/2009/05/13/ratpoi
malist-wm/
I use #! Wheezy, here's my /apt/sources:
SOURCES LIST
## DEBIAN
deb http://ftp.ca.debian.org/debian/ testing main contrib non-free
deb-src http://ftp.ca.debian.org/debian/ testing main contrib non-free
## DEBIAN SECURITY
deb http://security.debian.org/ testing/updates main
deb-src http://security.debian.org/ testing/updates main
## Multimedia
deb http://www.debian-multimedia.org testing main non-free
#Testing Proposed Updates
deb http://ftp.debian.org/debian/ testing-proposed-updates main contrib non-free
deb-src http://ftp.debian.org/debian/ testing-proposed-updates main contrib non-freeSUDO
I also edited the /etc/sudoers file:
# This file MUST be edited with the 'visudo' command as root.
#
# Please consider adding local content in /etc/sudoers.d/ instead of
# directly modifying this file.
#
# See the man page for details on how to write a sudoers file.
#
Defaults env_reset
# Host alias specification
# User alias specification
# Cmnd alias specification
# User privilege specification
root ALL=(ALL:ALL) ALL
# Allow members of group sudo to execute any command
#%sudo ALL=(ALL:ALL) ALL
#includedir /etc/sudoers.d
macondo ALL = NOPASSWD : ALL
giovi ALL = NOPASSWD: /sbin/halt, /sbin/rebootNow i don't need a password to sudo (a matter of choice)
BIND KEY
Following the article's instructions, i created the file: .xmodmaprc
$ touch .xmodmaprcAnd then added these lines (save/exit)
remove lock = Caps_Lock
keycode 66 = F13Now the bind key is the Caps_lock instead of Ctrl+t
GDM
I try to keep it simple, no DMs, i only use Linux, no Windows. I get rid of gdm:
$ sudo dpkg -P gdm gdm-themesThen i edit the /etc/inittab and leave it like this:
# The default runlevel.
id:2:initdefault:Also the # of ttys, i only need 2:
1:2345:respawn:/sbin/getty 38400 tty1
2:23:respawn:/sbin/getty 38400 tty2
#3:23:respawn:/sbin/getty 38400 tty3
#4:23:respawn:/sbin/getty 38400 tty4
#5:23:respawn:/sbin/getty 38400 tty5
#6:23:respawn:/sbin/getty 38400 tty6I create a .xinitrc in order to boot rp when i'm back from rebooting:
$ touch .xinitrcThen add these lines to it:
#!/bin/sh
setxkbmap -option terminate:ctrl_alt_bksp
xsetroot -solid black
xrdb -merge .Xdefaults
unclutter -idle 2 &
numlockx &
xmodmap .xmodmaprc
conky &
ratpoisonCONKY
I create the .conkyrc file:
$ touch .conkyrcThen copy/paste the following lines:
alignment top_left
background no
border_width 1
cpu_avg_samples 2
default_color white
default_outline_color white
default_shade_color white
draw_borders no
draw_graph_borders yes
draw_outline no
draw_shades no
use_xft yes
xftfont Terminus :size=10
gap_x 22
gap_y 2
minimum_size 5 5
net_avg_samples 2
no_buffers yes
out_to_console no
out_to_stderr no
extra_newline no
own_window no
own_window_class Conky
own_window_type desktop
stippled_borders 0
update_interval 1.0
uppercase no
use_spacer none
show_graph_scale no
show_graph_range no
TEXT
${color green}RAM:$color $memperc${color lightgrey}% ${color green}Swap:$color $swapperc${color lightgrey}% ${color green}Processes:$color $running_processes${color lightgrey}/ $color$processes ${color green}CPU: $color$cpu${color lightgrey}% ${color yellow} ${time %a.%d.%m.%Y %R}RATPOISON CONFIG
I create the file .ratpoisonrc
$ touch .ratpoisonrcThen i enter it:
$ nano -w .ratpoisonrcAnd paste this:
alias term exec xterm
escape F13
exec xrdb -merge "$HOME"/.Xdefaults
warp off
startup_message off
set winname class
defborder 0
set padding 0 14 0 0
defbarpadding 0 0
exec xsetroot -solid black -cursor_name left_ptr
bind semicolon colon
set bargravity sw
set winfmt %n %s %t
set fgcolor yellow
set bgcolor black
set font "Terminus-12"
alias showroot exec ratpoison -c fdump; ratpoison -c 'select -' -c only
alias unshowroot exec ratpoison -c "frestore at $HOME/.rpfdump"
### Escritorios virtuales/Workspaces
exec rpws 1
exec /usr/bin/rpws init 6 -k
## bind = F13
bind F1 exec rpws 1
bind F2 exec rpws 2
bind F3 exec rpws 3
#Focus
bind J exchangedown
bind K exchangeup
bind L exchangeright
bind H exchangeleft
bind j focusdown
bind l focusright
bind h focusleft
##Alt-tab
definekey top M-Tab next
definekey top M-ISO_Left_Tab prev
### Atajos de teclas/Keybindings
bind e exec xfe
bind f exec iceweasel
bind m exec sylpheed
bind u exec xchat
bind l exec leafpad
bind r restart
bind Pause exec sudo /sbin/shutdown -h now
bind w windows
bind space exec xterm
bind k kill
bind Escape abort
bind o only
rudeness 13
## Las teclas de de la fila de arriba no precisan de bind (F13)
# Para lanzar un Run box/To launch a Run box (Ctrl+Space bar):
definekey top C-space exec
# Para hacer un screenshot/To make a screenshot (Press the Print key)
definekey top Print exec xterm -e scrot -cd 10
# Sound Volume
bind KP_Multiply exec amixer set Master 5%+
bind KP_Divide exec amixer set Master 5%-Now i reboot, when i comeback i'm in the console, type my username (Enter), my user password (Enter) and then type startx (Enter)
and you should be in with rp.
Press the Cap_lock key (bind key) with your pinky, an X will appear on the screen and then i press f key and iceweasel will come up if that's what you installed, otherwise, chromium.
To shut off rp press bind + Pause key.
To close an applicatin, bind key + k,
alt-tab works as always,
press the Print key to take a snapshot,
Ctrl key + Space bar will give you a run box to launch an application,
bind + spacebar will launch the terminal,
bind + s key will split the screen in two horizontally,
bind + S, splits the screen vertically.
To go back to an undivided screen: bind+ o
To go to a different workspace: bind + F2,F3,F4,F5,F6
To see the windows you got open: bind + w
To go to a specific window: bind + window #
Just play with it
Ratpoison is really easy on ram usage (3 mb), my desktop uses an Atom processor, 1 gig of ram, the hd is 160 gigs, and the monitor is an old Samsung crt.
Ratpoison is not for everybody, is not pretty, there are no frills, just speed. The object of the game is speed, to keep your hands on the keyboard, by the time you grab the mouse and look for that icon, i'm already in like Flynn, it took me a day playing with it to master it ![]()
Your wrists will be grateful.
EDIT 07May11
I forgot to mention that if you want the debian menu, just press the bind key + period (.)
Last edited by macondo123 (2011-05-18 12:06:23)
Minimal Squeeze || icewm/fluxbox/ratpoison
KISS = Keep It Simple, Stupid