- Test-Driven Development (TDD) with pytest: Always write a failing test before writing implementation code (Red-Green-Refactor). Use
pytestandpytest-fixturesfor test setup, execution, and teardown. - KISS (Keep It Simple, Stupid): Favor the simplest solution that meets the requirements.
- DRY (Don't Repeat Yourself): Avoid code duplication. Extract reusable logic into functions or classes.
- Standard Libraries and Tools: Utilize standard Python libraries (like
datetimefor date/time,requestsfor HTTP requests, andlogging) and external libraries, includingBeautifulSoup4for HTML parsing, to avoid reinventing the wheel. Favor well-maintained and widely-used libraries. - YAGNI (You Ain't Gonna Need It): Don't implement features or functionality unless they are currently required.
- SOLID Principles & Extensibility: Adhere to SOLID principles, promoting maintainability, testability, and future extension. Consider potential future requi
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| {#--------------------------------------------------------------------- | |
| custom_pub_chat_template_gemma4.jinja | |
| ===================================== | |
| A public, harness-friendly fork of Google's Gemma 4 chat template, | |
| tuned for open-source agentic coding harnesses like: | |
| - anomalyco/opencode (https://github.com/anomalyco/opencode) | |
| - earendil-works/pi (https://github.com/earendil-works/pi) | |
| - openclaw, OpenHarness, similar Claude-Code-style harnesses | |
| WHY THIS FORK EXISTS |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # PCA on n=6990 images of handwritten 2's, each with d = 784 pixels. | |
| # install.packages("remotes") | |
| # remotes::install_github("jlmelville/snedata") | |
| # thank you jlmelville for making this data so easy to access! | |
| library(snedata) | |
| library(magrittr) | |
| library(Matrix) | |
| library(rARPACK) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Commented version of https://twitter.com/zozuar/status/1441384708441456651 | |
| // Google-translated (with some editing) from @gam0022's version | |
| float i, // Ray marching loop counter | |
| e, // Volume density (the smaller the value, the higher the density) | |
| s, // FBM scale (and loop counter) | |
| g, // Ray's distance (also used for tunnel twirl and camera prespective) | |
| k = .01; // Handy constant | |
| // Ray marching loop |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // RCL 05 June 2021 | |
| /* | |
| verify with `openssl pkey -in <privatekey>` or `openssl pkey -in <privatekey> -pubout` | |
| the latter should match the publickey | |
| */ | |
| package main | |
| import ( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Install docker or podman package on your distro (podman doesn't need a daemon like dockerd to work). All args are exactly same, just replace ``podman`` with ``docker`` in command if you want to. | |
| sudo pacman -S podman | |
| # Run an archlinux container with dbus and wayland sockets. | |
| sudo podman run \ | |
| --volume "$XDG_RUNTIME_DIR/$WAYLAND_DISPLAY":/tmp/wayland-0 \ | |
| --device /dev/dri \ | |
| --volume /run/user/1000/bus:/tmp/bus \ | |
| --rm -it archlinux /bin/bash |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 1. Install msys2 from msys2.org | |
| 2. run msys2.exe: pacman -Syu, restart, pacman -Su | |
| 3. run mingw64.exe: pamcan -S mingw-w64-x86_64-emacs | |
| 4. create C:\msys2_64\runemacs_patched_path.bat: | |
| cmd /C "set PATH=C:\msys2_64\mingw64\bin;C:\msys2_64\usr\bin;%PATH% && C:\msys2_64\mingw64\bin\runemacs.exe --daemon" | |
| 5. Super-R shell:startup [RET] | |
| 6. Create shortcut to runemacs_patched_path.bat, call it e.g. "emacs-daemon" | |
| 7. Create a short-cut in Start menu: | |
| C:\msys2_64\mingw64\bin\emacsclientw.exe -c -n -a "C:\msys2_64\mingw64\bin\runemacs.exe" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ;;; test-lsp-jdtls-installation.el --- Test lsp jdtls installation -*- lexical-binding: t; -*- | |
| ;;; Date: 2020-05-11_09.12.50 | |
| ;;; Usage: | |
| ;; ┌──── | |
| ;; │ $ emacs -nw -Q -l \ | |
| ;; │ --eval '(setq with-proxy-http-server "127.0.0.1:XXXX")' \ | |
| ;; │ /path/to/test-lsp-jdtls-installation.el | |
| ;; └──── | |
| (toggle-debug-on-error) | |
| (setq user-emacs-directory (format "~/.emacs.d/%s/%s/" (file-name-base load-file-name) emacs-version)) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| mount_*/ | |
| environment_*/ | |
| output.log |
This is a step-by-step tutorial for setting up your own conda feedstock from scratch. I started with the instructions here:
As a novice, I found that the above tutorial lacked sufficient detail. So, I decided to document the process that I used for my own future reference.
NewerOlder