thorko.deLinux / Unix systems administrator

GitHub Projects

buildserver Build Status Coverage Status

Latest SysadminDB entries


KDE Plasma - Autstart applications

In KDE Plasma you need to place a .desktop file in ~/.config/autostart

The specs for that can be found here


If that doesn't work place a script in ~/.config/plasma-workspace/env and make it executable

GPG cheatsheet

Sign and encrypt file with specific key

gpg -e -r <recipient> -u <id of signing key> --sign -o <output file> <file>
gpg -e -r -u 4A9C0FC09269797E706BB5A6D53E9087CA40E908 --sign -o test.gpg test

Export public key

gpg --armor --output <YOUR-KEY>.asc --export <YOUR-KEY-ID>
gpg --armor --output test.asc --export 4A9C0FC09269797E706BB5A6D53E9087CA40E908

Export secret key

gpg --armor --output <YOUR-SECRET>.asc --export-secret-keys <YOUR-KEY-ID>
gpg --armor --output test-sec.asc --export-secret-keys 4A9C0FC09269797E706BB5A6D53E9087CA40E908

Set special character on keys

First you need to figure out which keycode the key uses when you press it. To do so you start xev and type the key

KeyPress event, serial 40, synthetic NO, window 0x5c00001,
root 0xe7, subw 0x0, time 42471470, (1095,-519), root:(1095,250),
state 0x10, keycode 49 (keysym 0x5e, asciicircum), same_screen YES,
XLookupString gives 1 bytes: (5e) "^"
XmbLookupString gives 1 bytes: (5e) "^"
XFilterEvent returns: False

now create a file calles ~/.Xmodmap

keycode 49 = asciicircum

Owncloud - server replied: Locked

When getting the error message "the file is locked" you need to do the following steps to resolve this issue

~$ occ maintenance:mode --on
mysql> DELETE FROM oc_file_locks WHERE 1;
~$ occ maintenance:mode --off

Git usage

set global settings for git

git config --global "Mark Wallberg"
git config --global ""

use password file

# create a .netrc file in your home
login mark
password lm@te

checkout a single file (sparse-checkout)

git clone -n && cd script
git config core.sparsecheckout true
echo trunk/file > .git/info/sparse-checkout
git read-tree -m -u HEAD

Initialize Git repository for apache

git --bare init
git update-server-info

(c) 2014 by