Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 22 Jun 2014 20:29:51 +0000 (UTC)
From:      "Pedro F. Giffuni" <pfg@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject:   svn commit: r267747 - stable/10/usr.bin/patch
Message-ID:  <201406222029.s5MKTpqH051286@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: pfg
Date: Sun Jun 22 20:29:51 2014
New Revision: 267747
URL: http://svnweb.freebsd.org/changeset/base/267747

Log:
  MFC	r267512:
  
  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.

Modified:
  stable/10/usr.bin/patch/patch.1
  stable/10/usr.bin/patch/patch.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/usr.bin/patch/patch.1
==============================================================================
--- stable/10/usr.bin/patch/patch.1	Sun Jun 22 20:24:17 2014	(r267746)
+++ stable/10/usr.bin/patch/patch.1	Sun Jun 22 20:29:51 2014	(r267747)
@@ -21,7 +21,7 @@
 .\"
 .\" $OpenBSD: patch.1,v 1.27 2014/04/15 06:26:54 jmc Exp $
 .\" $FreeBSD$
-.Dd June 12, 2014
+.Dd June 15, 2014
 .Dt PATCH 1
 .Os
 .Sh NAME
@@ -107,7 +107,7 @@ This is equivalent to specifying
 This option is currently the default, unless
 .Fl -posix
 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.
 .It Fl c , Fl Fl context
 Forces

Modified: stable/10/usr.bin/patch/patch.c
==============================================================================
--- stable/10/usr.bin/patch/patch.c	Sun Jun 22 20:24:17 2014	(r267746)
+++ stable/10/usr.bin/patch/patch.c	Sun Jun 22 20:29:51 2014	(r267747)
@@ -469,6 +469,7 @@ get_some_switches(void)
 		{"context",		no_argument,		0,	'c'},
 		{"debug",		required_argument,	0,	'x'},
 		{"directory",		required_argument,	0,	'd'},
+		{"dry-run",		no_argument,		0,	'C'},
 		{"ed",			no_argument,		0,	'e'},
 		{"force",		no_argument,		0,	'f'},
 		{"forward",		no_argument,		0,	'N'},



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201406222029.s5MKTpqH051286>