Latest entries

Xscreensaver theming

Xscreensaver theming

In my humble opinion, xscreensaver is quite ugly. Even worse, xscreensaver doesn't support theming, without recompiling. Jamie Zawinski, the main developer, provides and explanation for his design decision.

Anyways, by adding some lines to ~/.Xresources, it is at least possible to change some colors and fonts.

The above screenshot had the following settings in ~/.Xresources: xscreensaver.splash: false

!font settings
xscreensaver.Dialog.headingFont:        -*-dina-bold-r-*-*-12-*-*-*-*-*-*-*
xscreensaver.Dialog.bodyFont:           -*-dina-medium-r-*-*-12-*-*-*-*-*-*-*
xscreensaver.Dialog.labelFont:          -*-dina-medium-r-*-*-12-*-*-*-*-*-*-*
xscreensaver.Dialog.unameFont:          -*-dina-medium-r-*-*-12-*-*-*-*-*-*-*
xscreensaver.Dialog.buttonFont:         -*-dina-bold-r-*-*-12-*-*-*-*-*-*-*
xscreensaver.Dialog.dateFont:           -*-dina-medium-r-*-*-12-*-*-*-*-*-*-*
xscreensaver.passwd.passwdFont:         -*-dina-bold-r-*-*-12-*-*-*-*-*-*-*

!general dialog box (affects ...

Read more »

vim: automatically chmod+x for files with shebang

Adding this to your .vimrc automatically sets the execution mode-bit when editing files beginning with shebang #! and a path containing bin

" automatically give executable permissions if file begins with #! and contains '/bin/' in the path
" see http://www.debian-administration.org/articles/571
" modified 23.12.2008 Benedikt Stegmaier <dev _at_ bstegmaier _dot_ de>
"
function MakeScriptExecuteable()
    if getline(1) =~ "^#!.*/bin/"
        silent !chmod +x <afile>
    endif
endfunction

au BufWritePost * call MakeScriptExecuteable()

After a file's permission have changed, vim will ask you what to do... Hit L to reload the file.

W16: Warning: Mode of file "myscript.sh" has changed since editing ...

Read more »

Getting ssl/tls fingerprints for fetchmailrc

Getting ssl/tls fingerprints for fetchmailrc

Using a secure connections, fetchmail compares the fingerprint of the server's certificate with one specified in the configuration file. If those fingerprints do not match, the connection will fail with:

fetchmail: $SERVER fingerprints do not match! fetchmail: SSL connection failed.

So, what's the fastest way to get the server's certificate and fingerprint? Just use

openssl s_client -connect $SERVER:$PORT -showcerts | openssl x509 -fingerprint -noout -md5

replacing $SERVER and $PORT with the appropriate values.

The first command opens a ssl or tls connection to the respective server and prints its certificate. The second command calculates an MD5-fingerprint of ...

Read more »

Yearly archives