Movatterモバイル変換


[0]ホーム

URL:


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

Commitd5479b2

Browse files
committed
Use set -u in init script
This is already done in the other shell scripts. Althoughinit-tests-after-clone.sh does not have as many places where a bugcould slip through by an inadvertently nonexistent parameter, itdoes have $answer (and it may have more expansions in the future).
1 parent5060c9d commitd5479b2

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

‎init-tests-after-clone.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
#!/bin/sh
22

3-
set -e
3+
set -eu
44

5-
iftest -z"$TRAVIS";then
5+
iftest -z"${TRAVIS-}";then
66
printf'This operation will destroy locally modified files. Continue ? [N/y]:'>&2
77
read -r answer
88
case"$answer"in
@@ -29,7 +29,7 @@ git reset --hard HEAD~1
2929
git reset --hard __testing_point__
3030

3131
# Do some setup that CI takes care of but that may not have been done locally.
32-
iftest -z"$TRAVIS";then
32+
iftest -z"${TRAVIS-}";then
3333
# The tests needs some version tags. Try to get them even in forks.
3434
git fetch --all --tags
3535

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp