TIL: Image Cells in Google Sheets

Today I learned you can insert image cells into a Google Sheets document. All you need is a URL to an image:

=IMAGE("http://example.com/image.jpg")

The documentation lists a few other options, like how the image should be sized and fit the cell.

Screenshot of image cells in a Google Sheets document

For certain things, like planning a kitchen remodel, having a small thumbnail makes it really easy to skim through a document and even helps in the design process.

TIL: Open Atom Fuzzy Finder Results in Split Panes

One of the things I missed most from vim’s fuzzy finder plugins is the ability to open a result in a new split. So today I decided to take a few minutes today and look for a solution. Turns out I’m not the first to want this, and came across this issue that has a nice solution.

Turns out, all you need to do is add something like the following to your keymap (goto Atom → Keymap… to edit it):

'.fuzzy-finder atom-text-editor[mini]':
  'cmd-right': 'pane:split-right'
  'cmd-down': 'pane:split-down'

Now when you’re searching for a file, you can hit ⌘→ to open it in a new pane to the right, or ⌘↓ to open it in a new pane below. (You could probably figure out the other directions, but I find these 2 are what I want do do 99% of the time). Pretty handy!

TIL: SSH Bastion Hosts

Today I finally learned how to setup “bastion” or gateway hosts to enable one-line simple SSHing to machines behind a firewall.

For too long I would first SSH into the public machine, then issue another SSH command to get to the machine I wanted. I knew it was possible to do it with one line but never bothered figuring it out. I finally found a straightforward guide and made it work.

The setup is as follows: gateway is a machine with a public IP address and SSH port open, storage is not. I want to be able to simply ssh gateway (which already works without any extra configuration) and ssh storage.

Here’s what to add to ~/.ssh/config:

Host gateway
  HostName xxx.xxx.xxx.xxx # public IP (or hostname)
  ForwardAgent yes

Host storage
  ProxyCommand ssh gateway -W yyy.yyy.yyy.yyy:22 # internal IP (or hostname)
                                                 # even though 22 is the default, it's required

As a bonus this works perfectly with Transmit! I can just specify storage as the hostname and let SSH create the tunnel for me.