You can also also view the full archives of micro-posts. Longer blog posts are available in the Articles section.
I often want to delete a line matching a pattern in Vim, as well as, say, the next one. Here’s how to do it: :g/pattern/.,+1d
. #vim
TIL about the Datastar framework. Looks good and a bit different from HTMX.
Serving 200 million requests per day with a cgi-bin (via Simon Willison). I built many online quizzes and online survey using cgi-bin back in the days.
I guess my Scheming with Vim will be easier to find on the www.
Summertime
TIL about this little trick: Restrict sftp with Linux user namespaces. #unix
Fun with uv and PEP 723: I came across many similar posts about this new way to run Python scripts via uv. I switched to uv for managing python version and dependencies in virtual environments and I think it’s been one of the best addition to the language ecosystem in a while. #python
Software development needs more simple joy, and I’ve found that creating toy programs is a great way to remember why I started working with computers again. — Writing Toy Software Is A Joy
I have the following Jupyter kernels installed on my HD:
» jupyter kernelspec list
Available kernels:
python3 /Users/chl/.local/lib/jupyter/share/jupyter/kernels/python3
clojupyter /Users/chl/Library/Jupyter/kernels/clojupyter
common-lisp /Users/chl/Library/Jupyter/kernels/common-lisp
racket /Users/chl/Library/Jupyter/kernels/racket
wolfram /Users/chl/Library/Jupyter/kernels/wolframlanguage14.1
I renamed clojupyter snapshot to something more convenient to handle when calling jupyter console
. I’m using OpenJDK 24.0.1 from Homebrew (which I symlinked in macOS default $JAVA_HOME
, using sudo ln -sfn /opt/homebrew/opt/openjdk/libexec/openjdk.jdk /Library/Java/JavaVirtualMachines/openjdk.jdk
) and I kept getting this annoying warning:
WARNING: A restricted method in java.lang.System has been called
WARNING: java.lang.System::load has been called by org.sqlite.SQLiteJDBCLoader in an unnamed module (file:/Users/chl/Library/Jupyter/kernels/clojupyter/clojupyter-standalone.jar)
WARNING: Use --enable-native-access=ALL-UNNAMED to avoid a warning for callers in this module
WARNING: Restricted methods will be blocked in a future release unless native access is enabled
To get ride of the warning, simply add --enable-native-access=ALL-UNNAMED
in the kernel.json
init file.
/me is listening to “Shanghaï Gesture” by The Names