Pinned post

TIL that one can use double dollar sign in sd and rg (ripgrep) to place a literal dollar sign

why do we have universities when StackOverflow-driven-development exists

DB guys, do you find yourself using the term "upsert" often?

Another nice thing I just found in vim is :set so=999

The cursor is now kept in the middle of the screen, no need to pres zz to do it.

Finally found out how to move between splits in kitty terminal.

The shortcut is called Next Window, default is Ctrl+Shift+]

I have found a way how to make sure the tests in Laravel picks up if your defined job was properly scheduled, preventing accidental commented out lines and such. Here's a guide

peterbabic.dev/blog/test-if-co

This is a nice example, sed replacement written in rust called sd, respecting .gitignore via fd (a find replacement)

sd 'from "react"' 'from "preact"' $(fd --type file)

I know, when I ssh somewhere unknown there is a high possibility these modern replacements are not there, so keeping the basics (sed, find, grep, ...) under the belt still pays off, but one can never know too many tools.

I have found myself in the need to manually run jobs that are used for app maintenance like discarding or logs or pruning dangling records, so I documented ways to do it in Laravel 8.

peterbabic.dev/blog/dispatchin

I had some problems using array keys with reduce in Laravel, but managed to solve it in the end. There are some unexpected insights (to me at least), that I summed up in the article.

peterbabic.dev/blog/using-keys

every time I read a book about GNU beginnings I wonder how come I not use emacs but vim, which stems from lineage Berkeley instead

Vim can go to begining or end of last selection with '< and '>

I have never used the ' in vim up until now

Note to schools that have a BYOD policy (for the record, I'm against them, as they amplify inequity), if my child brings a Linux-powered computer to your school, it will be sufficient. If it isn't, it's your systems that have to change, not our computer. If you don't know what I'm talking about, consider this: davelane.nz/explainer-digitech (relevant even for those outside NZ).

TIL that there is SOUNDS LIKE in some SQL variants

Show older
Mastodon

A personal Mastodon instance for peterbabic.dev.