git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
* [PATCH 2/3] cg-patch: Use optparse
@ 2006-02-07 22:44 Jonas Fonseca
  0 siblings, 0 replies; only message in thread
From: Jonas Fonseca @ 2006-02-07 22:44 UTC (permalink / raw)
  To: Petr Baudis; +Cc: git

Signed-off-by: Jonas Fonseca <fonseca@diku.dk>
---
commit 77defc166986330f4285db8faf206c1176a6c4ae
tree 293120fe428f40eab2422ed59d84e77aa1fa53a1
parent 5095aca7013d87ccdb08dad20a9fb93d7465d33d
author Jonas Fonseca <fonseca@diku.dk> Tue, 07 Feb 2006 23:07:32 +0100
committer Jonas Fonseca <fonseca@antimatter.localdomain> Tue, 07 Feb 2006 23:07:32 +0100

 cg-patch |   11 +++++++----
 1 files changed, 7 insertions(+), 4 deletions(-)

diff --git a/cg-patch b/cg-patch
index 8be13be..90dfd30 100755
--- a/cg-patch
+++ b/cg-patch
@@ -70,10 +70,13 @@ redzone_border()
 
 
 reverse=
-if [ "${ARGS[0]}" = "-R" ]; then
-	reverse=1
-	shift
-fi
+while optparse; do
+	if optparse -R; then
+		reverse=1
+	else
+		optfail
+	fi
+done
 
 
 gonefile="$(mktemp -t gitapply.XXXXXX)"

-- 
Jonas Fonseca

^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2006-02-07 22:45 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-02-07 22:44 [PATCH 2/3] cg-patch: Use optparse Jonas Fonseca

Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).