Skip to contentSkip to conversation

small fixes to some messages and man pages, and some questions

PATCH In review Benno Schulenberg 2 participants 5 messages Aug 11, 2011 – Aug 16, 2011 Util-Linux package

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 small fixes to some messages and man pages, and some questions

Hi,

Attached bunch of patches improve or correct several error messages or usage synopses.

About the fourth patch I'm unsure. The current description of the option '--no-reread' is "skip partition re-read at boot". With "boot" is meant "program startup", so that needs to be corrected. But the real effect of --no-reread seems to be to just check that the relevant partition is not in use. Is that correct?

By the way, I don't understand why the options -g (--show-geometry) and -G (show-pt-geometry) are listed under "Dangerous options". How can they be dangerous when they just show things?

Also I do not understand the descriptions of the new options --nested, --chained, and --onesector. How is "disjoint" different from "mutually disjoint"? Would the following attempts at description be correct?

--nested each logical and extended partition falls within an extended one
--chained each logical partition falls within an extended one
--onesector not any partition falls within another

The two new options --inside-outer and --not-inside-outer have been misdocumented as --inside-order and --not-inside-order. The last and seventeenth patch fixes that.

The fourteenth patch adds the missing "[options]" to the usage synopsis of scriptreplay, and also indicates the timingfile argument as optional. However, I find this a bit misleading: the timingfile is only optional when it is specified via the -t option. Wouldn't it be better to describe the command with two alternative synopses, as follows?

Usage: scriptreplay timingfile [typescript [divisor]]
or: scriptreplay [options] [timingfile] [typescript] [divisor]

Regards,

Benno

Signature · 2 lines
http://www.fastmail.fm - Accessible with your email software
                          or over the web

From 8675f4f28e656a3d754a569afd0a732f786fa572 Mon Sep 17 00:00:00 2001
From: Benno Schulenberg <[email protected]>
Date: Wed, 10 Aug 2011 20:55:48 +0200
Subject: [PATCH 01/17] mkfs.cramfs: clearer error message, "cannot close" instead of "closing"

---
 disk-utils/mkfs.cramfs.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
disk-utils/mkfs.cramfs.c +1 -1
index 9bb9153..5193634 100644
@@ -665,7 +665,7 @@ static unsigned int write_file(char *file, char *base, unsigned int offset)
 	memcpy(base + offset, buf, image_length);
 	munmap(buf, image_length);
 	if (close (fd) < 0)
