patch: add dry-run alias for compatibility with other implementations.
Other implementations of patch(1), including GNU patch and "svn patch" have a --dry-run option which does the same as our -C or --check option. Add a new alias to make our implementation more compatible. MFC after: 1 week
This commit is contained in:
parent
a1c70d6943
commit
5e64d66ca4
@ -21,7 +21,7 @@
|
|||||||
.\"
|
.\"
|
||||||
.\" $OpenBSD: patch.1,v 1.27 2014/04/15 06:26:54 jmc Exp $
|
.\" $OpenBSD: patch.1,v 1.27 2014/04/15 06:26:54 jmc Exp $
|
||||||
.\" $FreeBSD$
|
.\" $FreeBSD$
|
||||||
.Dd June 12, 2014
|
.Dd June 15, 2014
|
||||||
.Dt PATCH 1
|
.Dt PATCH 1
|
||||||
.Os
|
.Os
|
||||||
.Sh NAME
|
.Sh NAME
|
||||||
@ -107,7 +107,7 @@ This is equivalent to specifying
|
|||||||
This option is currently the default, unless
|
This option is currently the default, unless
|
||||||
.Fl -posix
|
.Fl -posix
|
||||||
is specified.
|
is specified.
|
||||||
.It Fl C , Fl Fl check
|
.It Fl C , Fl Fl check , Fl Fl dry-run
|
||||||
Checks that the patch would apply cleanly, but does not modify anything.
|
Checks that the patch would apply cleanly, but does not modify anything.
|
||||||
.It Fl c , Fl Fl context
|
.It Fl c , Fl Fl context
|
||||||
Forces
|
Forces
|
||||||
|
@ -469,6 +469,7 @@ get_some_switches(void)
|
|||||||
{"context", no_argument, 0, 'c'},
|
{"context", no_argument, 0, 'c'},
|
||||||
{"debug", required_argument, 0, 'x'},
|
{"debug", required_argument, 0, 'x'},
|
||||||
{"directory", required_argument, 0, 'd'},
|
{"directory", required_argument, 0, 'd'},
|
||||||
|
{"dry-run", no_argument, 0, 'C'},
|
||||||
{"ed", no_argument, 0, 'e'},
|
{"ed", no_argument, 0, 'e'},
|
||||||
{"force", no_argument, 0, 'f'},
|
{"force", no_argument, 0, 'f'},
|
||||||
{"forward", no_argument, 0, 'N'},
|
{"forward", no_argument, 0, 'N'},
|
||||||
|
Loading…
x
Reference in New Issue
Block a user