修复最后一行没有换行符的情况
This commit is contained in:
parent
8eec8b76fd
commit
721c59dffb
4
.github/workflows/docker.yaml
vendored
4
.github/workflows/docker.yaml
vendored
@ -61,7 +61,7 @@ jobs:
|
|||||||
# 数据预处理,判断镜像是否重名
|
# 数据预处理,判断镜像是否重名
|
||||||
declare -A duplicate_images
|
declare -A duplicate_images
|
||||||
declare -A temp_map
|
declare -A temp_map
|
||||||
while IFS= read -r line; do
|
while IFS= read -r line || [ -n "$line" ]; do
|
||||||
# 忽略空行与注释
|
# 忽略空行与注释
|
||||||
[[ -z "$line" ]] && continue
|
[[ -z "$line" ]] && continue
|
||||||
if echo "$line" | grep -q '^\s*#'; then
|
if echo "$line" | grep -q '^\s*#'; then
|
||||||
@ -99,7 +99,7 @@ jobs:
|
|||||||
done < images.txt
|
done < images.txt
|
||||||
|
|
||||||
|
|
||||||
while IFS= read -r line; do
|
while IFS= read -r line || [ -n "$line" ]; do
|
||||||
# 忽略空行与注释
|
# 忽略空行与注释
|
||||||
[[ -z "$line" ]] && continue
|
[[ -z "$line" ]] && continue
|
||||||
if echo "$line" | grep -q '^\s*#'; then
|
if echo "$line" | grep -q '^\s*#'; then
|
||||||
|
Loading…
x
Reference in New Issue
Block a user