-		err(MKFS_ERROR, _("closing file %s"), file);
+		err(MKFS_ERROR, _("cannot close file %s"), file);
 	/* Pad up the image_length to a 4-byte boundary */
 	while (image_length & 3) {
 		*(base + offset + image_length) = '\0';
Signature · 1 line
1.7.0.4

From fb2664acf48c1c4c278caabade80f75ddd3ea467 Mon Sep 17 00:00:00 2001
From: Benno Schulenberg <[email protected]>
Date: Wed, 10 Aug 2011 20:57:07 +0200
Subject: [PATCH 02/17] fdisksgilabel: correct the grammar of an error message

---
 fdisk/fdisksgilabel.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
fdisk/fdisksgilabel.c +1 -1
index cc95598..8179bc1 100644
@@ -533,7 +533,7 @@ int
 sgi_change_sysid(int i, int sys)
 {
 	if (sgi_get_num_sectors(i) == 0) /* caught already before, ... */ {
-		printf(_("Sorry You may change the Tag of non-empty partitions.\n"));
+		printf(_("Sorry, only for non-empty partitions you can change the tag.\n"));
 		return 0;
 	}
 	if (((sys != ENTIRE_DISK) && (sys != SGI_VOLHDR))
Signature · 1 line
1.7.0.4

From aec94f1a8a9c2ae333f2659d283ad8f355869d01 Mon Sep 17 00:00:00 2001
From: Benno Schulenberg <[email protected]>
Date: Wed, 10 Aug 2011 20:58:49 +0200
Subject: [PATCH 03/17] sfdisk: gettextize each warning as a whole

---
 fdisk/sfdisk.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)
fdisk/sfdisk.c +4 -4
index 6cd85a2..6ae0be4 100644
@@ -1243,8 +1243,8 @@ partitions_ok(struct disk_desc *z) {
 		q = p->ep;
 		if (p->start < q->start
 		    || p->start + p->size > q->start + q->size) {
-		    my_warn(_("Warning: partition %s "), PNO(p));
-		    my_warn(_("is not contained in partition %s\n"), PNO(q));
+		    my_warn(_("Warning: partition %s is not contained in "
+			      "partition %s\n"), PNO(p), PNO(q));
 		    return 0;
 		}
 	    }
@@ -1255,8 +1255,8 @@ partitions_ok(struct disk_desc *z) {
 	    for (q = p + 1; q < partitions + partno; q++)
 		if (q->size && !is_extended(q->p.sys_type))
 		    if (!((p->start > q->start) ? disj(q, p) : disj(p, q))) {
-			my_warn(_("Warning: partitions %s "), PNO(p));
-			my_warn(_("and %s overlap\n"), PNO(q));
+			my_warn(_("Warning: partitions %s and %s overlap\n"),
+				PNO(p), PNO(q));
 			return 0;
 		    }
 
Signature · 1 line
1.7.0.4

From 2f124ce033ced627e121522b07795e610b0c5b9d Mon Sep 17 00:00:00 2001
From: Benno Schulenberg <[email protected]>
Date: Wed, 10 Aug 2011 20:59:49 +0200
Subject: [PATCH 04/17] sfdisk: improve descriptions of options --no-reread and --show-extended

Also keep the two geometry options (-g and -G) together by moving -A.

---
 fdisk/sfdisk.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)
fdisk/sfdisk.c +4 -4
index 6ae0be4..b01723d 100644
@@ -2378,13 +2378,13 @@ usage(FILE * out) {
 
     fprintf(out, _("\nDangerous options:\n"
 		   "  -f, --force             disable all consistency checking\n"
+		   "      --no-reread         do not check whether the partition is in use\n"
 		   "  -g, --show-geometry     print the kernel's idea of the geometry\n"
-		   "  -A, --activate[=device] activate bootable flag\n"
 		   "  -G, --show-pt-geometry  print geometry guessed from the partition table\n"
+		   "  -A, --activate[=device] activate bootable flag\n"
 		   "  -U, --unhide[=device]   set partition unhidden\n"
-		   "      --no-reread         skip partition re-read at boot\n"
-		   "  -x, --show-extended     also list extended partitions on output\n"
-		   "                          or expect descriptors for them on input\n"
+		   "  -x, --show-extended     also list extended partitions in the output,\n"
+		   "                            or expect descriptors for them in the input\n"
 		   "      --leave-last        do not allocate the last cylinder\n"
 		   "      --IBM               same as --leave-last\n"
 		   "      --in-order          partitions are in order\n"
Signature · 1 line
1.7.0.4

From e2bac4d95b0d6da74215337a6211e1312ad771e7 Mon Sep 17 00:00:00 2001
From: Benno Schulenberg <[email protected]>
Date: Wed, 10 Aug 2011 21:02:10 +0200
Subject: [PATCH 05/17] sfdisk: remove inconsistent and wasteful newlines in the _() calls

---
 fdisk/sfdisk.c |  113 +++++++++++++++++++++----------------------------------
 1 files changed, 43 insertions(+), 70 deletions(-)
fdisk/sfdisk.c +43 -70

254 lines not on this page · raw message

Signature · 1 line
1.7.0.4

From 5776dd6bcb05f4e2a666608ac2608cf123c3c15f Mon Sep 17 00:00:00 2001
From: Benno Schulenberg <[email protected]>
Date: Wed, 10 Aug 2011 21:04:42 +0200
Subject: [PATCH 06/17] ul: in usage() not overwriting but overriding is meant

Also always use lowercase.

---
 text-utils/ul.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
text-utils/ul.c +2 -2
index 1cbacfc..9e08bc1 100644
@@ -137,8 +137,8 @@ usage(FILE *out)
 
 	fprintf(out, _(
 		"\nOptions:\n"
-		" -t, --terminal TERMINAL    overwrite TERM environment variable\n"
-		" -i, --indicated            Underlining is indicated by a separate line\n"
+		" -t, --terminal TERMINAL    override the TERM environment variable\n"
+		" -i, --indicated            underlining is indicated via a separate line\n"
 		" -V, --version              output version information and exit\n"
 		" -h, --help                 display this help and exit\n\n"));
 
Signature · 1 line
1.7.0.4

From 88f0d378e8ed1474bce2a16f0b7269576dc6a66e Mon Sep 17 00:00:00 2001
From: Benno Schulenberg <[email protected]>
Date: Wed, 10 Aug 2011 21:06:07 +0200
Subject: [PATCH 07/17] ul: make usage() say that more than one input file is allowed

---
 text-utils/ul.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
text-utils/ul.c +1 -1
index 9e08bc1..a52000b 100644
@@ -133,7 +133,7 @@ usage(FILE *out)
 {
 	fprintf(out, _(
 		"\nUsage:\n"
-		" %s [options] [file]\n"), program_invocation_short_name);
+		" %s [options] [file...]\n"), program_invocation_short_name);
 
 	fprintf(out, _(
 		"\nOptions:\n"
Signature · 1 line
1.7.0.4

From fd4c3ccf8b3b9ca9b6f134fb297e5fe90e3a78c0 Mon Sep 17 00:00:00 2001
From: Benno Schulenberg <[email protected]>
Date: Wed, 10 Aug 2011 21:07:13 +0200
Subject: [PATCH 08/17] ul: add -h and -V to the man page; use "file" and lowercase

---
 text-utils/ul.1 |   10 +++++++---
 1 files changed, 7 insertions(+), 3 deletions(-)
text-utils/ul.1 +7 -3
index 7d4e57a..7992d72 100644
@@ -39,11 +39,11 @@
 .Nd do underlining
 .Sh SYNOPSIS
 .Nm ul
-.Op Fl i
+.Op Fl hiV
 .Op Fl t Ar terminal
-.Op Ar name Ar ...
+.Op Ar file Ar ...
 .Sh DESCRIPTION
-.Nm Ul
+.Nm ul
 reads the named files (or standard input if none are given)
 and translates occurrences of underscores to the sequence
 which indicates underlining for the terminal in use, as specified
@@ -63,6 +63,8 @@ If the terminal cannot underline, underlining is ignored.
 .Pp
 The following options are available:
 .Bl -tag -width Ds
+.It Fl h
+Display a help text and exit.
 .It Fl i
 Underlining is indicated by a separate line containing appropriate
 dashes `\-'; this is useful when you want to look at the underlining
@@ -72,6 +74,8 @@ output stream on a crt-terminal.
 .It Fl t Ar terminal
 Overrides the terminal type specified in the environment with
 .Ar terminal .
+.It Fl V
+Display version information and exit.
 .El
 .Sh ENVIRONMENT
 The following environment variable is used:
Signature · 1 line
1.7.0.4

From db67b9c1332a703b7071c2ff02db41b0e91819ef Mon Sep 17 00:00:00 2001
From: Benno Schulenberg <[email protected]>
Date: Wed, 10 Aug 2011 21:10:29 +0200
Subject: [PATCH 09/17] ul: remove superfluous return as usage() does not return

---
 text-utils/ul.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)
text-utils/ul.c +1 -2
index a52000b..6132166 100644
@@ -192,12 +192,11 @@ int main(int argc, char **argv)
 		case 'V':
 			printf(_("%s from %s\n"), program_invocation_short_name,
 						  PACKAGE_STRING);
-			return(EXIT_SUCCESS);
+			return EXIT_SUCCESS;
 		case 'h':
 			usage(stdout);
 		default:
 			usage(stderr);
-			return EXIT_FAILURE;
 		}
 	setupterm(termtype, STDOUT_FILENO, &ret);
 	switch (ret) {
Signature · 1 line
1.7.0.4

From 372194ba12cb789f5e03e59b70dcc60461d9d386 Mon Sep 17 00:00:00 2001
From: Benno Schulenberg <[email protected]>
Date: Wed, 10 Aug 2011 21:11:45 +0200
Subject: [PATCH 10/17] tailf: harmonize option argument and explanation in usage message

---
 text-utils/tailf.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
text-utils/tailf.c +2 -2
index fbe81c8..c8f3e91 100644
@@ -200,8 +200,8 @@ static void __attribute__ ((__noreturn__)) usage(FILE *out)
 
 	fprintf(out, _(
 		"\nOptions:\n"
-		" -n, --lines NUMBER  output the last N lines\n"
-		" -NUMBER             same as -n NUMBER\n"
+		" -n, --lines NUMBER  output the last NUMBER lines\n"
+		" -NUMBER             same as `-n NUMBER'\n"
 		" -V, --version       output version information and exit\n"
 		" -h, --help          display this help and exit\n\n"));
 
Signature · 1 line
1.7.0.4

From 68cbfe5ad7c2aadbabee083d156ebd5ed893b691 Mon Sep 17 00:00:00 2001
From: Benno Schulenberg <[email protected]>
Date: Wed, 10 Aug 2011 21:12:56 +0200
Subject: [PATCH 11/17] hexdump: fix "beginnin" typo in usage message

---
 text-utils/hexsyntax.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
text-utils/hexsyntax.c +1 -1
index 211e5d5..5cdd1de 100644
@@ -145,7 +145,7 @@ void __attribute__((__noreturn__)) usage(FILE *out)
 		       " -e format       format string to be used for displaying data\n"
 		       " -f format_file  file that contains format strings\n"
 		       " -n length       interpret only length bytes of input\n"
-		       " -s offset       skip offset bytes from the beginnin\n"
+		       " -s offset       skip offset bytes from the beginning\n"
 		       " -v              display without squeezing similar lines\n"
 		       " -V              output version information and exit\n\n"));
 
Signature · 1 line
1.7.0.4

From a592a8c71f020e3b44ca0f952de459cc94c39fdb Mon Sep 17 00:00:00 2001
From: Benno Schulenberg <[email protected]>
Date: Wed, 10 Aug 2011 21:13:44 +0200
Subject: [PATCH 12/17] write: remove inconsistent periods from two error messages

---
 term-utils/write.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
term-utils/write.c +2 -2
index 8843362..b44f0e0 100644
@@ -143,7 +143,7 @@ int main(int argc, char **argv)
 			exit(EXIT_FAILURE);
 		if (!msgsok)
 			errx(EXIT_FAILURE,
-			     _("you have write permission turned off."));
+			     _("you have write permission turned off"));
 
 	} else
 		mytty = "<no tty>";
@@ -161,7 +161,7 @@ int main(int argc, char **argv)
 			argv[2] += 5;
 		if (utmp_chk(argv[1], argv[2]))
 			errx(EXIT_FAILURE,
-			     _("%s is not logged in on %s."),
+			     _("%s is not logged in on %s"),
 			     argv[1], argv[2]);
 		if (term_chk(argv[2], &msgsok, &atime, 1))
 			exit(EXIT_FAILURE);
Signature · 1 line
1.7.0.4

From 215d39ef6686e02db8a5842e5051242763ba2bd6 Mon Sep 17 00:00:00 2001
From: Benno Schulenberg <[email protected]>
Date: Wed, 10 Aug 2011 21:21:17 +0200
Subject: [PATCH 13/17] script: indicate that the file argument to --timing is optional

Also improve some other descriptions in the usage message.

---
 term-utils/script.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)
term-utils/script.c +4 -4
index 1f88253..deba155 100644
@@ -133,13 +133,13 @@ usage(FILE *out)
 
 	fprintf(out, _(
 		"\nOptions:\n"
-		" -a, --append            append output\n"
-		" -c, --command COMMAND   run command rather than interactive shell\n"
+		" -a, --append            append the output\n"
+		" -c, --command COMMAND   run COMMAND rather than interactive shell\n"
 		" -r, --return            return exit code of the child process\n"
 		" -f, --flush             run flush after each write\n"
-		"     --force             use output file even it would be a link\n"
+		"     --force             use output file even when it is a link\n"
 		" -q, --quiet             be quiet\n"
-		" -t, --timing=FILE       output timing data to stderr, or to file\n"
+		" -t, --timing[=FILE]     output timing data to stderr (or to FILE)\n"
 		" -V, --version           output version information and exit\n"
 		" -h, --help              display this help and exit\n\n"));
 
