Hermes Sync Command Rewrite | Generated by AI
Here’s a summary of all changes:
What changed
ww/sync/remote.py — sync_hermes() rewritten
- Before: synced only
~/.hermes/config.yamlto/from a hardcoded remote host (via env varsWW_REMOTE_IP/WW_REMOTE_USER) - After: syncs the entire
~/.hermes/directory, with explicitfrom_hostandto_hostparams - Each host is either
localhostoruser@ip forth=from_host→to_hostback=to_host→from_host- Falls back to env vars when
to_hostis empty (backward compat)
ww/main.py — dispatch updated
- Moved
direction = _pop_subcmd() or "forth"into each subcommand (bashrc, zprofile, ssh) that needs it, instead of at the sync group level - For
hermes, usesargparseto handle--from-host,--to-host, and--helpproperly - Updated help text
Usage
# Push local ~/.hermes/ to remote
ww sync hermes forth --from-host localhost --to-host lzw@192.168.1.36
# Pull remote ~/.hermes/ back to local
ww sync hermes back --from-host localhost --to-host lzw@192.168.1.36
# With env vars (backward compat - no flags needed)
ww sync hermes forth
# Help
ww sync hermes --help