generated from osc/skins-template
This commit is contained in:
@@ -676,22 +676,15 @@ jobs:
|
|||||||
skin_header="$skin"
|
skin_header="$skin"
|
||||||
|
|
||||||
if [ -f "$ini_file" ]; then
|
if [ -f "$ini_file" ]; then
|
||||||
line=$(grep -a -i '^Name[[:space:]]*:' "$ini_file" | head -n1 || true)
|
name_line=$(grep -a -i '^Name[[:space:]]*:' "$ini_file" | head -n1 || true)
|
||||||
if [ -n "$line" ]; then
|
if [ -n "$name_line" ]; then
|
||||||
val="${line#*:}"
|
val="${name_line#*:}"
|
||||||
val="$(echo "$val" | sed 's/^[[:space:]]*//;s/[[:space:]]*$//')"
|
val="$(echo "$val" | sed 's/^[[:space:]]*//;s/[[:space:]]*$//')"
|
||||||
if [ -n "$val" ]; then
|
[ -n "$val" ] && skin_header=$(sanitize_filename "$val")
|
||||||
skin_header=$(sanitize_filename "$val")
|
|
||||||
else
|
|
||||||
skin_header=$(sanitize_filename "$skin")
|
|
||||||
echo "⚠️ Warning: 'Name:' field empty in $skin. Falling back to folder name." >&2
|
|
||||||
fi
|
|
||||||
else
|
else
|
||||||
skin_header=$(sanitize_filename "$skin")
|
skin_header=$(sanitize_filename "$skin")
|
||||||
echo "⚠️ Warning: No 'Name:' field found in $skin. Falling back to folder name." >&2
|
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
echo "⚠️ Warning: No skin.ini found for $skin. Skipping." >&2
|
|
||||||
continue
|
continue
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@@ -704,6 +697,14 @@ jobs:
|
|||||||
desc=$(get_desc "$skin")
|
desc=$(get_desc "$skin")
|
||||||
[ -n "$desc" ] && { echo "$desc" >> "$README_PATH"; echo "" >> "$README_PATH"; }
|
[ -n "$desc" ] && { echo "$desc" >> "$README_PATH"; echo "" >> "$README_PATH"; }
|
||||||
|
|
||||||
|
if [ -f "$ini_file" ]; then
|
||||||
|
author_line=$(grep -i '^[[:space:]]*Author:' "$ini_file" | head -n1 || true)
|
||||||
|
if [ -n "$author_line" ]; then
|
||||||
|
author=$(echo "$author_line" | cut -d ':' -f2- | sed 's/^[[:space:]]*//;s/[[:space:]]*$//')
|
||||||
|
[ -n "$author" ] && { echo "**Author:** $author" >> "$README_PATH"; echo "" >> "$README_PATH"; }
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
echo "[](/docs/${base_path}.md)" >> "$README_PATH"
|
echo "[](/docs/${base_path}.md)" >> "$README_PATH"
|
||||||
echo "" >> "$README_PATH"
|
echo "" >> "$README_PATH"
|
||||||
done < order.txt
|
done < order.txt
|
||||||
@@ -717,22 +718,15 @@ jobs:
|
|||||||
skin_header="$skin"
|
skin_header="$skin"
|
||||||
|
|
||||||
if [ -f "$ini_file" ]; then
|
if [ -f "$ini_file" ]; then
|
||||||
line=$(grep -a -i '^Name[[:space:]]*:' "$ini_file" | head -n1 || true)
|
name_line=$(grep -a -i '^Name[[:space:]]*:' "$ini_file" | head -n1 || true)
|
||||||
if [ -n "$line" ]; then
|
if [ -n "$name_line" ]; then
|
||||||
val="${line#*:}"
|
val="${name_line#*:}"
|
||||||
val="$(echo "$val" | sed 's/^[[:space:]]*//;s/[[:space:]]*$//')"
|
val="$(echo "$val" | sed 's/^[[:space:]]*//;s/[[:space:]]*$//')"
|
||||||
if [ -n "$val" ]; then
|
[ -n "$val" ] && skin_header=$(sanitize_filename "$val")
|
||||||
skin_header=$(sanitize_filename "$val")
|
|
||||||
else
|
|
||||||
skin_header=$(sanitize_filename "$skin")
|
|
||||||
echo "⚠️ Warning: 'Name:' field empty in $skin. Falling back to folder name." >&2
|
|
||||||
fi
|
|
||||||
else
|
else
|
||||||
skin_header=$(sanitize_filename "$skin")
|
skin_header=$(sanitize_filename "$skin")
|
||||||
echo "⚠️ Warning: No 'Name:' field found in $skin. Falling back to folder name." >&2
|
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
echo "⚠️ Warning: No skin.ini found for $skin. Skipping." >&2
|
|
||||||
continue
|
continue
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@@ -741,6 +735,15 @@ jobs:
|
|||||||
|
|
||||||
echo "## [$skin_header]($REGISTRY_URL/$USER_REPOSITORY/media/tag/$new_tag/export/${base_path}.osk)" >> "$README_PATH"
|
echo "## [$skin_header]($REGISTRY_URL/$USER_REPOSITORY/media/tag/$new_tag/export/${base_path}.osk)" >> "$README_PATH"
|
||||||
echo "" >> "$README_PATH"
|
echo "" >> "$README_PATH"
|
||||||
|
|
||||||
|
if [ -f "$ini_file" ]; then
|
||||||
|
author_line=$(grep -i '^[[:space:]]*Author:' "$ini_file" | head -n1 || true)
|
||||||
|
if [ -n "$author_line" ]; then
|
||||||
|
author=$(echo "$author_line" | cut -d ':' -f2- | sed 's/^[[:space:]]*//;s/[[:space:]]*$//')
|
||||||
|
[ -n "$author" ] && { echo "**Author:** $author" >> "$README_PATH"; echo "" >> "$README_PATH"; }
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
echo "[](/docs/${base_path}.md)" >> "$README_PATH"
|
echo "[](/docs/${base_path}.md)" >> "$README_PATH"
|
||||||
echo "" >> "$README_PATH"
|
echo "" >> "$README_PATH"
|
||||||
done
|
done
|
||||||
@@ -816,14 +819,30 @@ jobs:
|
|||||||
|
|
||||||
video_url="$REGISTRY_URL/$USER_REPOSITORY/raw/tag/$new_tag/media/gameplay/${base_path}.mp4"
|
video_url="$REGISTRY_URL/$USER_REPOSITORY/raw/tag/$new_tag/media/gameplay/${base_path}.mp4"
|
||||||
|
|
||||||
|
author=""
|
||||||
|
if [ -f "$ini_file" ]; then
|
||||||
|
author_line=$(grep -i '^[[:space:]]*Author:' "$ini_file" | head -n1 || true)
|
||||||
|
if [ -n "$author_line" ]; then
|
||||||
|
author=$(echo "$author_line" | cut -d ':' -f2- | sed 's/^[[:space:]]*//;s/[[:space:]]*$//')
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
{
|
{
|
||||||
echo "# [$skin_header]($osk_url)"
|
echo "# [$skin_header]($osk_url)"
|
||||||
echo ""
|
echo ""
|
||||||
|
[ -n "$author" ] && echo "**Author:** $author"
|
||||||
|
[ -n "$author" ] && echo ""
|
||||||
|
|
||||||
|
echo "## Hitsounds"
|
||||||
echo "<video controls autoplay loop muted playsinline src=\"$video_url\" type=\"video/mp4\">"
|
echo "<video controls autoplay loop muted playsinline src=\"$video_url\" type=\"video/mp4\">"
|
||||||
echo "</video>"
|
echo "</video>"
|
||||||
echo ""
|
echo ""
|
||||||
|
|
||||||
|
echo "## Ranking Panel"
|
||||||
echo ""
|
echo ""
|
||||||
echo ""
|
echo ""
|
||||||
|
|
||||||
|
echo "## Mod Icons"
|
||||||
echo ""
|
echo ""
|
||||||
} > "$md_file_path"
|
} > "$md_file_path"
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user