It's sometimes helpful to run ftp -o - http://somwhat/ for debugging
purposes, but the progress bar gets in the way and makes it ugly. Even with -V
to disable verbose, it still prints progress. Add -M (complement of -m) to
always turn off progress.


Index: ftp.1
===================================================================
RCS file: /cvs/src/usr.bin/ftp/ftp.1,v
retrieving revision 1.96
diff -u -p -r1.96 ftp.1
--- ftp.1       31 Jan 2015 19:33:45 -0000      1.96
+++ ftp.1       17 Feb 2015 08:05:06 -0000
@@ -38,7 +38,7 @@
 .Nd Internet file transfer program
 .Sh SYNOPSIS
 .Nm ftp
-.Op Fl 46AadEegimnptVv
+.Op Fl 46AadEegiMmnptVv
 .Op Fl D Ar title
 .Op Fl k Ar seconds
 .Op Fl P Ar port
@@ -181,6 +181,11 @@ transfer.
 By default,
 .Nm
 will send a byte every 60 seconds.
+.It Fl M
+Causes
+.Nm
+to never display the progress meter in cases where it would do
+so by default.
 .It Fl m
 Causes
 .Nm
Index: main.c
===================================================================
RCS file: /cvs/src/usr.bin/ftp/main.c,v
retrieving revision 1.97
diff -u -p -r1.97 main.c
--- main.c      9 Feb 2015 08:24:21 -0000       1.97
+++ main.c      17 Feb 2015 08:04:14 -0000
@@ -202,7 +202,7 @@ main(volatile int argc, char *argv[])
        httpuseragent = NULL;
 
        while ((ch = getopt(argc, argv,
-                   "46AaCc:dD:Eegik:mno:pP:r:S:s:tU:vV")) != -1) {
+                   "46AaCc:dD:Eegik:Mmno:pP:r:S:s:tU:vV")) != -1) {
                switch (ch) {
                case '4':
                        family = PF_INET;
@@ -267,6 +267,9 @@ main(volatile int argc, char *argv[])
                                        optarg);
                                usage();
                        }
+                       break;
+               case 'M':
+                       progress = 0;
                        break;
                case 'm':
                        progress = -1;


Reply via email to