TIL is my collection of daily learnings. Each entry is brief, technical, and lightly edited.
Tail Docker Logs
Here’s how you tail a Docker log. docker logs --follow <container_name> See docker logs --help for more.
TIL is my collection of daily learnings. Each entry is brief, technical, and lightly edited.
Here’s how you tail a Docker log. docker logs --follow <container_name> See docker logs --help for more.
MySQL’s display is tabular: ...
One of my projects features a Dockerized API. The dev process was: write a file, rebuild container, and restart container. There’s a better way! ...
Sometimes I’ll be looking at a Git commit online, and want to put my dev environment in a world where the commit is un-applied. This can be achieved by applying it in reverse. ...
I’ve been buying keyboards with Cherry MX switches for a decade, browns and a few blues. Today, I learned that MX stands for “Mechanical X-Point”– “X” for the x-shape of the keyboard stem you can see when you remove the keycap. https://en.wikipedia.org/wiki/Cherry_AG
As a long-time Ruby on Rails programmer, I thought that the name ActiveRecord –the model layer of Rails’ MVC– was branding. I didn’t know that it’s an architectural pattern, described by Martin Fowler in the 2003 book Patterns of Enterprise Application Architecture. An object that wraps a row in a database table or view, encapsulates the database access, and adds domain logic on that data. https://www.martinfowler.com/eaaCatalog/activeRecord.html
The Node REPL has its own editor: node > .editor // Entering editor mode (Ctrl+D to finish, Ctrl+C to cancel) const increment = (array) => array.map(item => item + 1) increment([1,2,3]) Exit and evaluate with Ctrl+D: [ 2, 3, 4 ] I’d use this to experiment with JavaScript API’s without leaving my terminal-based IDE.
I have a Vim normal mode mapping, and I don’t know where it comes from. My Vim config, a plugin, somewhere else? nmap shows me the mapping: :nmap gsp n gsp * 1z= And verbose nmap shows me where it comes from: :verbose nmap gsp n gsp * 1z= Last set from ~/.vimrc line 111 The setting is coming from inside the .vimrc!
It’s common practice to create usernames in a non-production database like “dev@example.com” or “customer@example.org”. We do this to say: “This is just an example!” But there’s a more to the story. ...
Today I learned about the .har extension (via Wikipedia): ...
Don’t miss my next essay
Hear from me immediately when I post: no ads, unsubscribe anytime.