Shell Steckerhalter's ƛ

Shell commands with GNU sed

sed is useful to replace some text on the fly. But how about processing text on the fly with shell commands instead of just replacing it with fixed content?

ssh Agent Forwarding

Quite often it is necessary to ssh via an intermediate host if the destination host is not directly accessible through ssh. Usually people do this:

ssh user@host1
ssh host2
# you'll have to enter your password

Finding unicode symbols on the shell

Sometimes I want to know if there is a unicode symbol for a certain topic. There is a convenient tool on the command line that allows to do exactly that. For example to find something regarding computer:

$ unicode computer
U+1F4BB PERSONAL COMPUTER
UTF-8: f0 9f 92 bb UTF-16BE: d83ddcbb Decimal: 💻 Octal: \0372273
💻
Category: So (Symbol, Other)
Bidi: ON (Other Neutrals)

U+1F5A5 DESKTOP COMPUTER
UTF-8: f0 9f 96 a5 UTF-16BE: d83ddda5 Decimal: 🖥 Octal: \0372645
🖥

Download and unzip in one command

With tar it is possible to do something like this:

wget -O- http://example.com/my.tar.gz | tar xvz

This downloads and extracts the archive in one go which is of course faster than having to first download and then extract the contents. I have been annoyed that this didn’t seem possible with zip files. But today I found a “trick” for exactly that: