]> git.deb.at Git - debienna.git/blob - SebastianBachmann/Screenrc/index.mdwn
fix whitespace
[debienna.git] / SebastianBachmann / Screenrc / index.mdwn
1
2 .screenrc:
3 [[!format txt """
4 backtick 1 0 10   /usr/bin/cpu-screen
5 backtick 2 0 30   /usr/bin/ip-screen
6 backtick 3 0 5    /usr/local/bin/bat_state.pyc
7 backtick 4 0 5    /usr/local/bin/meminfo.pyc
8
9 # Wich screen windows should start
10 screen -t top 0 nice top
11 screen -t irssi 1 nice irssi
12 screen 2 zsh
13 # Local in META Screen by lefant
14 # screen -t localhost 1 screen -S local -d -RR
15
16 # use %n to display the window number and %t for its title:
17   activity              "activity in %n (%t) [%w:%s]~"
18
19 # pass on the "beep" (CTRL-G) by adding a '~':
20   bell                  "bell     in %n (%t) [%w:%s]~"
21
22 # pow_detach_msg:       Message shown when session
23   pow_detach_msg "Screen session of \$LOGNAME \$:cr:\$:nl:ended."
24
25 # vbell_msg:            Message shown when the
26   vbell_msg             " *beep* "
27
28
29 defutf8               on
30 login                 off
31 deflogin              off
32 startup_message       off
33 vbell                 on
34 bell_msg        'Bell in %n'
35
36 termcapinfo xterm*|linux*|rxvt*|Eterm* OP
37
38 defscrollback         1000
39 #hardcopydir           ~/.screen
40 hardcopy_append       on
41 shell                 zsh
42
43 hardstatus alwayslastline
44 #caption always "%{wk}%?%-Lw%?%{kW}%n*%f %t%?(%u)%?%{wk}%?%+Lw"
45 caption always "%{b k}[ %{r}$USER@%{b}%H %{b}]%{w}[ %1` ]%{C}[ %4` ]%{B}[%= %2` %= ]%-62=%{Y}[ %{Y}%l ]%{b}[ %3` ]%{g}[ %0c ]%{w}[ %D %d.%m.%Y ]"
46 hardstatus string "%{g}%=%?%-Lw%?%{=b kR}(%{W}%n*%f %t%?(%u)%?%{=b kR})%{= kw}%?%+Lw%?%?%=%{g}"
47
48 sorendition 10 99 # default!
49
50 #idle 600 eval "screen cmatrix -o -f -u 9 -C red -s" "idle 0"
51
52 #usefull binds
53   bind 'K' kill
54   bind 'I' login on
55   bind 'O' login off
56   bind '}' history
57   bind Q quit
58   bind G screen -t 'google'    w3m www.google.com
59   bind H screen -t HeiseTicker w3m www.heise.de/newsticker/pda/data/paket4.html
60   bind X lockscreen
61 """]]
62 /usr/local/bin/bat_info.py (compile with py_compilefiles)
63 [[!format txt """
64 import re
65 import string
66
67 state = open("/proc/acpi/battery/BAT0/state","r").readlines()
68 info = open("/proc/acpi/battery/BAT0/info","r").readlines()
69
70
71 aktuell = string.join(re.findall("[0-9]", state[4]), '')
72 design = string.join(re.findall("[0-9]", info[1]), '')
73 full = string.join(re.findall("[0-9]", info[2]), '')
74
75 aktuell = float(aktuell)
76 design = float(design)
77 full = float(full)
78 print "%.2f | %.2f" %((100/(design/aktuell)), (100/(design/full)))
79 """]]
80 /usr/local/bin/meminfo.py
81 [[!format txt """
82 import re
83 import string
84
85 mem = open("/proc/meminfo","r").readlines()
86
87 all = float(string.join(re.findall("[0-9]",mem[0]), ''))/1048576
88 free = float(string.join(re.findall("[0-9]",mem[1]), ''))/1048576
89 swapall = float(string.join(re.findall("[0-9]",mem[11]), ''))/1048576
90 swapfree = float(string.join(re.findall("[0-9]",mem[12]), ''))/1048576
91
92 print "%.2f/%.2f | %.2f/%.2f" %(free,all,swapfree,swapall)
93 """]]
94 Get your ip-screen and cpu-screen from GRML!