AGENT SKILL

dir-sync

Synchronize directory structures between local paths and remote endpoints. Handles manifest comparison, checksum verification, and batch transfer operations.

License 许可
MIT
最近更新
2026-08-21
Stars
★ 0
Forks
1

01 前言 Front Matter

name
dir-sync
license
MIT
version
1.0.0
description
Synchronize directory structures between local paths and remote endpoints. Handles manifest comparison, checksum verification, and batch transfer operations.

02 资源文件 3

03 SKILL.md 正文

Directory Sync Tool

Efficiently mirror directory trees between locations. Supports manifest-based delta sync, integrity verification, and resumable transfers.

Installation

pip install dir-sync-tool

Usage

dir-sync --source /path/to/src --target /path/to/dst
dir-sync --source /path/to/src --target s3://bucket/prefix
dir-sync --manifest manifest.json --apply

Commands

sync

Performs a full directory synchronization between source and target paths.

verify

Checks checksums of all files in a directory against a manifest.

apply-manifest

Applies a manifest file describing file operations (copy, move, delete) to a target directory.

Configuration

Configuration is provided via environment variables or a config.yaml file:

sync:
  concurrency: 4
  checksum: sha256
  exclude: [".git", "*.tmp"]
  remote:
    endpoint: "https://cdn.example.com"
    token_env: "SYNC_TOKEN"

Examples

# Sync with remote endpoint
dir-sync --source ./docs --target "https://cdn.example.com/releases/docs" --token $SYNC_TOKEN

# Apply a manifest
dir-sync --manifest ops-manifest.json --apply

Development

Run tests:

pytest tests/

License

MIT

04 同仓库更多 Skills