noste | 11 years ago | on: Sweden has proof foreign submarine entered its waters
noste's comments
noste | 12 years ago | on: How Japan Copied American Culture and Made it Better
noste | 13 years ago | on: What It's Like To Be Ridiculed For Open Sourcing A Project
# This version is obviously unsafe
verbose_sed() {
sed -i.old -e "$1" "$2"
diff -u "$2.old" "$2"
rm "$2.old"
}
verbose_sed s/vim/emacs/g rant.txt
You could then use all the tools that we already have for working with patches: colordiff to colorize the output, diffstat for a summary of changes, patch -R for reverting the changes, and so on.Of course, you're more likely to than not already using version control, which gives you all this and much more, even if you were to use vanilla find+sed.
noste | 13 years ago | on: '2 girls 1 cup' producer sentenced to 4 years in federal prison
noste | 13 years ago | on: Why Opera thrives in Europe’s last dictatorship
noste | 13 years ago | on: How To Strip DRM from Kindle E-Books and Others
noste | 13 years ago | on: Bashttpd - An http server in bash
I'm somewhat saddened to see that they don't own dd.sh domain anymore. It was at least twice as cute as no.de is :)
noste | 13 years ago | on: Do Plants Think?
noste | 14 years ago | on: Why I Use Perl: Reliability
noste | 14 years ago | on: What's really behind Twitter's staff exodus
noste | 14 years ago | on: Learn to speak vim - verbs, nouns, and modifiers
noste | 14 years ago | on: China state paper urges Internet rethink to gag foes
noste | 14 years ago | on: Linus Torvalds proposes a change to the Git commit object format
noste | 14 years ago | on: I don't program in my spare time. Does that make me a bad developer?
1. http://git.kernel.org/?p=linux/kernel/git/torvalds/tracker.g...
2. http://git.kernel.org/?p=linux/kernel/git/torvalds/pesconver...
3. http://git.kernel.org/?p=editors/uemacs/uemacs.git;a=summary
noste | 15 years ago | on: Soywiki: a wiki built on top of Vim and Git.
noste | 15 years ago | on: Transcending the Human, DIY Style
That being said, there is interesting stuff to be done without DIY surgeries. For example, Christina Kubisch used to auralize electromagnetic fields using some portable gear, and wander around urban areas listening sounds made by security systems, WLAN hotspots, and the like (see interview here: http://www.christinakubisch.de/pdf/Kubisch_Interview.pdf ).
noste | 15 years ago | on: Kafka: A distributed pub/sub messaging system from LinkedIn
noste | 15 years ago | on: A Guide to the Good Life: The Ancient Art of Stoic Joy
noste | 15 years ago | on: Secure your code: OpenVPN in the cloud
"Yeah, there is. First, doing it with SSH+keys requires either multi-step (which is annoying, esp. for copying files), or exposing each servers SSH to the net (which might be unfeasible if you don't have public IPs for everything)."
You can work around much of the annoying stuff in multi-step setups by using SSH's ProxyCommand configuration variable. For example, you could have something like this in your local .ssh/config:
Host prod-db
ProxyCommand ssh bastion nc -w1 %h %p
After which 'ssh prod-db' and 'scp prod-db:...' work as if the bastion host wasn't between you and prod-db."Second, getting a dump of a table from your MySQL DB with SSH+keys:"
If you can access prod-db with SSH, you can dump the database with a single command:
$ ssh prod-db mysqldump what-i-need > file.sqlnoste | 15 years ago | on: People have no bloody idea about saving energy