Skip to content

Instantly share code, notes, and snippets.

View karstx's full-sized avatar
⚙️

Karolis Stasaitis karstx

⚙️
View GitHub Profile
@karstx
karstx / keybase.md
Created October 18, 2026 09:52
Keybase proof

Keybase proof

I hereby claim:

  • I am karstx on github.
  • I am carlossless (https://keybase.io/carlossless) on keybase.
  • I have a public key whose fingerprint is 30BB C79D B489 1D4D 0CC9 718A 2EEC C8FA 302A 72F5

To claim this, I am signing this object:

@karstx
karstx / io.carlossless.debesis.svg
Created June 7, 2026 14:41
debesis app icon (vector source of truth)
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
{
lib,
stdenv,
fetchFromGitHub,
xcbuildHook,
}:
stdenv.mkDerivation rec {
pname = "nuage";
version = "0.0.9";
❯ /nix/store/3199ymcckbqln3b3vx4rzlj54why6b8s-q2pro-0-unstable-2025-05-03/bin/q2pro
------- FS_Init -------
Current search path:
/Users/carlossless/.q2pro/baseq2/pak3.pkz (118 files)
/Users/carlossless/.q2pro/baseq2/pak2.pak (2 files)
/Users/carlossless/.q2pro/baseq2/pak1.pak (279 files)
/Users/carlossless/.q2pro/baseq2/pak0.pak (1106 files)
/Users/carlossless/.q2pro/baseq2
/nix/store/3199ymcckbqln3b3vx4rzlj54why6b8s-q2pro-0-unstable-2025-05-03/share/q2pro/baseq2
1387 files in PAK files
@karstx
karstx / rpi4-lp5012-leds.nix
Created March 29, 2025 18:56
nix (nixos, nixos-hardware) device-tree overlay for LP5012 & oneshot systemd service to set LED color
{ config, lib, ... }:
let
cfg = config.hardware.raspberry-pi."4".lp5012-leds;
in {
options.hardware = {
raspberry-pi."4".lp5012-leds = {
enable = lib.mkEnableOption ''
support for lp50xx activity leds.
'';
@karstx
karstx / sinolink.py
Last active October 30, 2024 18:00
A shallow mock of sinolink's USB descriptors using facedancer
@karstx
karstx / gist:ed4014f300582d7bc8dd8e66a95d9b3a
Created February 18, 2024 12:23
u-boot with CONFIG_SERIAL=n
Running phase: unpackPhase
unpacking source archive /nix/store/bvzli4m66fv7s3h9yb3ra37r2fbcrdjw-u-boot-2023.07.02.tar.bz2
source root is u-boot-2023.07.02
setting SOURCE_DATE_EPOCH to timestamp 1689088844 of file u-boot-2023.07.02/tools/zynqmpimage.h
Running phase: patchPhase
patching script interpreter paths in tools
tools/rmboard.py: interpreter directive changed from "#! /usr/bin/python3" to "/nix/store/qhadfg7ab0rchg2icqy1z0980pmqm8qr-python3-3.11.6-env/bin/python3"
tools/buildman/main.py: interpreter directive changed from "#!/usr/bin/env python3" to "/nix/store/qhadfg7ab0rchg2icqy1z0980pmqm8qr-python3-3.11.6-env/bin/python3"
tools/k3_fit_atf.sh: interpreter directive changed from "#!/bin/sh" to "/nix/store/8hdfaadlsdrxhzji9wzypadip450mflv-bash-5.2-p15/bin/sh"
tools/rkmux.py: interpreter directive changed from "#!/usr/bin/env python3" to "/nix/store/qhadfg7ab0rchg2icqy1z0980pmqm8qr-python3-3.11.6-env/bin/python3"
{ lib, pkgs, stdenvNoCC, dtc }:
with lib; {
applyOverlays = (base: overlays': stdenvNoCC.mkDerivation {
name = "device-tree-overlays";
nativeBuildInputs = [ dtc ];
buildCommand = let
overlays = toList overlays';
in ''
mkdir -p $out
@karstx
karstx / bcm2711-rpi-4-b.dts
Last active June 19, 2022 15:36
bcm2711-rpi-4-b.dtb with a partially applied poe-hat-overlay
/dts-v1/;
/memreserve/ 0x0000000000000000 0x0000000000001000;
/ {
compatible = "raspberrypi,4-model-b\0brcm,bcm2711";
model = "Raspberry Pi 4 Model B";
#address-cells = <0x02>;
#size-cells = <0x01>;
interrupt-parent = <0x01>;
@karstx
karstx / dnsmasq-for-localhost-on-macos.md
Last active December 16, 2022 10:38
Setup dnsmasq for .localhost domains on macOS

.localhost domains on macOS with dnsmasq

  1. Install dnsmasq
brew install dnsmasq
  1. Add an address entry to point everything under .dev to 127.0.0.1 in /usr/local/etc/dnsmasq.conf
echo "address=/.localhost/127.0.0.1" &gt;&gt; "$(brew --prefix)"/etc/dnsmasq.conf