{ lib, stdenv, fetchFromGitea, }: stdenv.mkDerivation (finalAttrs: { pname = "little-things"; version = "0-unstable-2026-04-29"; src = fetchFromGitea { domain = "gitea.arpa.li"; owner = "JustAnotherArchivist"; repo = finalAttrs.pname; rev = "ec645c7b748fe985da01126927838f74e7cc4977"; hash = "sha256-g/468gem70MfZ81HDmbyq2J4MItkZaybK9ICCThlKsM="; }; postPatch = '' substituteInPlace dir-to-ia --replace-fail \ '$(git -C "''${scriptpath}" log --max-count=1 --format=%H)' \ "(${finalAttrs.src.rev}) ${finalAttrs.version}" ''; buildPhase = '' rm LICENSE README.md .gitignore .make-and-exec for file in *.c; do echo "compiling $file" orig=$(basename "$file" ".c") rm "$orig" case "$orig" in "youtube-extract-rapid") continue;; esac gcc -o "$orig" "$file" rm "$file" done ''; installPhase = '' install -Dt $out/bin * ''; meta = { description = "The little things give you away... A collection of various small helper stuff"; homepage = "https://gitea.arpa.li/JustAnotherArchivist/little-things"; license = lib.licenses.gpl3Plus; #maintainers = with lib.maintainers; [ ]; }; })