This repository has been archived on 2026-06-13. You can view files and clone it, but cannot push or open issues or pull requests.
anvillm/mcptools/sync_beads.sh

24 lines
453 B
Bash
Executable File

#!/bin/bash
# capabilities: beads
# description: Sync a mounted beads project
# Usage: sync_beads.sh --mount <mount>
set -euo pipefail
MOUNT=""
while [[ $# -gt 0 ]]; do
case "$1" in
--mount) MOUNT="$2"; shift 2 ;;
*) echo "unknown argument: $1" >&2; exit 1 ;;
esac
done
if [ -z "$MOUNT" ]; then
echo "usage: sync_beads.sh --mount <mount>" >&2
exit 1
fi
echo "sync" | 9p write "beads/$MOUNT/ctl"
echo "synced $MOUNT"