summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sftp.142
-rw-r--r--sftp.c10
2 files changed, 30 insertions, 22 deletions
diff --git a/sftp.1 b/sftp.1
index 4554ae4f3..a52c1cff3 100644
--- a/sftp.1
+++ b/sftp.1
@@ -1,4 +1,4 @@
1.\" $OpenBSD: sftp.1,v 1.126 2019/06/12 11:31:50 jmc Exp $ 1.\" $OpenBSD: sftp.1,v 1.127 2019/06/19 20:12:44 jmc Exp $
2.\" 2.\"
3.\" Copyright (c) 2001 Damien Miller. All rights reserved. 3.\" Copyright (c) 2001 Damien Miller. All rights reserved.
4.\" 4.\"
@@ -22,7 +22,7 @@
22.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 22.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
23.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 23.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
24.\" 24.\"
25.Dd $Mdocdate: June 12 2019 $ 25.Dd $Mdocdate: June 19 2019 $
26.Dt SFTP 1 26.Dt SFTP 1
27.Os 27.Os
28.Sh NAME 28.Sh NAME
@@ -404,7 +404,7 @@ extension.
404Quit 404Quit
405.Nm sftp . 405.Nm sftp .
406.It Xo Ic get 406.It Xo Ic get
407.Op Fl afPpr 407.Op Fl afpR
408.Ar remote-path 408.Ar remote-path
409.Op Ar local-path 409.Op Ar local-path
410.Xc 410.Xc
@@ -439,15 +439,19 @@ flag is specified, then
439will be called after the file transfer has completed to flush the file 439will be called after the file transfer has completed to flush the file
440to disk. 440to disk.
441.Pp 441.Pp
442If either the 442If the
443.Fl P
444or
445.Fl p 443.Fl p
444.\" undocumented redundant alias
445.\" or
446.\" .Fl P
446flag is specified, then full file permissions and access times are 447flag is specified, then full file permissions and access times are
447copied too. 448copied too.
448.Pp 449.Pp
449If the 450If the
450.Fl r 451.Fl R
452.\" undocumented redundant alias
453.\" or
454.\" .Fl r
451flag is specified then directories will be copied recursively. 455flag is specified then directories will be copied recursively.
452Note that 456Note that
453.Nm 457.Nm
@@ -545,7 +549,7 @@ Create remote directory specified by
545.It Ic progress 549.It Ic progress
546Toggle display of progress meter. 550Toggle display of progress meter.
547.It Xo Ic put 551.It Xo Ic put
548.Op Fl afPpr 552.Op Fl afpR
549.Ar local-path 553.Ar local-path
550.Op Ar remote-path 554.Op Ar remote-path
551.Xc 555.Xc
@@ -581,15 +585,19 @@ after the file has been transferred.
581Note that this is only supported by servers that implement 585Note that this is only supported by servers that implement
582the "fsync@openssh.com" extension. 586the "fsync@openssh.com" extension.
583.Pp 587.Pp
584If either the 588If the
585.Fl P
586or
587.Fl p 589.Fl p
590.\" undocumented redundant alias
591.\" or
592.\" .Fl P
588flag is specified, then full file permissions and access times are 593flag is specified, then full file permissions and access times are
589copied too. 594copied too.
590.Pp 595.Pp
591If the 596If the
592.Fl r 597.Fl R
598.\" undocumented redundant alias
599.\" or
600.\" .Fl r
593flag is specified then directories will be copied recursively. 601flag is specified then directories will be copied recursively.
594Note that 602Note that
595.Nm 603.Nm
@@ -600,7 +608,7 @@ Display remote working directory.
600Quit 608Quit
601.Nm sftp . 609.Nm sftp .
602.It Xo Ic reget 610.It Xo Ic reget
603.Op Fl Ppr 611.Op Fl fpR
604.Ar remote-path 612.Ar remote-path
605.Op Ar local-path 613.Op Ar local-path
606.Xc 614.Xc
@@ -612,12 +620,12 @@ with the
612.Fl a 620.Fl a
613flag set. 621flag set.
614.It Xo Ic reput 622.It Xo Ic reput
615.Op Fl Ppr 623.Op Fl fpR
616.Op Ar local-path 624.Ar local-path
617.Ar remote-path 625.Op Ar remote-path
618.Xc 626.Xc
619Resume upload of 627Resume upload of
620.Op Ar local-path . 628.Ar local-path .
621Equivalent to 629Equivalent to
622.Ic put 630.Ic put
623with the 631with the
diff --git a/sftp.c b/sftp.c
index 03c7a5c72..d3e118919 100644
--- a/sftp.c
+++ b/sftp.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: sftp.c,v 1.192 2019/06/07 03:47:12 dtucker Exp $ */ 1/* $OpenBSD: sftp.c,v 1.193 2019/06/19 20:12:44 jmc Exp $ */
2/* 2/*
3 * Copyright (c) 2001-2004 Damien Miller <djm@openbsd.org> 3 * Copyright (c) 2001-2004 Damien Miller <djm@openbsd.org>
4 * 4 *
@@ -284,9 +284,7 @@ help(void)
284 "df [-hi] [path] Display statistics for current directory or\n" 284 "df [-hi] [path] Display statistics for current directory or\n"
285 " filesystem containing 'path'\n" 285 " filesystem containing 'path'\n"
286 "exit Quit sftp\n" 286 "exit Quit sftp\n"
287 "get [-afPpRr] remote [local] Download file\n" 287 "get [-afpR] remote [local] Download file\n"
288 "reget [-fPpRr] remote [local] Resume download file\n"
289 "reput [-fPpRr] [local] remote Resume upload file\n"
290 "help Display this help text\n" 288 "help Display this help text\n"
291 "lcd path Change local directory to 'path'\n" 289 "lcd path Change local directory to 'path'\n"
292 "lls [ls-options [path]] Display local directory listing\n" 290 "lls [ls-options [path]] Display local directory listing\n"
@@ -297,10 +295,12 @@ help(void)
297 "lumask umask Set local umask to 'umask'\n" 295 "lumask umask Set local umask to 'umask'\n"
298 "mkdir path Create remote directory\n" 296 "mkdir path Create remote directory\n"
299 "progress Toggle display of progress meter\n" 297 "progress Toggle display of progress meter\n"
300 "put [-afPpRr] local [remote] Upload file\n" 298 "put [-afpR] local [remote] Upload file\n"
301 "pwd Display remote working directory\n" 299 "pwd Display remote working directory\n"
302 "quit Quit sftp\n" 300 "quit Quit sftp\n"
301 "reget [-fpR] remote [local] Resume download file\n"
303 "rename oldpath newpath Rename remote file\n" 302 "rename oldpath newpath Rename remote file\n"
303 "reput [-fpR] local [remote] Resume upload file\n"
304 "rm path Delete remote file\n" 304 "rm path Delete remote file\n"
305 "rmdir path Remove remote directory\n" 305 "rmdir path Remove remote directory\n"
306 "symlink oldpath newpath Symlink remote file\n" 306 "symlink oldpath newpath Symlink remote file\n"