Run Rsync from Python
This question already has an answer here:
You can call a subprocess from python using the following snippet
import subprocess
subprocess.call(["ls", "-l"])
In your case, it would be something like this
subprocess.call(["rsync", "-Ccavz", "--delete","DJStatic", "username@website"])
See here for more details.
链接地址: http://www.djcxy.com/p/13490.html下一篇: 从Python运行Rsync