Random Linux Niceties


Over the years there are lots of little tricks and tips that make life easy/hard fun... this is a collection of the things I think are cool little hacks that I will probably forget or something like that. I started making this list on 2/3/07.

-wz


DCOP + SSH + Amarok Awesomeness

Ever wanted to just change songs playing on your main machine, while sitting across the room on your laptop? Well DCOP + Amarok was made to do this.
Its super cool. It clenches it for me that I need a media machine... it can just sit anywhere, screenless and busy accumulating mp3's and video and play movies and songs from torrents.

$ dcop amarok player {next|prev|play|pauseplay|stop|setVolume}
Or if you feel really spicy....
$ ssh 192.168.x.x "DISPLAY=:0 /usr/kde/3.5/bin/dcop amarok player next"
Now all you need to do is make some XFCE buttons that link up the the ssh command for dcop... and your set. Even better... hot-keys that emulate amarok on the main machine!

DPMS

Ever just wanted to turn your screen off immediately and lock/start the screensaver?
Well here it all is. I generally feel bad letting the screen saver run because of power waste or something, or I think the screens are being wasted.. I don't really know, but here is a script to make me sleep better at night.
woodzy@desk ~ $ cat scripts/sleep-screen 
#!/bin/bash
xscreensaver-command -activate
sleep 10
xset dpms force standby 

Remote Mplayer

So your sitting across the room from your giant lcd screen attached to a linux machine, mplayer finishes a movie and you want to start another without getting up cause your lazy, your too drunk, your under the covers with a lady friend, who knows... something. So bust out your laptop, ssh into the media box and do something like the following.
woodzy@media ~ $ DISPLAY=:0 mplayer -fs -xineramascreen 2 -stop-xscreensaver file.to.play

Now not only do you have a new movie playing, but you have remote control on your laptop... ah linux is awesome.

-wz

Back - Home