Skip to content

Commit 75827da

Browse files
committed
Merge branch 'fc/random-cleanup'
Random cleanup. * fc/random-cleanup: gitignore: remove entry for git serve gitignore: drop duplicate entry for git-sh-i18n tests: lib-functions: trivial style cleanups test: completion: fix typos .gitignore: remove dangling file refspec: trivial cleanup
2 parents 18da626 + 2fbd305 commit 75827da

File tree

4 files changed

+16
-18
lines changed

4 files changed

+16
-18
lines changed

.gitignore

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,6 @@
134134
/git-remote-ftps
135135
/git-remote-fd
136136
/git-remote-ext
137-
/git-remote-testpy
138137
/git-repack
139138
/git-replace
140139
/git-request-pull
@@ -147,11 +146,9 @@
147146
/git-rm
148147
/git-send-email
149148
/git-send-pack
150-
/git-serve
151149
/git-sh-i18n
152150
/git-sh-i18n--envsubst
153151
/git-sh-setup
154-
/git-sh-i18n
155152
/git-shell
156153
/git-shortlog
157154
/git-show

refspec.c

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -272,15 +272,16 @@ void refspec_ref_prefixes(const struct refspec *rs,
272272
else if (item->src && !item->exact_sha1)
273273
prefix = item->src;
274274

275-
if (prefix) {
276-
if (item->pattern) {
277-
const char *glob = strchr(prefix, '*');
278-
strvec_pushf(ref_prefixes, "%.*s",
279-
(int)(glob - prefix),
280-
prefix);
281-
} else {
282-
expand_ref_prefix(ref_prefixes, prefix);
283-
}
275+
if (!prefix)
276+
continue;
277+
278+
if (item->pattern) {
279+
const char *glob = strchr(prefix, '*');
280+
strvec_pushf(ref_prefixes, "%.*s",
281+
(int)(glob - prefix),
282+
prefix);
283+
} else {
284+
expand_ref_prefix(ref_prefixes, prefix);
284285
}
285286
}
286287
}

t/t9902-completion.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -906,7 +906,7 @@ test_expect_success '__git_refs - after --opt= - full refs' '
906906
test_cmp expected "$actual"
907907
'
908908

909-
test_expect_success '__git refs - exluding refs' '
909+
test_expect_success '__git refs - excluding refs' '
910910
cat >expected <<-EOF &&
911911
^HEAD
912912
^master
@@ -922,7 +922,7 @@ test_expect_success '__git refs - exluding refs' '
922922
test_cmp expected "$actual"
923923
'
924924

925-
test_expect_success '__git refs - exluding full refs' '
925+
test_expect_success '__git refs - excluding full refs' '
926926
cat >expected <<-EOF &&
927927
^refs/heads/master
928928
^refs/heads/matching-branch

t/test-lib-functions.sh

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -955,7 +955,7 @@ test_expect_code () {
955955
# - cmp's output is not nearly as easy to read as diff -u
956956
# - not all diff versions understand "-u"
957957

958-
test_cmp() {
958+
test_cmp () {
959959
eval "$GIT_TEST_CMP" '"$@"'
960960
}
961961

@@ -968,7 +968,7 @@ test_cmp() {
968968
#
969969
# test_cmp_config foo core.bar
970970
#
971-
test_cmp_config() {
971+
test_cmp_config () {
972972
local GD &&
973973
if test "$1" = "-C"
974974
then
@@ -984,7 +984,7 @@ test_cmp_config() {
984984

985985
# test_cmp_bin - helper to compare binary files
986986

987-
test_cmp_bin() {
987+
test_cmp_bin () {
988988
cmp "$@"
989989
}
990990

@@ -1418,7 +1418,7 @@ nongit () {
14181418
# whitespace and put in a single packet. Note that data containing NULs must be
14191419
# given on stdin, and that empty input becomes an empty packet, not a flush
14201420
# packet (for that you can just print 0000 yourself).
1421-
packetize() {
1421+
packetize () {
14221422
if test $# -gt 0
14231423
then
14241424
packet="$*"

0 commit comments

Comments
 (0)