Signature · 1 line
1.7.0.4

From 498625334309e88b21acc859a24b986721b3d184 Mon Sep 17 00:00:00 2001
From: Benno Schulenberg <[email protected]>
Date: Wed, 10 Aug 2011 21:31:55 +0200
Subject: [PATCH 14/17] scriptreplay: add [options] to usage(), and timingfile is optional too

---
 term-utils/scriptreplay.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
term-utils/scriptreplay.c +1 -1
index 86c82fd..d7fb031 100644
@@ -36,7 +36,7 @@
 void __attribute__((__noreturn__))
 usage(FILE *out)
 {
-	fprintf(out, _("Usage: %s timingfile [typescript] [divisor]\n"),
+	fprintf(out, _("Usage: %s [options] [timingfile] [typescript] [divisor]\n"),
 			program_invocation_short_name);
 	fprintf(out, _(
 		"\nOptions:\n"
Signature · 1 line
1.7.0.4

From 8cf2b7aa035653cfc26226c275c412569447e492 Mon Sep 17 00:00:00 2001
From: Benno Schulenberg <[email protected]>
Date: Wed, 10 Aug 2011 21:46:13 +0200
Subject: [PATCH 15/17] scriptreplay: improve synopsis and formatting in man page

---
 term-utils/scriptreplay.1 |   23 ++++++++++++-----------
 1 files changed, 12 insertions(+), 11 deletions(-)
term-utils/scriptreplay.1 +12 -11
index 5610eb1..785d60e 100644
@@ -145,9 +145,10 @@ scriptreplay \- play back typescripts, using timing information
 .SH "SYNOPSIS"
 .IX Header "SYNOPSIS"
 .B scriptreplay
-.I timingfile
-.RI [ typescript
-.RI [ divisor ]]
+.RI [ option ...]
+.RI [ timingfile ]
+.RI [ typescript ]
+.RI [ divisor ]
 .SH "DESCRIPTION"
 .IX Header "DESCRIPTION"
 This program replays a typescript, using timing information to ensure that
@@ -175,29 +176,29 @@ parameter.
 By default, the typescript to display is assumed to be named \*(L"typescript\*(R",
 but other filenames may be specified, as the second parameter.
 .PP
-If the third parameter is specified, it is used as a speed-up multiplier. For
-example, a speed-up of 2 makes
+If the third parameter is specified, it is used as a speed-up multiplier.
+For example, a speed-up of 2 makes
 .B scriptreplay
 go twice as fast and a speed-up of 0.1 makes it go ten times slower
 than the original session.
 .SH OPTIONS
 The options will overide old style arguments.
 .TP
-.BR \-t , " \-\-timing FILE"
+.BR \-t , " \-\-timing " \fIfile\fR
 File containing script timing output.
 .TP
-.BR \-s , " \-\-typescript FILE"
-Script terminal output file.
+.BR \-s , " \-\-typescript " \fIfile\fR
+File containing the script terminal output.
 .TP
-.BR \-d , " \-\-divisor NUM"
+.BR \-d , " \-\-divisor " \fInumber\fR
 Speed up or slow down replay displaying by divisor. The argument
 is floating point number.
 .TP
 .BR \-V , " \-\-version"
-Print version information.
+Display version information and exit.
 .TP
 .BR \-h , " \-\-help"
-Print a help message.
+Display a help message exit.
 .SH "EXAMPLE"
 .IX Header "EXAMPLE"
 .Vb 7
Signature · 1 line
1.7.0.4

From 97795839cc61476c6d0cba4351bb9a1c29491ec6 Mon Sep 17 00:00:00 2001
From: Benno Schulenberg <[email protected]>
Date: Wed, 10 Aug 2011 22:37:31 +0200
Subject: [PATCH 16/17] script: normalize formatting of the man page

Also improve the description of the --timing option, and discard a then superfluous paragraph.

---
 term-utils/script.1 |   37 ++++++++++++++++++-------------------
 1 files changed, 18 insertions(+), 19 deletions(-)
term-utils/script.1 +18 -19
index f618ec3..5f96b9c 100644
@@ -40,16 +40,16 @@
 .Sh SYNOPSIS
 .Nm script
 .Op Fl a
-.Op Fl c Ar COMMAND
+.Op Fl c Ar command
 .Op Fl e
 .Op Fl f
 .Op Fl q
-.Op Fl t[=FILE]
+.Op Fl t Ns Op Ns = Ns Ar file
 .Op Fl V
 .Op Fl h
 .Op Ar file
 .Sh DESCRIPTION
-.Nm Script
+.Nm script
 makes a typescript of everything printed on your terminal.
 It is useful for students who need a hardcopy record of an interactive
 session as proof of an assignment, as the typescript file 
@@ -73,32 +73,31 @@ Append the output to
 or
 .Pa typescript ,
 retaining the prior contents.
-.It Fl c, Fl Fl command Ar COMMAND
-Run the COMMAND rather than an interactive shell.
+.It Fl c, Fl Fl command Ar command
+Run the
+.Ar command
+rather than an interactive shell.
 This makes it easy for a script to capture the output of a program that
 behaves differently when its stdout is not a tty.
 .It Fl e, Fl Fl return
-Return the exit code of the child process. Uses the same format as bash
+Return the exit code of the child process.  Uses the same format as bash
 termination on signal termination exit code is 128+n.
 .It Fl f, Fl Fl flush
-Flush output after each write. This is nice for telecooperation:
-One person does `mkfifo foo; script -f foo' and another can
+Flush output after each write.  This is nice for telecooperation:
+one person does `mkfifo foo; script -f foo', and another can
 supervise real-time what is being done using `cat foo'.
 .It Fl Fl force
-Allow default output destination, e.g. typescript file, to be
-hard or symbolic link. The command will follow symbolic link.
+Allow the default output destination, i.e. the typescript file, to be a
+hard or symbolic link.  The command will follow a symbolic link.
 .It Fl q, Fl Fl quiet
 Be quiet.
-.It Fl t, Fl Fl timing[=FILE]
-Output timing data to standard error. This data contains two fields,
-separated by a space. The first field indicates how much time elapsed since
-the previous output. The second field indicates how many characters were
-output this time. This information can be used to replay typescripts with
+.It Fl t, Fl Fl timing Ns Op Ns = Ns Ar file
+Output timing data to standard error, or to \fIfile\fR when given.
+This data contains two fields, separated by a space.
+The first field indicates how much time elapsed since the previous output.
+The second field indicates how many characters were output this time.
+This information can be used to replay typescripts with
 realistic typing and output delays.
-
-The timing option is able to take file path as an argument. The
-file is used as output detination instead of standard error when
-it is supplied.
 .It Fl V, Fl Fl version
 Output version information and exit.
 .It Fl h, Fl Fl help
Signature · 1 line
1.7.0.4

From 43dd49413578c384a059ba7c0ffcad60dab718ed Mon Sep 17 00:00:00 2001
From: Benno Schulenberg <[email protected]>
Date: Thu, 11 Aug 2011 21:47:15 +0200
Subject: [PATCH 17/17] sfdisk: correct '--inside-order' to '--inside-outer' in documentation

---
 fdisk/sfdisk.8 |    4 ++--
 fdisk/sfdisk.c |    4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)
fdisk/sfdisk.8 +2 -2
index c3f06b3..02e8d11 100644
@@ -322,10 +322,10 @@ Caution, see warning section. To be documented.
 .B \-\-not\-in\-order
 Caution, see warning section. To be documented.
 .TP
-.B \-\-inside\-order
+.B \-\-inside\-outer
 Caution, see warning section. Chaining order.
 .TP
-.B \-\-not\-inside\-order
+.B \-\-not\-inside\-outer
 Caution, see warning section. Chaining order.
 .TP
 .B \-\-nested
fdisk/sfdisk.c +2 -2
index cd494d0..08e1b0c 100644
@@ -2368,8 +2368,8 @@ usage(FILE * out) {
 		   "      --IBM               same as --leave-last\n"
 		   "      --in-order          partitions are in order\n"
 		   "      --not-in-order      partitions are not in order\n"
-		   "      --inside-order      all logicals inside outermost extended\n"
-		   "      --not-inside-order  not all logicals inside outermost extended\n"
+		   "      --inside-outer      all logicals inside outermost extended\n"
+		   "      --not-inside-outer  not all logicals inside outermost extended\n"
 		   "      --nested            every partition is disjoint from all others\n"
 		   "      --chained           like nested, but extended partitions may lie outside\n"
 		   "      --onesector         partitions are mutually disjoint\n"
Signature · 1 line
1.7.0.4
maintainer
#1 lore raw
Quoted 5 lines

About the fourth patch I'm unsure. The current description of the option '--no-reread' is "skip partition re-read at boot". With "boot" is meant "program startup", so that needs to be corrected. But the real effect of --no-reread seems to be to just check that the relevant partition is not in use. Is that correct?

Yes.

Quoted 3 lines

By the way, I don't understand why the options -g (--show-geometry) and -G (show-pt-geometry) are listed under "Dangerous options". How can they be dangerous when they just show things?

Hmm.. not sure.

Quoted 7 lines

Also I do not understand the descriptions of the new options --nested, --chained, and --onesector. How is "disjoint" different from "mutually disjoint"? Would the following attempts at description be correct?

--nested each logical and extended partition falls within an extended one
--chained each logical partition falls within an extended one
--onesector not any partition falls within another

The original comment from code:

/* There are two common ways to structure extended partitions:
as nested boxes, and as a chain. Sometimes the partitions must be given in order. Sometimes all logical partitions must lie inside the outermost extended partition.
NESTED: every partition is contained in the surrounding partitions
and is disjoint from all others.
CHAINED: every data partition is contained in the surrounding partitions
and disjoint from all others, but extended partitions may lie outside (insofar as allowed by all_logicals_inside_outermost_extended).
ONESECTOR: all data partitions are mutually disjoint; extended partitions
each use one sector only (except perhaps for the outermost one).
*/

The default is NESTED and "inside the outermost extended partition".

Quoted 8 lines

The fourteenth patch adds the missing "[options]" to the usage synopsis of scriptreplay, and also indicates the timingfile argument as optional. However, I find this a bit misleading: the timingfile is only optional when it is specified via the -t option. Wouldn't it be better to describe the command with two alternative synopses, as follows?

Usage: scriptreplay timingfile [typescript [divisor]]
or: scriptreplay [options] [timingfile] [typescript] [divisor]

scriptreplay [options] [-t] timingfile [typescript [divisor]]

?

Karel

Signature · 2 lines
 Karel Zak  <[email protected]>
 http://karelzak.blogspot.com
#2 lore raw
Quoted 9 lines
Quoted 3 lines

Also I do not understand the descriptions of the new options --nested, --chained, and --onesector. [...]

The original comment from code:

/* [...]
NESTED: every partition is contained in the surrounding partitions
and is disjoint from all others.

I still fail to understand. If "contained in the surrounding partitions" means "contained in the containing partitions", it says nothing. If it means "contained in the partitions that come before and after", this seems impossible to me. The only way I can make sense of the above comment is to read it as follows:

NESTED: every extended partition is contained within a surrounding extended partition [except of course the outermost one] and is disjoint from all other extended partitions at the same nesting level.

(Here I take "disjoint" to mean "does not overlap", but then I still fail to understand how "mutually disjoint" is different.)

Quoted 2 lines

CHAINED: every data partition is contained in the surrounding partitions
and disjoint from all others, but extended partitions may lie outside

Is a data partition the same as a logical partition?

Quoted 8 lines
Quoted 6 lines

However, I find this a bit misleading: the timingfile is only optional when it is specified via the -t option. Wouldn't it be better to describe the command with two alternative synopses, as follows?

Usage: scriptreplay timingfile [typescript [divisor]]
or: scriptreplay [options] [timingfile] [typescript] [divisor]

scriptreplay [options] [-t] timingfile [typescript [divisor]]

Yes, that would do. It does not cover the possibilty of the typescript file being passed with option -s and the divisor as a direct argument, but it's good enough for my taste.

Regards,

Benno

Signature · 1 line
http://www.fastmail.fm - Same, same, but different...
maintainer
#3 lore raw
Quoted 11 lines · Benno Schulenberg
Quoted 9 lines
Quoted 3 lines

Also I do not understand the descriptions of the new options --nested, --chained, and --onesector. [...]

The original comment from code:

/* [...]
NESTED: every partition is contained in the surrounding partitions
and is disjoint from all others.

I still fail to understand.

The each logical partition is defined by extended partition table (EBR) http://en.wikipedia.org/wiki/Extended_boot_record

EBR contains usually two partitions:
1/ data partition (used as a logical partition) 2/ extended partition (used as a pointer to the next EBR)

so if you have 5 logical partitions then there is usually 5 small partition tables and 5 extended partitions :-) The partitions are usually NESTED.

The top-level (outermost) extended partition is the partition visible for end-users in fdisk output.

Quoted 6 lines

If "contained in the surrounding partitions"
means "contained in the containing partitions", it says nothing. If it means "contained in the partitions that come before and after", this seems impossible to me. The only way I can make sense of the above comment is to read it as follows:

Quoted 6 lines

NESTED: every extended partition is contained within a surrounding extended partition [except of course the outermost one] and is disjoint from all other extended partitions at the same nesting level.

(Here I take "disjoint" to mean "does not overlap", but then I still fail to understand how "mutually disjoint" is different.)

NESTED: every extended partition is contained within a parental
extended partition.

IMHO nothing other is usable in Linux.

Quoted 5 lines
Quoted 3 lines

CHAINED: every data partition is contained in the surrounding partitions
and disjoint from all others, but extended partitions may lie outside

Is a data partition the same as a logical partition?

Yes.

IMHO the comment is mess as well as the implementation :-) Don't think about it too much. We need to rewrite sfdisk and cfdisk....

Quoted 1 line
Quoted 1 line

scriptreplay [options] [-t] timingfile [typescript [divisor]]

Fixed in the usage().

Karel

Signature · 2 lines
 Karel Zak  <[email protected]>
 http://karelzak.blogspot.com
maintainer
#4 lore raw
In reply to Benno Schulenberg
Quoted 2 lines · Benno Schulenberg

Attached bunch of patches improve or correct several error messages or usage synopses.

All applied, but except patches 0015,0016 (the scriptreplay changes) -- I'll wait for your feedback about this issue.

Karel

Signature · 2 lines
 Karel Zak  <[email protected]>
 http://karelzak.blogspot.com