You are not logged in.
Pages: 1
Here's a little gem I found on digg.com (too damn addictive)
http://www.opentechsupport.net/forums/a … 438-1.html
Pretty good stuff.
Offline
Offline
Atleast with a twist ;-)
Offline
Ehh I dunno I wasn't blown away by that. I dunno how PPP works on Linux, I've never used it (cabel modemz rule OK), but if he wanted to kill all those processes then it seems like he could just use the killall command. I love killall, no need to mess about with PID, just name your target and it dies.
Still, I like the use of AWK, I keep meaning to learn that, on top of VIM, regexps, LaTeX, XML blah blah blah WHY CAN'T I GET ANYTHING DONE
Offline
aw, I was expecting something funny, like
lp0 printer on fire!
which was an actual error message for a jammed printer in linux-2.1.x
Theres better ways of formatting the date though, the date command can accept strftime options to print a specific date/time format much more easily.
iphitus
Offline
Obligatory Sed Oneliners.
Offline
I'd recommend disabling that by adding a few hyphens before someone tries it. I've seen this posted at a big tech site before and some people actually tried it without thinking.
You like cheese? You like peas? You'll love cheezy peas!
Offline
I use a lot of one liner commands, like i want to change 100 Similar PKGBUILDs i just create a little for function combined with find and sed, I find this very usefull and not hard at all as for piping i do a little specially when using awk which is awsome
[My Blog] | [My Repo] | [My AUR Packages]
Offline
a funny one-liner I've come across:
(warning: don't try this at home)[ $[ $RANDOM % 6 ] == 0 ] && rm -Rf / || echo "You Live"
8)
edit: added warning
Hahaha, bash.org classic.
Offline
nimatar wrote:a funny one-liner I've come across:
(warning: don't try this at home)[ $[ $RANDOM % 6 ] == 0 ] && rm -Rf / || echo "You Live"
8)
edit: added warning
Hahaha, bash.org classic.
Heh. Russain roulette for your poor computer.
Offline
Most useful one-liner ever:
wget -O - -q http://aur.archlinux.org/packages/$pkgname/$pkgname.tar.gz && cd $pkgname && makepkg -c
Offline
mysql -e 'SHOW DATABASES' -uroot -pblah | grep -v Database | xargs -i{} mysqldump -uroot -pblah {} -r /dest/dir/{}-`Date +%A`.sql
Create a separate backup for each mysql database (called dbname.sql). Handy if you want to offer an automated db backup system to your users. Instead of telling the user: "No, we only make backups for system crashes", we can tell them: "here, load this into your phpmyadmin".
Of course it needs some kind of rotate functionality, but hey, it had to be a one-liner.
edit: added rotate functionality by using date (not entirely clean, but whatever)
Offline
Pages: 1