Files
honey-biscuit-workshop/templates/bake.sh.tmpl
T
Catty Steve 117660d5c4 feat(baker/finalize): notification system and consolidate status types
- Rename types/build_status.rs to types/buildstatus.rs
- Rename StageInfo.sub_stage field to substage for consistency
- Move notification logic from finalize to dedicated notify module
- Remove notification module from finalize (moved to notify)
- Add notify module with event queuing, retry, and priority scheduling
- Add exponential backoff for temporary notification failures
- Implement plugin filtering by name list during registration
- Add fetch_plugins helper for batch plugin download
- Update finalize plugin registration to accept optional plugin filter
- Fix finalize config template indentation for notification policy
- Move all YAML templates to templates/ directory
2026-04-23 16:18:20 +08:00

86 lines
1.3 KiB
Cheetah

#!/bin/bash
#Implicit set -euo pipefail
# function to be used by any pipeline stage
function get_custom_library() {
curl -LO https://archive.ppy.sh/$2/$1.tar.gz
}
# @pipeline
prepare_dotnet() {
curl -L https://dot.net/v1/dotnet-install.sh | bash
bake_info "Successfully installed dotnet"
}
# @pipeline
fetch_source() {
git clone https://github.com/ppy/osu.git --depth 1
}
# @pipeline
# @if(WS_PIPELINE_ARCH == amd64)
# @timeout(720)
# @retry(3, 5)
# @parallel
fetch_library() {
get_custom_library ffmpeg amd64
get_custom_library libesqlite3 amd64
get_custom_library libbass amd64
}
# @pipeline
# @fallible
# @parallel
fetch_osu_framework() {
cd ..
git clone https://github.com/ppy/osu-framework.git --depth 1
}
# @pipeline
# @timeout(600)
restore_workload() {
cd osu
dotnet workload restore
}
# @pipeline
# @export
set_environment() {
export DOTNET_ENVIRONMENT=Production
}
# @pipeline
# @export
build() {
dotnet build osu.Desktop
dotnet publish osu.Desktop -o osu-build --sc
}
# @pipeline
# @loop(3)
test() {
dotnet test
}
# @pipeline
# @parallel
# @after(fetch_library)
compress_library() {
mkdir -p osu-native
cp osu-build/*.so ../osu-native
tar -cf osu-native osu-native.tar
zstd osu.tar
}
# @pipeline
# @after(test)
compress_artifact() {
tar -cf osu osu.tar
zstd osu.tar
}