Allow for generating arch-specific image docs for which the current architecture is not supported

This commit is contained in:
Tianon Gravi 2017-11-17 13:44:00 -08:00
parent 77e1c1f3d5
commit 389ba4576b
1 changed files with 8 additions and 1 deletions

View File

@ -121,7 +121,14 @@ for image in "${images[@]}"; do
echo ' TAGS => generate-dockerfile-links-partial.sh "'"$repo"'"'
partial="$("$helperDir/generate-dockerfile-links-partial.sh" "$repo")"
[ "$partial" ]
if [ -z "$partial" ]; then
if [ -n "$ARCH_SPECIFIC_DOCS" ]; then
partial='**No supported tags found!**'$'\n\n''It is very likely that `%%REPO%%` does not support the currently selected architecture (`'"$BASHBREW_ARCH"'`).'
else
echo >&2 'error: missing TAGS for '"$repo"'!'
exit 1
fi
fi
replace_field "$targetFile" 'TAGS' "$partial"
echo ' ARCHES => arches.sh "'"$repo"'"'