Skip to content

Commit 8f390cf

Browse files
committed
Accept _ as space substitutes
Replace all spaces in the ID/ID_LIKE scoring to allow for space replacement Signed-off-by: Nicolas signed-log FORMICHELLA <[email protected]>
1 parent 36fda72 commit 8f390cf

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

yadm

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -204,14 +204,14 @@ function score_file() {
204204
return
205205
fi
206206
elif [[ "$label" =~ ^(d|distro)$ ]]; then
207-
if [ "$value" = "$local_distro" ]; then
207+
if [ "${value/\ /_}" = "${local_distro/\ /_}" ]; then
208208
score=$((score + 4))
209209
else
210210
score=0
211211
return
212212
fi
213213
elif [[ "$label" =~ ^(f|distro_family)$ ]]; then
214-
if [ "$value" = "$local_distro_family" ]; then
214+
if [ "${value/\ /_}" = "${local_distro_family/\ /_}" ]; then
215215
score=$((score + 8))
216216
else
217217
score=0

0 commit comments

Comments
 (0)