Agent hallucinated "xiaojuzi@meta.com" instead of looking up the correct address from USER.md. Prompting rules can't reliably prevent this, so recipient validation is now enforced at the tool level. - Add contact list/add/delete subcommands (vCard .vcf files synced via CardDAV) - send --to now resolves through contacts: accepts names, name:type, or known emails; rejects unknown addresses with available contacts shown - Multi-email contacts supported with type qualifier (e.g. "小橘子:work") - Adding contacts and sending are separate operations (no chaining)
27 lines
1.2 KiB
Bash
Executable File
27 lines
1.2 KiB
Bash
Executable File
#!/usr/bin/env bash
|
|
# calendar — wrapper script for the calendar and todo tool.
|
|
#
|
|
# Usage:
|
|
# ./calendar.sh send [options] # send a calendar invite (supports --rrule)
|
|
# ./calendar.sh reply [options] # accept/decline/tentative
|
|
# ./calendar.sh event list [options] # list/search calendar events
|
|
# ./calendar.sh event delete [options] # delete an event by UID or summary
|
|
# ./calendar.sh contact list # list all contacts
|
|
# ./calendar.sh contact add [options] # add a contact
|
|
# ./calendar.sh contact delete [options] # delete a contact
|
|
# ./calendar.sh todo add [options] # create a todo
|
|
# ./calendar.sh todo list [options] # list pending todos
|
|
# ./calendar.sh todo edit [options] # edit a todo's fields
|
|
# ./calendar.sh todo complete [options] # mark todo as done
|
|
# ./calendar.sh todo delete [options] # remove a todo
|
|
# ./calendar.sh todo check # daily digest for cron
|
|
#
|
|
# Requires: uv, himalaya, vdirsyncer (for CalDAV sync).
|
|
|
|
set -euo pipefail
|
|
|
|
SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
|
|
SKILL_DIR="$(cd "$SCRIPT_DIR/.." && pwd)"
|
|
|
|
exec uv run --project "$SKILL_DIR" python "$SCRIPT_DIR/cal_tool.py" "$@"
|