Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit cc8536d

Browse files
committed
better help output from git-ptt
1 parent 6291c5c commit cc8536d

File tree

1 file changed

+13
-2
lines changed

1 file changed

+13
-2
lines changed

‎git-ptt‎

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,14 @@
22

33
usage() {
44
cat <<EOF
5-
0ドル: usage: 0ドル [-f] [-F] [-r <remote>] <rev>
5+
${0##*/}: usage: ${0##*/} [-fhF] [-r <remote>] <rev>
6+
7+
Options:
8+
9+
-f Push using --force-with-lease
10+
-F Push using --force
11+
-r <remote> Push to remote <remote>
12+
-h Show this help message
613
EOF
714
}
815

@@ -12,7 +19,7 @@ query_only=0
1219
shortlen=10
1320
marker=x-branch
1421

15-
while getopts qfr: ch; do
22+
while getopts fhr:q ch; do
1623
case $ch in
1724
(f) force="--force-with-lease"
1825
;;
@@ -24,6 +31,10 @@ while getopts qfr: ch; do
2431
(q) query_only=1
2532
;;
2633

34+
(h) usage
35+
exit 0
36+
;;
37+
2738
(\?) usage >&2
2839
exit 2
2940
;;

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /