mirror of
https://github.com/tldr-pages/tldr.git
synced 2025-04-29 23:24:55 +02:00
rsync: add Chinese translation (#5200)
This commit is contained in:
parent
dc1298012c
commit
d698531e94
1 changed files with 36 additions and 0 deletions
36
pages.zh/common/rsync.md
Normal file
36
pages.zh/common/rsync.md
Normal file
|
@ -0,0 +1,36 @@
|
|||
# rsync
|
||||
|
||||
> 一种快速,通用,远程(和本地)文件复制工具。
|
||||
> 更多信息:<https://man7.org/linux/man-pages/man1/rsync.1.html>。
|
||||
|
||||
- 从本地传输文件到远程主机:
|
||||
|
||||
`rsync {{path/to/local_file}} {{remote_host}}:{{path/to/remote_directory}}`
|
||||
|
||||
- 从远程主机传输文件到本地:
|
||||
|
||||
`rsync {{remote_host}}:{{path/to/remote_file}} {{path/to/local_directory}}`
|
||||
|
||||
- 将本地文件以归档模式并保留几乎所有属性,同时使用压缩功能传输到远程主机,并以人类可读方式输出详细信息和进度条:
|
||||
|
||||
`rsync --archive --compress --verbose --human-readable --progress {{path/to/local_file}} {{remote_host}}:{{path/to/remote_directory}}`
|
||||
|
||||
- 将远程主机目录上的所有文件,以递归模式传输到本地:
|
||||
|
||||
`rsync --recursive {{remote_host}}:{{path/to/remote_directory}} {{path/to/local_directory}}`
|
||||
|
||||
- 将远程主机该目录下的所有内容(不包含该目录),以递归方式传输到本地:
|
||||
|
||||
`rsync --recursive {{remote_host}}:{{path/to/remote_directory}}/ {{path/to/local_directory}}`
|
||||
|
||||
- 递归方式传输目录,保留几乎所有属性,解析软连接,并忽略已传输的文件:
|
||||
|
||||
`rsync --recursive --archive --update --copy-links {{remote_host}}:{{path/to/remote_file}} {{path/to/local_directory}}`
|
||||
|
||||
- 指定本地和远程之间通信方式:
|
||||
|
||||
`rsync --rsh ssh {{remote_host}}:{{path/to/remote_file}} {{path/to/local_file}}`
|
||||
|
||||
- 指定本地和远程之间通信方式,使用指定端口,并显示进度条:
|
||||
|
||||
`rsync --rsh 'ssh -p {{port}}' --progress {{remote_host}}:{{path/to/remote_file}} {{path/to/local_file}}`
|
Loading…
Add table
Reference in a new issue