https://github.com/zaaack/scp-sync
Sync project files to remote server via scp,
https://github.com/zaaack/scp-sync
developer-tools remote-development remote-sync scp scp-sync ssh sync
Last synced: 3 months ago
JSON representation
Sync project files to remote server via scp,
- Host: GitHub
- URL: https://github.com/zaaack/scp-sync
- Owner: zaaack
- Created: 2021-03-08T09:00:57.000Z (about 4 years ago)
- Default Branch: master
- Last Pushed: 2021-03-12T07:05:30.000Z (about 4 years ago)
- Last Synced: 2025-02-18T11:45:40.876Z (4 months ago)
- Topics: developer-tools, remote-development, remote-sync, scp, scp-sync, ssh, sync
- Language: TypeScript
- Homepage:
- Size: 31.3 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# @zaaack/scp-sync
Sync project files to remote server via scp.
## Features
* sync file when file changed
* start command after watching
* customize watching directory and remote directory## Usage
```sh
yarn global add @zaaack/scp-sync
scp-sync init # this generate config file "scpSync.json" in current directory.
```then edit scpSync.json,
```json
{
"host": "yourName@yourHost",
"startCmd": "start command to run remotely after watching",
"remoteFolder": "yourRemoteFolderPath",
"localFolder": "yourLocalFolderPath",
"port": 0,
"sshParams": ["extra", "ssh", "params", "when", "running", "startCmd"],
"scpParams": ["extra", "scp", "params", "when", "syncing", "files"],
"ignore": ["**/.DS_Store", "**/node_modules/**"] // 忽略同步某些文件,支持 glob
}
```start watching
```sh
scp-sync start
# scp-sync watch # watch and sync files
# scp-sync exec # exec start command
```