Commit 22676fe
authored
### Rationale for this change
This is the sub issue #44748.
* SC2206: Quote to prevent word splitting/globbing
* SC2086: Double quote to prevent globbing
```
shellcheck ci/scripts/msys2_setup.sh
In ci/scripts/msys2_setup.sh line 27:
packages+=(${MINGW_PACKAGE_PREFIX}-aws-sdk-cpp)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 28:
packages+=(${MINGW_PACKAGE_PREFIX}-boost)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 29:
packages+=(${MINGW_PACKAGE_PREFIX}-brotli)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 30:
packages+=(${MINGW_PACKAGE_PREFIX}-bzip2)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 31:
packages+=(${MINGW_PACKAGE_PREFIX}-c-ares)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 32:
packages+=(${MINGW_PACKAGE_PREFIX}-ccache)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 33:
packages+=(${MINGW_PACKAGE_PREFIX}-clang)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 34:
packages+=(${MINGW_PACKAGE_PREFIX}-cmake)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 35:
packages+=(${MINGW_PACKAGE_PREFIX}-double-conversion)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 36:
packages+=(${MINGW_PACKAGE_PREFIX}-gflags)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 37:
packages+=(${MINGW_PACKAGE_PREFIX}-grpc)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 38:
packages+=(${MINGW_PACKAGE_PREFIX}-gtest)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 39:
packages+=(${MINGW_PACKAGE_PREFIX}-libutf8proc)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 40:
packages+=(${MINGW_PACKAGE_PREFIX}-libxml2)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 41:
packages+=(${MINGW_PACKAGE_PREFIX}-llvm)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 42:
packages+=(${MINGW_PACKAGE_PREFIX}-lz4)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 43:
packages+=(${MINGW_PACKAGE_PREFIX}-ninja)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 44:
packages+=(${MINGW_PACKAGE_PREFIX}-nlohmann-json)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 45:
packages+=(${MINGW_PACKAGE_PREFIX}-protobuf)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 46:
packages+=(${MINGW_PACKAGE_PREFIX}-rapidjson)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 47:
packages+=(${MINGW_PACKAGE_PREFIX}-re2)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 48:
packages+=(${MINGW_PACKAGE_PREFIX}-snappy)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 49:
packages+=(${MINGW_PACKAGE_PREFIX}-sqlite3)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 50:
packages+=(${MINGW_PACKAGE_PREFIX}-thrift)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 51:
packages+=(${MINGW_PACKAGE_PREFIX}-xsimd)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 52:
packages+=(${MINGW_PACKAGE_PREFIX}-uriparser)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 53:
packages+=(${MINGW_PACKAGE_PREFIX}-zstd)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 61:
packages+=(${MINGW_PACKAGE_PREFIX}-openssl)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 62:
packages+=(${MINGW_PACKAGE_PREFIX}-zlib)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 69:
packages+=(${MINGW_PACKAGE_PREFIX}-gobject-introspection)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 70:
packages+=(${MINGW_PACKAGE_PREFIX}-meson)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 71:
packages+=(${MINGW_PACKAGE_PREFIX}-vala)
^---------------------^ SC2206 (warning): Quote to prevent word splitting/globbing, or split robustly with mapfile or read -a.
In ci/scripts/msys2_setup.sh line 81:
"$(dirname $0)/ccache_setup.sh"
^-- SC2086 (info): Double quote to prevent globbing and word splitting.
Did you mean:
"$(dirname "$0")/ccache_setup.sh"
In ci/scripts/msys2_setup.sh line 82:
echo "CCACHE_DIR=$(cygpath --absolute --windows ccache)" >> $GITHUB_ENV
^---------^ SC2086 (info): Double quote to prevent globbing and word splitting.
Did you mean:
echo "CCACHE_DIR=$(cygpath --absolute --windows ccache)" >> "$GITHUB_ENV"
In ci/scripts/msys2_setup.sh line 83:
echo "PIP_CACHE_DIR=$(pip cache dir)" >> $GITHUB_ENV
^---------^ SC2086 (info): Double quote to prevent globbing and word splitting.
Did you mean:
echo "PIP_CACHE_DIR=$(pip cache dir)" >> "$GITHUB_ENV"
For more information:
https://www.shellcheck.net/wiki/SC2206 -- Quote to prevent word splitting/g...
https://www.shellcheck.net/wiki/SC2086 -- Double quote to prevent globbing ...
```
### What changes are included in this PR?
Quote variables.
### Are these changes tested?
Yes.
### Are there any user-facing changes?
No.
* GitHub Issue: #47244
Authored-by: Hiroyuki Sato <[email protected]>
Signed-off-by: Sutou Kouhei <[email protected]>
1 parent 19f3b85 commit 22676fe
2 files changed
+37
-35
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
334 | 334 | | |
335 | 335 | | |
336 | 336 | | |
| 337 | + | |
337 | 338 | | |
338 | 339 | | |
339 | 340 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
24 | 24 | | |
25 | 25 | | |
26 | 26 | | |
27 | | - | |
28 | | - | |
29 | | - | |
30 | | - | |
31 | | - | |
32 | | - | |
33 | | - | |
34 | | - | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | | - | |
39 | | - | |
40 | | - | |
41 | | - | |
42 | | - | |
43 | | - | |
44 | | - | |
45 | | - | |
46 | | - | |
47 | | - | |
48 | | - | |
49 | | - | |
50 | | - | |
51 | | - | |
52 | | - | |
53 | | - | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
54 | 54 | | |
55 | 55 | | |
56 | 56 | | |
57 | 57 | | |
58 | 58 | | |
59 | 59 | | |
60 | 60 | | |
61 | | - | |
62 | | - | |
| 61 | + | |
| 62 | + | |
63 | 63 | | |
64 | 64 | | |
65 | 65 | | |
66 | 66 | | |
67 | 67 | | |
68 | 68 | | |
69 | | - | |
70 | | - | |
71 | | - | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
72 | 72 | | |
73 | 73 | | |
74 | 74 | | |
| |||
78 | 78 | | |
79 | 79 | | |
80 | 80 | | |
81 | | - | |
82 | | - | |
83 | | - | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
0 commit comments