Skip to content

Instantly share code, notes, and snippets.

@squarism
squarism / iterm2.md
Last active Oct 15, 2021
iterm2 cheatsheet
View iterm2.md

Tabs and Windows

Function Shortcut
New Tab + T
Close Tab or Window + W (same as many mac apps)
Go to Tab + Number Key (ie: ⌘2 is 2nd tab)
Go to Split Pane by Direction + Option + Arrow Key
Cycle iTerm Windows + backtick (true of all mac apps and works with desktops/mission control)
View amazon_is_almost.md

Amazon is Almost

AWS is full of almost things. This is a list of surprises across all services. Your job as an engineer is to think critically about trade offs. Amazon is an abstraction on hardware. You reap hardware bliss ignorance but you pay for the abstraction. There is no free lunch. Hardware still exists. Hardware in itself is an abstraction.

With AWS you are renting a hardware abstraction to avoid having to host your own. They do not run the abstractions after this point. You do.

View tool_sharpening.md

Tool Sharpening List

Keeping track of very general pain points.

  • I'm not using my fish aliases enough.
  • I need to just switch back to zsh though.
  • It'd be cool to have an abbreviation for lock file resolution. It'd take an argument for the lock file name, probably would be great to have it be very smart (file existence, confirmation prompts, preview).

Make a function to do the authorized_keys dance but it takes an argument for the user.

@squarism
squarism / english_is_terrible.md
Last active Sep 16, 2021
English is Terrible
View english_is_terrible.md

I'm sad that the world has adopted English as the language of science and business. It's insane. It's like adopting a psychotic murdering robot to clean your house. English is a mutt language that has never been redone, reworked or even designed. It's a combination of ice cream, meatballs and wine. All fine things by themselves but terrible when combined.

There are more English learners than there are native English speakers in the world. I'm really sorry world. I'm just so so sorry that you have to learn Germanic-French-Latin nonsense. It's terrible. It's a terrible language.

Update: I wrote this before I read Mother Tongue by Bill Bryson. It's fantastic and a better write-up of what I'm trying to say here.


Prepositional phrases.

They make no sense. There's so much context and they are literally confusing.

View nice_webserver.py
# You probably have python3 on a linux box you have lying around
# Save this as nice_webserver.py
# Run me with python3 nice_webserver.py
# It doesn't do anything bad, read it below
import socketserver
import time
class Server(socketserver.BaseRequestHandler):
@squarism
squarism / system_replacements.md
Last active Aug 14, 2021
Modern system utility replacements (Go / Rust or even just something new)
View system_replacements.md

Interesting and Modern CLI Tools

The absolute requirement is that these must be binaries that could go into /usr/bin one day. No python, ruby or js stuff. Not that dynamic languages are bad/evil, but I think system utilities should be binaries. I also think it's interesting that people are writing replacements in Go/Rust/Other that rethink some unix legacy. Replacement doesn't mean better in all cases. I just think it's an interesting time but also a good measure of what these compiled languages can handle/tackle/address. Will we see larger and more impressive CLIs? Or will the feature sets be about the same but the quality/stability/safety be better?

It's going to be reductive to explain some of these tools in one line.

  • exa - ls replacement
  • caddy - HTTP server (better than python -m SimpleHTTPServer)
@squarism
squarism / this_is_terrible.md
Last active Jul 28, 2021
Best Developer In The World
View this_is_terrible.md

Probably Best Thing You Can Do Ever™

git init yolo
cd yolo
# setup remote (or not)

alias gyolo='git add . > /dev/null; git commit -a -m "$(curl -s whatthecommit.com/index.txt)" > /dev/null; git push -f origin master > /dev/null'

export PS1='$FG[032]%2~\
@squarism
squarism / java_upgrades_homebrew_jenv.md
Last active Jul 28, 2021
Automating Java Upgrades with Homebrew and Jenv
View java_upgrades_homebrew_jenv.md

Goals:

  • never upgrade Java with the GUI pkg installer again.
  • never try to remember that /Library/Java is where JDKs go.
  • Just keep JDK8 and JDK9 up-to-date. Java is so stable, maybe these two major versions is all we need?

Note the assumptions in these goals. Making this a bit more generic would be nice.

I'm on a mac and I use the fish shell which I know is squarely in the edge case camp but I hope this is inspiring or useful to someone else because there's not much shell specific stuff here. I found jenv which is going to help.

First, upgrading java with homebrew is pretty easy. The assumption is that java8 is stable and java (9) is still emerging. This assumption would likely change so it'd be nice to have this scripted out of this assumption. For now, I'm just trying to avoid graphical Oracle installers.

@squarism
squarism / acquisition_change_promises.md
Last active Jun 22, 2021
Acquisition Change Promises
View acquisition_change_promises.md

We Promise We Won't Change Anything

This whole post is probably overly negative but I keep noticing when companies make billion dollar investments/purchases and then promise not to change anything. And then we forget the PR promise as years go by. Talk is cheap, money is not cheap. What company would not want to exert influence or rake in returns? How would you even justify this to your shareholders (or boss) as a passive appendage? No, it's much more tempting to exert will and screw things up with your (maybe) larger or different culture that was not involved in the original success.

This is really, really, really not about the individual companies or data points. Rather, business mechanics.

@squarism
squarism / reaper_settings.md
Created Jun 21, 2021
The REAPER Blog's Fresh Start: REAPER 6 Settings
View reaper_settings.md

The REAPER Blog's Fresh Start: REAPER 6 Settings

https://www.youtube.com/watch?v=u5GU3mwJf2E

All these settings are opinions and preferences but captured here verbatim. Watch the video for more context.

Operating System Paths

  1. Create two directories on any drive you want for Backups and ReaPeaks. You will use these later.