Skip to content

ZenUml/conf-app / .claude/skills/add-todo

add-todo

Verified

Record a todo item in a local, untracked JSON file shared by every worktree of this repo. With no argument, extracts the todo from the most recent conversation. Use when the user invokes /add-todo, says "add a todo", "todo:", "add this to my todos", "记个待办", or asks to note a follow-up for later. To view todos use list-todos.

FileKindSize
SKILL.mdskill md2.0 KB
scripts/test_todo.pyscript2.6 KB
scripts/todo.pyexecutablescript4.2 KB

scripts/test_todo.py

View on GitHub
"""Offline tests for the shared todo store used by add-todo and list-todos."""
import contextlib
import io
import json
import os
import sys
import tempfile
import unittest
from datetime import datetime, timedelta, timezone

sys.path.insert(0, os.path.dirname(os.path.abspath(__file__)))
import todo  # noqa: E402

NOW = datetime(2026, 9, 15, 0, 0, tzinfo=timezone.utc)


class TodoStore(unittest.TestCase):
    def setUp(self):
        self.tmp = tempfile.TemporaryDirectory()
        self.addCleanup(self.tmp.cleanup)
        self.path = os.path.join(self.tmp.name, "todos.json")

    def run_cli(self, *argv):
        out = io.StringIO()
        with contextlib.redirect_stdout(out):
            todo.main(["--file", self.path, *argv], now=NOW)
        return out.getvalue()

    def items(self):
        with open(self.path) as f:
            return json.load(f)["items"]

    def test_add_creates_file_and_assigns_incrementing_ids(self):
        self.run_cli("add", "First", "--notes", "from chat")
        self.run_cli("add", "Second")
        items = self.items()
        self.assertEqual([i["id"] for i in items], [1, 2])
        self.assertEqual(items[0]["title"], "First")
        self.assertEqual(items[0]["notes"], "from chat")
        self.assertEqual(items[0]["status"], "open")
        self.assertIsNone(items[0]["completed_at"])

    def test_done_marks_completed(self):
        self.run_cli("add", "Task")
        self.run_cli("done", "1")
        item = self.items()[0]
        self.assertEqual(item["status"], "done")
        self.assertEqual(item["completed_at"], NOW.isoformat())

    def test_done_unknown_id_fails(self):
        self.run_cli("add", "Task")
        with self.assertRaises(SystemExit):
            self.run_cli("done", "99")

    def test_list_shows_open_and_recently_done_only(self):
        for title in ("open task", "recent done", "old done"):
            self.run_cli("add", title)
        data = {"items": self.items()}
        data["items"][1].update(status="done", completed_at=(NOW - timedelta(days=6)).isoformat())
        data["items"][2].update(status="done", completed_at=(NOW - timedelta(days=8)).isoformat())
        with open(self.path, "w") as f:
            json.dump(data, f)
        out = self.run_cli("list")
        self.assertIn("open task", out)
        self.assertIn("recent done", out)
        self.assertNotIn("old done", out)
        self.assertLess(out.index("open task"), out.index("recent done"))

    def test_list_on_missing_file_reports_empty(self):
        self.assertIn("No todos", self.run_cli("list"))


if __name__ == "__main__":
    unittest.main()
slack-gif-creatoranthropics/skillsKnowledge and utilities for creating animated GIFs optimized for Slack. Provides constraints, validation tools, and animation concepts. Use when users request animated GIFs for Slack like "make me a GIF of X doing Y for Slack."Stars: 198kUpdated Claude CodeCodexVerifiedInstall
ponytailDietrichGebert/ponytailLazy senior dev mode for any coding task: the smallest change that fully solves it, and a reply a busy human understands in one read.Stars: 194kUpdated Claude CodeCodexVerifiedInstall
ponytail-debtDietrichGebert/ponytailHarvest every shortcut: comment into one debt ledger, so deferrals get tracked instead of forgotten. One-shot report.Stars: 194kUpdated Claude CodeCodexVerifiedInstall
ponytail-debtDietrichGebert/ponytailList every `shortcut:` comment (and older `ponytail:` ones) as a debt ledger. One-shot report, changes nothing. Use for "ponytail debt", "what did ponytail defer", "list the shortcuts", /ponytail-debt.Stars: 194kUpdated Claude CodeCodexVerifiedInstall