Message ID | 20190321020218.5154-6-tytso@mit.edu |
---|---|
State | Accepted, archived |
Headers | show |
Series | [1/9] e2scrub: check to make sure lvm2 is installed | expand |
On Wed, Mar 20, 2019 at 10:02:15PM -0400, Theodore Ts'o wrote: > Signed-off-by: Theodore Ts'o <tytso@mit.edu> > --- > scrub/e2scrub_all.8.in | 9 +++++++-- > scrub/e2scrub_all.in | 8 +++++--- > 2 files changed, 12 insertions(+), 5 deletions(-) > > diff --git a/scrub/e2scrub_all.8.in b/scrub/e2scrub_all.8.in > index ba3b8735e..2787a7108 100644 > --- a/scrub/e2scrub_all.8.in > +++ b/scrub/e2scrub_all.8.in > @@ -20,12 +20,17 @@ See the > manual page for more information about how the checking is performed. > .SH OPTIONS > .TP > -\fB-A\fR > -Scrub all ext[234] filesystems even if they are not mounted. > +\fB-n\fR > +Print what commands > +.B e2scrub_all > +would execute (but don't actually execute them). > .TP > \fB-r\fR > Remove e2scrub snapshots but do not check anything. > .TP > +\fB-A\fR > +Scrub all ext[234] filesystems even if they are not mounted. > +.TP Nitpicking, but this is also rearranging the order of manpage and help text. The changes themselves look ok, but I don't know how picky you are these days about this sort of thing being separate changes. :) Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com> --D > \fB-V\fR > Print version information and exit. > .SH SEE ALSO > diff --git a/scrub/e2scrub_all.in b/scrub/e2scrub_all.in > index d725a7f2e..8bc868aa0 100644 > --- a/scrub/e2scrub_all.in > +++ b/scrub/e2scrub_all.in > @@ -29,8 +29,9 @@ scrub_args="" > > print_help() { > echo "Usage: $0 [OPTIONS]" > - echo " -A: Scrub all ext[234] filesystems even if not mounted." > + echo " -n: Show what commands e2scrub_all would execute." > echo " -r: Remove e2scrub snapshots." > + echo " -A: Scrub all ext[234] filesystems even if not mounted." > echo " -V: Print version information and exit." > } > > @@ -60,10 +61,11 @@ exitcode() { > exit "${ret}" > } > > -while getopts "ArV" opt; do > +while getopts "nrAV" opt; do > case "${opt}" in > - "A") scrub_all=1;; > + "n") DBG="echo Would execute: " ;; > "r") scrub_args="${scrub_args} -r";; > + "A") scrub_all=1;; > "V") print_version; exitcode 0;; > *) print_help; exitcode 2;; > esac > -- > 2.19.1 >
diff --git a/scrub/e2scrub_all.8.in b/scrub/e2scrub_all.8.in index ba3b8735e..2787a7108 100644 --- a/scrub/e2scrub_all.8.in +++ b/scrub/e2scrub_all.8.in @@ -20,12 +20,17 @@ See the manual page for more information about how the checking is performed. .SH OPTIONS .TP -\fB-A\fR -Scrub all ext[234] filesystems even if they are not mounted. +\fB-n\fR +Print what commands +.B e2scrub_all +would execute (but don't actually execute them). .TP \fB-r\fR Remove e2scrub snapshots but do not check anything. .TP +\fB-A\fR +Scrub all ext[234] filesystems even if they are not mounted. +.TP \fB-V\fR Print version information and exit. .SH SEE ALSO diff --git a/scrub/e2scrub_all.in b/scrub/e2scrub_all.in index d725a7f2e..8bc868aa0 100644 --- a/scrub/e2scrub_all.in +++ b/scrub/e2scrub_all.in @@ -29,8 +29,9 @@ scrub_args="" print_help() { echo "Usage: $0 [OPTIONS]" - echo " -A: Scrub all ext[234] filesystems even if not mounted." + echo " -n: Show what commands e2scrub_all would execute." echo " -r: Remove e2scrub snapshots." + echo " -A: Scrub all ext[234] filesystems even if not mounted." echo " -V: Print version information and exit." } @@ -60,10 +61,11 @@ exitcode() { exit "${ret}" } -while getopts "ArV" opt; do +while getopts "nrAV" opt; do case "${opt}" in - "A") scrub_all=1;; + "n") DBG="echo Would execute: " ;; "r") scrub_args="${scrub_args} -r";; + "A") scrub_all=1;; "V") print_version; exitcode 0;; *) print_help; exitcode 2;; esac
Signed-off-by: Theodore Ts'o <tytso@mit.edu> --- scrub/e2scrub_all.8.in | 9 +++++++-- scrub/e2scrub_all.in | 8 +++++--- 2 files changed, 12 insertions(+), 5 deletions(-)