summaryrefslogtreecommitdiff
path: root/git-format-patch.sh
diff options
context:
space:
mode:
authorJunio C Hamano <junkio@cox.net>2005-12-14 21:01:01 (GMT)
committerJunio C Hamano <junkio@cox.net>2005-12-14 21:01:01 (GMT)
commitb0d3e9baaa16c805ef941e8f26d55fb23f091ef5 (patch)
tree142e8fb76c906de7b61b9bf55ab026bee2388aa3 /git-format-patch.sh
parenta4adf54d38ba49e58511aaafd18e99e6d3d4dabb (diff)
parent5073eb04d6f0e8ac2578140b9231817e2afefe50 (diff)
downloadgit-b0d3e9baaa16c805ef941e8f26d55fb23f091ef5.zip
git-b0d3e9baaa16c805ef941e8f26d55fb23f091ef5.tar.gz
git-b0d3e9baaa16c805ef941e8f26d55fb23f091ef5.tar.bz2
Merge branch 'fk/usage'
Diffstat (limited to 'git-format-patch.sh')
-rwxr-xr-xgit-format-patch.sh25
1 files changed, 8 insertions, 17 deletions
diff --git a/git-format-patch.sh b/git-format-patch.sh
index 921feee..01508e3 100755
--- a/git-format-patch.sh
+++ b/git-format-patch.sh
@@ -3,19 +3,8 @@
# Copyright (c) 2005 Junio C Hamano
#
-. git-sh-setup
-
-# Force diff to run in C locale.
-LANG=C LC_ALL=C
-export LANG LC_ALL
-
-usage () {
- echo >&2 "usage: $0"' [-n] [-o dir | --stdout] [--keep-subject] [--mbox]
- [--check] [--signoff] [-<diff options>...]
- [--help]
- ( from..to ... | upstream [ our-head ] )
-
-Prepare each commit with its patch since our-head forked from upstream,
+USAGE='[-n | -k] [-o <dir> | --stdout] [--signoff] [--check] [--mbox] [--diff-options] <upstream> [<our-head>]'
+LONG_USAGE='Prepare each commit with its patch since our-head forked from upstream,
one file per patch, for e-mail submission. Each output file is
numbered sequentially from 1, and uses the first line of the commit
message (massaged for pathname safety) as the filename.
@@ -28,10 +17,12 @@ as "[PATCH N/M] Subject", unless you have only one patch.
When --mbox is specified, the output is formatted to resemble
UNIX mailbox format, and can be concatenated together for processing
-with applymbox.
-'
- exit 1
-}
+with applymbox.'
+. git-sh-setup
+
+# Force diff to run in C locale.
+LANG=C LC_ALL=C
+export LANG LC_ALL
diff_opts=
LF='