LinuxCommandLibrary

mutagen

provides fast file synchronization and network forwarding for development

TLDR

Create sync session

$ mutagen sync create [/local/path] [user@host:/remote/path]
copy
List sync sessions
$ mutagen sync list
copy
Pause sync session
$ mutagen sync pause [session_name]
copy
Resume sync session
$ mutagen sync resume [session_name]
copy
Terminate sync session
$ mutagen sync terminate [session_name]
copy
Create with ignore patterns
$ mutagen sync create --ignore "*.log" [/local] [remote:/path]
copy
Flush pending changes
$ mutagen sync flush [session_name]
copy
Monitor sessions
$ mutagen sync monitor
copy

SYNOPSIS

mutagen [sync] [forward] [create] [list] [terminate] [options] [args]

DESCRIPTION

mutagen provides fast file synchronization and network forwarding for development workflows. It's designed for syncing code between local and remote environments.
Synchronization watches for filesystem changes and propagates them bidirectionally. Unlike rsync, it maintains persistent sessions that react to changes in real-time.
The tool handles conflicts intelligently. Two-way-safe mode creates conflict files rather than overwriting. One-way modes sync in a single direction.
Docker integration syncs files into containers. SSH connections sync with remote servers. Both can run simultaneously for complex development setups.
Port forwarding tunnels network connections, enabling access to remote services locally or exposing local services remotely.
Performance optimizations include compression, caching, and differential transfers. Large codebases sync efficiently.

PARAMETERS

sync create LOCAL REMOTE

Create synchronization session.
sync list
List sync sessions.
sync monitor
Monitor sessions in real-time.
sync pause SESSION
Pause synchronization.
sync resume SESSION
Resume synchronization.
sync flush SESSION
Flush pending changes.
sync terminate SESSION
End sync session.
forward create LOCAL REMOTE
Create port forwarding.
--ignore PATTERN
Ignore matching files.
--sync-mode MODE
Sync mode (two-way-safe, one-way-safe, etc.).
--name NAME
Session name.

CAVEATS

Requires agent on remote systems (auto-installed via SSH). High file counts may slow initial scan. Conflicts need manual resolution. Docker Desktop on macOS/Windows may have filesystem limitations.

HISTORY

Mutagen was created by Jacob Howard around 2018 to solve file synchronization issues in containerized development environments. It addresses performance problems with Docker Desktop's file sharing on macOS and Windows.

SEE ALSO

rsync(1), unison(1), syncthing(1), docker(1)

> TERMINAL_GEAR

Curated for the Linux community

Copied to clipboard

> TERMINAL_GEAR

Curated for the Linux community