Following this post where Pedro talks about how he receives notifications about background jobs I decided to clone his script to a Linux version using libnotify daemon.
#!/bin/bash
"$@"
status=$?
notify-send "Background script notification" "Completed $*"
exit $status
Now if you simple alias n="your_script" you can do pretty things like Melo
n scp user@machine:pr0n /tmp
And get notified when the transfer ends :) Pretty handy! Thank you Melo for this tip!
Following a personal project I’m doing involving processes running over weeks, I stumbled upon some code that allows you to run a block of code in a separate thread in Ruby, every n seconds.
This works great, as expected, and Ruby made my day :-)
Yesterday I change my blog engine.. AGAIN!
This time I’m using the great and powerful Perl based Movable Type blog engine. One of the things that attracted me the most is that MT4 generates your blog in a static way, so almost all the blog frontend is served directly by my HTTP server.
This now means I can resist a little bit more to a slashdot attack :)
For those who read my blog through RSS, I’ve instructed my HTTP server to redirect the old feed URL to the new one, so it should work without making any changes. Wish me luck :)
Oh god I found this post today! Now I can blog from my favorite editor!
THANK YOU PEDRO!
You know I love the Vi – improved. And I wish I know this tip a long time ago.
Basically Vim allows you to write freely and then wrap your text to a fixed number of characters. You can use the :set tw=80 to force your text never to exceed 80 characters. And if you already have a non wrapped text, you can easily select (using visual mode) the text you like to wrap and hit gq on your keyboard, and Vim will haply apply your settings to the region.
For LaTeX and emails, this is awesome…