更新时间:2023-11-22 15:30:52
引用 sftp
手册页:
Quoting the sftp
man page:
如果以下任何命令失败,
sftp
将中止:get
,put
,reget
,reput
,rename
,ln
,rm
,mkdir
,, ls
,lchdir
,chmod
,chown
,chgrp
,lpwd
,df
,symlink
和lmkdir
.可以在命令的基础上通过在命令前面加上-
字符(例如,-rm /tmp/blah*
)来抑制错误终止.
sftp
will abort if any of the following commands fail:get
,put
,reget
,reput
,rename
,ln
,rm
,mkdir
,chdir
,ls
,lchdir
,chmod
,chown
,chgrp
,lpwd
,df
,symlink
, andlmkdir
. Termination on error can be suppressed on a command by command basis by prefixing the command with a-
character (for example,-rm /tmp/blah*
).
因此使用:
-get $clientLocation/$filePattern2 $myLocation