diff --git a/web/src/pages/SyncPairs.tsx b/web/src/pages/SyncPairs.tsx index 98485b6..acd7f1c 100644 --- a/web/src/pages/SyncPairs.tsx +++ b/web/src/pages/SyncPairs.tsx @@ -26,7 +26,7 @@ import { import { EmptyState } from '@/components/ui/EmptyState'; import { Badge } from '@/components/ui/Badge'; import { Card } from '@/components/ui/Card'; -import { Play, Trash2, Plus, GitCompare, ArrowRight, ArrowLeft, Pencil } from 'lucide-react'; +import { Play, Trash2, Plus, GitCompare, ArrowRight, ArrowLeft, Pencil, AlertTriangle } from 'lucide-react'; import { toast } from 'sonner'; import { cn } from '@/lib/utils'; @@ -295,8 +295,8 @@ export default function SyncPairs() { {form.id ? 'Edit Sync Pair' : 'Add Sync Pair'} {form.id - ? 'Update the configuration for this sync pair' - : 'Define a new source and destination for data syncing'} + ? 'Update this sync pair. Direction: push (src→dst), pull (dst←src), or mirror (push + --delete).' + : 'Define source and destination for data syncing. Pick a direction: push (src→dst), pull (dst←src), or mirror (push + --delete).'}
@@ -414,6 +414,12 @@ export default function SyncPairs() { Mirror +

+ Push copies source → destination.{' '} + Pull reverses it (dest ← source).{' '} + Mirror is like push but adds{' '} + --delete (see warning). +

@@ -427,6 +433,22 @@ export default function SyncPairs() { />
+ {form.direction === 'mirror' && ( +
+ +
+ Mirror will delete files.{' '} + With --delete, any file in the + destination that doesn't exist in the source is permanently + removed. Double-check both paths before saving — a wrong + destination (e.g. / or{' '} + /home) can wipe data. +
+
+ )}