blog · git · desktop · images · contact & privacy · gopher
~/.*rc
So, hier stopfe ich mal alles "Unkategorisierte" rein: .virc, .screenrc und sowas. Im Klartext die ganzen kleinen "Tricks" und "Tweaks", damit ich sie nicht jedesmal neu suchen muss. ;) Über Ergänzungen oder Korrekturen würde ich mich natürlich immer freuen. :)
alias l='ls -al --si --color=auto'
# bissel aufgeräumter und mit check des letzten rückgabewertes
PS1='\[\033[0m\]\[\033[32m\]<\A>\[\033[01;33m\] \w \[\033[22m\]$(if [[ $? == "0" ]]; then echo -e "\[\033[32m\]"; else echo -e "\[\033[31m\]"; fi)\$\[\033[0m\] '
# für's zusammenspiel mit newmail dieser alias:
alias mutt='mutt && touch ~/Mail/cache.*'
# tab completion bei sudo:
complete -cf sudo
# pfad krams:
export PATH=$PATH:/opt/java/jre/bin:/opt/texlive/bin
export CLASSPATH=$CLASSPATH:.
# titlebar des terminals!
case $TERM in
xterm | rxvt-* | screen)
export PROMPT_COMMAND='echo -ne "\033]0;${PWD/$HOME/~}\007"'
;;
esac
# history
export HISTFILESIZE=1000 # the bash history should save 3000 commands
export HISTCONTROL=ignoredups #don't put duplicate lines in the history.
alias hist='history | grep $1' #Requires one input
# kein screen blanking an vc's
setterm -blank 0
# fetchmail - es kümmert sich selbst drum, dass es nur einmal läuft
fetchmail -d 300 >/dev/null 2>&1
hardstatus on
hardstatus string "%?%h%:%t%?"
defhstatus ""
termcapinfo xterm|screen|rxvt-unicode 'hs:ts=\E]2;:fs=\007:ds=\E]0;screen\007'
vbell off
shell -${SHELL}
Immer einen schönen Titel im Terminal setzen, visual bell aus ...
" Zeilennummern:
set number
" Gescheites Einrücken/Umbrechen
set ai tabstop=4 sw=4
set wrap
set formatoptions=l
set linebreak
set t_Co=8
Nicht viel, ist nämlich bei Arch schon gut voreingestellt. Aber auch diese Datei wächst mit der Zeit ein bisschen ... :)
# -----------------------
# rxvt-unicode, allgemein
URxvt*saveLines: 10000
URxvt*scrollBar: false
URxvt*foreground: grey
# für echte transparenz mit compositing:
URxvt.depth: 32
URxvt.background: rgba:0000/0000/0000/f9f9
URxvt*secondaryScroll: true
URxvt*font: xft:Terminus:pixelsize=21
URxvt*cursorBlink: true
URxvt*cursorUnderline: true
# rxvt-unicode, url catcher
URxvt*perl-ext-common: default,matcher
URxvt*matcher.button: 3
URxvt*urlLauncher: firefox
# rxvt-unicode, colors ...
URxvt*foreground: #A8A8A8
URxvt*color0: rgba:0000/0000/0000/f9f9
URxvt*color1: #A80000
URxvt*color2: #00A800
URxvt*color3: #A85400
URxvt*color4: #0000A8
URxvt*color5: #A800A8
URxvt*color6: #00A8A8
URxvt*color7: #A8A8A8
URxvt*color8: #545054
URxvt*color9: #F85450
URxvt*color10: #50FC50
URxvt*color11: #EDFC00
URxvt*color12: #5054F8
URxvt*color13: #F854F8
URxvt*color14: #50FCF8
URxvt*color15: #F8FCF8
urlCommand "firefox '%s'"
psFile "|psnup -2 | xfprint4 -"
initialZoom page
Auszug, nur die Farben und Tweaks. Für den Rest siehe vorherige News.
#########
# COLORS!
# - Mails und Header -
color header brightgreen black ^From:
color header brightyellow black ^Subject:
color header brightcyan black ^To:
color header brightcyan black ^Cc:
color header red black ^User-Agent:
color attachment black brightred
# - Index -
color index brightyellow black ~N # new message
color index yellow black ~O # old unread message
color index red black ~D # deleted message
color indicator black green
# - Quote-Levels -
color quoted cyan black
color quoted1 yellow black
color quoted2 red black
color quoted3 green black
color quoted4 cyan black
color quoted5 yellow black
color quoted6 red black
color quoted7 green black
# - Misc -
color markers brightcyan black # wrap marker
###############
# Kleine Tweaks
set include=ask-yes # ask whether to cite a mail when replying
set fast_reply # nicht jedesmal *alles* nachfragen
set sort=date # in umgekehrter reihenfolge im index anzeigen
set hidden_host=yes # kein "mobil..." da reintun...
set mime_forward=yes # attachments forwarden statt quote
set mime_forward_rest=yes
#set index_format = "%4C %Z %{%b %d} %-15.15L (%?l?%4l&%4c?) %s"
set index_format = "%4C %Z [%{%y-%m-%d %H:%M}] %-15.15L (%?l?%4l&%4c?) %s"
######################
# Adressbuch mit abook
# hierzu separat "abook" installieren. am To:-Prompt von mutt
# dann STRG+T drücken, um das adressbuch zu durchsuchen
set query_command = "abook --mutt-query"
######
# News
set news_server = "news.mein-hauptserver.de"
set newsrc = "~/.mutt/newsrc-%s" # name des newsservers mit rein, um kollisionen zu vermeiden
# hotkeys:
macro generic "<esc>q" ":set news_server=news.mein-hauptserver.de"
macro generic "<esc>w" ":set news_server=news.mein-zweiter-server.de"
macro generic "<esc>y" ":set sort=date"
macro generic "<esc>x" ":set sort=threads"
Für die "Multimedia Tasten" des Dell Inspiron 6400.
# vol up
"amixer set Master 2dB+ unmute"
m:0x10 + c:176
# vol dn
"amixer set Master 2dB- unmute"
m:0x10 + c:174
# vol mute
"amixer set Master toggle"
m:0x10 + c:160
# run audacious - it's the "MediaDirect" hotkey
"audacious"
m:0x0 + c:237
## --- Wrapper-Script for various players
# play/pause
"playercontrol.sh 0"
m:0x0 + c:162
# rewind
"playercontrol.sh 2"
m:0x0 + c:144
# next
"playercontrol.sh 3"
m:0x0 + c:153
# stop
"playercontrol.sh 1"
m:0x0 + c:164
Im Zweifelsfalle befrage man hierzu "xbindkeys -mk". Passend dazu das
Script playercontrol.sh
:
#!/bin/bash
PLAYERS="cmus audacious"
# order: 0 = play/pause, 1 = stop, 2 = prev, 3 = next
CTRLS_cmus=("cmus-remote -u" "cmus-remote -s" "cmus-remote -r" "cmus-remote -n")
CTRLS_audacious=("audacious --play-pause" "audacious -s" "audacious -r" "audacious -f")
for i in $PLAYERS
do
pgrep $i 2>&1 > /dev/null
if (( $? == 0 ))
then
# quick and dirty via eval ...
eval \${CTRLS_$i[$1]}
fi
done
Minimale Config, z.B. für pcmanfm unter pekwm:
style "Sans"
{
font_name = "Bitstream Vera Sans 10"
}
widget_class "*" style "Sans"
gtk-font-name = "Bitstream Vera Sans 10"
gtk-icon-theme-name = "Rodent"
gtk-theme-name = "Xfce"