Remote Sync
VS Code extension for file synchronization to remote development environments via SSH.
Features
- Automatic sync on save
- Respects .gitignore by default
- SSH config integration
- Pattern matching for file triggers
- Debounced sync operations
- Retry with exponential backoff
- Per-workspace configuration
Installation
- Install from VS Code marketplace
- Ensure
rsync is installed locally
- Configure SSH access to remote servers
Usage
Initial Setup
- Open workspace in VS Code
- Save any file to trigger setup
- Select SSH host from ~/.ssh/config
- Enter remote directory path
Configuration
.vscode/settings.json :
{
"remote-sync.connection.host": "dev-server",
"remote-sync.connection.remotePath": "/home/user/project",
"remote-sync.connection.enabled": true,
"remote-sync.triggers.patterns": ["*.py", "*.yaml"],
"remote-sync.triggers.excludePatterns": [],
"remote-sync.sync.deleteExtraneous": true,
"remote-sync.sync.useGitignore": true,
"remote-sync.sync.additionalExcludes": ["node_modules", "__pycache__"]
}
Default behavior: Files in .gitignore are automatically excluded from sync. If no .gitignore exists, all files are synced.
Commands
Remote Sync: Configure Connection
Remote Sync: Sync Now
Remote Sync: Dry Run
Remote Sync: Show Sync Log
Remote Sync: Disable for Workspace
Requirements
- VS Code 1.85.0+
- rsync
- SSH key authentication
Development
npm install
npm run compile
npm test
License
MIT
| |