Kill process by name (or: what pkill already does)

Whenever I wanted to terminate a program by force I used ps -A | grep PROGNAME, read the process id and then executed sudo kill PID. Now I wrote a one line bash script making things easier — reducing the required effort by half:

sudo kill `ps -A | grep $1 | grep -Eo '[0-9]{3,4}'`

Also usable as a one line command which requires one to enter the program's name afterwards:

read x;sudo kill `ps -A | grep $x | grep -Eo '[0-9]{3,4}'`

The first version, however, is much more convenient. I stored it as nkill in /usr/bin/ which enables me to for example kill firefox with nkill firefox or kill all open terminals with nkill xterm.

Update: Uhm ... yeah ... I just learned that pkill does just that. :D

tags: linux


Proper subsequent loading of content

On today's schedule:
light exercises in JavaScript, regular expressions and Vim. :D

I finally managed to grant my Elfen Lied content base a proper functionality to load content on demand. The full page contains images worth >60MB. Combined with slow speed due to free webspace you end up with a browsing experience of pure "meh ...". Until now I only hid collapsed content and displayed it on demand. Now expanding and collapsing really means loading the content and removing it. Not only hiding and displaying while loading it anyway.

tags: website


Arch and Wacom

Arch Linux! Wacom! W00t! <3 :D

Okay ... one thing at a time ... After a good year of using Ubuntu I now switched to Arch Linux. The reason being that I'll be forced to build a system fitting to my needs.
Thanks to the great beginner's guide on I managed to set up a basic system pretty fast and I didn't even run into that much problems. ^^ At the moment I'm using awesome as a window manager — which, btw, is absolutely doing justice to its name —, emelFM2 as my filemanager (also a great component), sxiv for viewing images and apart from that the common stuff that I already used before ... Firefox, VLC, GIMP, XAMPP, etc.

The thing that caused the most problems so far and, additionally, the second topic in this blog entry, is my new Wacom Bamoo Pen tablet. I chose a Wacom tablet because I knew about the Linux Wacom Project. Unfortunately the tablet I got is a relatively new model and isn't yet supported by the standard linuxwacom package you get from the repositories. Thus I had to use a package from the AUR, patch it and manually change some stuff — which I managed to do because of the great help I got from some guys from : )

So ... I now got a new, awesome system and a nice drawing tablet. The only thing I'm missing now is drawing skills. :D But that's fine, I got the tablet mainly for postprocessing of photos and doing stupid things on imageboards. ^^



28  27  26  25  24  23  22  21  20  19  18  17  16  15  14  13  12  11  10  9  8  7  6  5  4  3  2  1