Skip to content

Instantly share code, notes, and snippets.

View l-mb's full-sized avatar

Lars Marowsky-Brée l-mb

View GitHub Profile
@l-mb
l-mb / updateChecklist.js
Created December 25, 2025 10:48
Export the open/checked off checklist item counts to a file property in Obsidian
// This adds a counter of completed vs total checklist items in a note as a file
// property whenever you update the note.
// I use this together with the TaskNote plugin's Kanban view to give me a "Trello"-like
// experience of items that are still open/completed at a quick glance.
// Customize as you see fit - it might differ based on which task statuses you
// use with Obsidian, for example, or which property names you want.
//
// Pre-requisites: the QuickAdd and Linter plugins
//
// Alternative: turning this into a proper plugin and/or a more complex bases query?
@l-mb
l-mb / package_tracker.py
Created August 19, 2025 08:00
ansible callback to track package (requested) (un)installs during playbook run
#!/usr/bin/python3
from ansible.plugins.callback import CallbackBase
class CallbackModule(CallbackBase):
CALLBACK_VERSION = 2.0
CALLBACK_TYPE = 'notification'
CALLBACK_NAME = 'package_tracker'
def v2_runner_on_ok(self, result):