Free space so workflows don't fail! #509
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build | |
on: | |
workflow_dispatch: | |
pull_request: | |
push: | |
branches: | |
- 'fourteen' | |
jobs: | |
build: | |
runs-on: ubuntu-24.04 | |
strategy: | |
fail-fast: false | |
matrix: | |
target: [a52q, a52sxq, a52xq, a71, a72q, a73xq, b0q, dm1q, dm2q, dm3q, g0q, m52xq, r0q, r8q, r9q, r9q2] | |
steps: | |
- name: Free Disk Space (Ubuntu) | |
uses: jlumbroso/free-disk-space@main | |
with: | |
# this might remove tools that are actually needed, | |
# if set to "true" but frees about 6 GB | |
tool-cache: false | |
# all of these default to true, but feel free to set to | |
# "false" if necessary for your workflow | |
android: true | |
dotnet: true | |
haskell: true | |
large-packages: true | |
docker-images: true | |
swap-storage: true | |
- name: Free disk space through docker | |
run: | | |
sudo rm -rf /usr/share/dotnet /usr/local/lib/android /opt/ghc /opt/hostedtoolcache/CodeQL | |
sudo docker image prune --all --force | |
sudo docker builder prune -a | |
- name: Checkout repo | |
uses: actions/checkout@v4 | |
with: | |
submodules: 'recursive' | |
- name: Free disk space | |
uses: rokibhasansagar/slimhub_actions@main | |
with: | |
retain: 'compiler_cmake' | |
- name: Set up build environment | |
run: | | |
sudo apt update | |
DEBIAN_FRONTEND=noninteractive sudo apt install -yq \ | |
attr ccache clang ffmpeg golang \ | |
libbrotli-dev libgtest-dev libprotobuf-dev libunwind-dev libpcre2-dev \ | |
libzstd-dev linux-modules-extra-$(uname -r) lld protobuf-compiler webp \ | |
zipalign | |
sudo modprobe erofs f2fs | |
git config --global user.name "github-actions[bot]" | |
git config --global user.email "41898282+github-actions[bot]@users.noreply.github.com" | |
echo -n "${{ secrets.PLATFORM_KEY_PK8 }}" | base64 --decode > unica/security/unica_platform.pk8 | |
echo -n "${{ secrets.PLATFORM_KEY_PEM }}" | base64 --decode > unica/security/unica_platform.x509.pem | |
- name: Set up JDK 11 | |
uses: actions/setup-java@v4 | |
with: | |
distribution: 'temurin' | |
java-version: '11' | |
cache: 'gradle' | |
- name: Set up Node.js | |
uses: actions/setup-node@v4 | |
with: | |
node-version: 'latest' | |
- name: Build dependencies | |
run: source ./buildenv.sh ${{ matrix.target }} | |
- name: Download stock firmwares | |
run: | | |
source ./buildenv.sh ${{ matrix.target }} | |
./scripts/download_fw.sh | |
- name: Extract stock firmwares | |
run: | | |
source ./buildenv.sh ${{ matrix.target }} | |
./scripts/extract_fw.sh | |
./scripts/cleanup.sh odin | |
- name: Build ROM | |
run: | | |
source ./buildenv.sh ${{ matrix.target }} | |
./scripts/make_rom.sh --no-rom-zip --no-rom-tar |