Skip to content

Instantly share code, notes, and snippets.

@BasicAcid
BasicAcid / org-sort-list-by-checkbox-and-priority.el
Created November 1, 2025 10:52
Sort org list items: unchecked first (no priority, then by priority), then checked.
(defun mf/org-sort-list-by-checkbox-and-priority ()
"Sort org list items: unchecked first (no priority, then by priority), then checked."
(interactive)
(org-sort-list
nil ?f
(lambda ()
;; Extract the sorting key for each item
(let* ((item (buffer-substring-no-properties
(line-beginning-position)
(line-end-position)))
@BasicAcid
BasicAcid / config.def.h
Created December 15, 2023 14:00
My DWM config.
#include <X11/XF86keysym.h>
/* See LICENSE file for copyright and license details. */
/* appearance */
static const unsigned int borderpx = 1; /* border pixel of windows */
static const unsigned int snap = 32; /* snap pixel */
static const int showbar = 1; /* 0 means no bar */
static const int topbar = 1; /* 0 means bottom bar */
static const char *fonts[] = { "monospace:size=10" };
#!/usr/bin/env stack
-- stack --install-ghc runghc --package turtle
{-# LANGUAGE AllowAmbiguousTypes #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE OverloadedStrings #-}
{-
To compile:
stack ghc -- -O2 -dynamic -no-keep-hi-files -no-keep-o-files -Wall tagger.hs -o ~/.local/bin/tagger
-}