diff options
author | Benno Schulenberg <bensberg@justemail.net> | 2007-05-16 22:28:35 +0200 |
---|---|---|
committer | Jim Meyering <jim@meyering.net> | 2007-05-16 22:46:15 +0200 |
commit | 4fb83ba5d4e3461797a9161c86d70749ac6c3fd8 (patch) | |
tree | 72eebe19121e36ac8c3710b893d4b319a1da74c4 /partprobe | |
parent | 25fc9b92d45c8ced38289fd5446c573e8258d894 (diff) | |
download | parted-4fb83ba5d4e3461797a9161c86d70749ac6c3fd8.tar.gz |
partprobe: new option: --dry-run, synonym for now-deprecated --no-update; improve its description
Diffstat (limited to 'partprobe')
-rw-r--r-- | partprobe/partprobe.c | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/partprobe/partprobe.c b/partprobe/partprobe.c index 1659100..6035b39 100644 --- a/partprobe/partprobe.c +++ b/partprobe/partprobe.c @@ -57,7 +57,10 @@ static struct option const long_options[] = { + /* Note: the --no-update option is deprecated, and deliberately + * not documented. FIXME: remove --no-update in 2009. */ {"no-update", no_argument, NULL, 'd'}, + {"dry-run", no_argument, NULL, 'd'}, {"summary", no_argument, NULL, 's'}, {"help", no_argument, NULL, 'h'}, {"version", no_argument, NULL, 'v'}, @@ -68,7 +71,7 @@ static struct option const long_options[] = char *program_name; /* initialized to 0 according to the language lawyers */ -static int opt_no_probe; +static int opt_no_inform; static int opt_summary; static void @@ -115,7 +118,7 @@ process_dev (PedDevice* dev) disk = ped_disk_new (dev); if (!disk) goto error; - if (!opt_no_probe) { + if (!opt_no_inform) { if (!ped_disk_commit_to_os (disk)) goto error_destroy_disk; } @@ -140,16 +143,16 @@ usage (int status) { printf (_("Usage: %s [OPTION] [DEVICE]...\n"), PROGRAM_NAME); fputs (_("\ -Inform the OS of partition table changes.\n\ +Inform the operating system about partition table changes.\n\ \n\ - -d, --no-update don't update the kernel\n\ + -d, --dry-run do not actually inform the operating system\n\ -s, --summary print a summary of contents\n\ -h, --help display this help and exit\n\ -v, --version output version information and exit\n\ "), stdout); fputs (_("\ \n\ -With no DEVICE, probe all partitions.\n\ +When no DEVICE is given, probe all partitions.\n\ "), stdout); printf (_("\nReport bugs to <%s>.\n"), PACKAGE_BUGREPORT); } @@ -168,7 +171,7 @@ main (int argc, char* argv[]) while ((c = getopt_long (argc, argv, "dhsv", long_options, NULL)) != -1) switch (c) { case 'd': - opt_no_probe = 1; + opt_no_inform = 1; break; case 's': |