Skip to content

build-angle

build-angle #154

Workflow file for this run

name: build-angle
on:
schedule:
- cron: "0 0 * * 0"
push:
branches:
- main
jobs:
info:
runs-on: ubuntu-24.04
outputs:
ANGLE_COMMIT: ${{ steps.info.outputs.ANGLE_COMMIT }}
BUILD_DATE: ${{ steps.info.outputs.BUILD_DATE }}
steps:
- name: Get Latest Commit Id
id: info
run: |
echo ANGLE_COMMIT=`git ls-remote https://chromium.googlesource.com/angle/angle HEAD | awk '{ print $1 }'` >> ${GITHUB_OUTPUT}
echo BUILD_DATE=`date +'%Y-%m-%d'` >> ${GITHUB_OUTPUT}
build:
runs-on: windows-2022
needs: info
strategy:
matrix:
arch: [x64, arm64]
env:
ANGLE_COMMIT: ${{ needs.info.outputs.ANGLE_COMMIT }}
BUILD_DATE: ${{ needs.info.outputs.BUILD_DATE }}
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Run Build Script
id: build
shell: cmd
run: call build.cmd ${{ matrix.arch }}
- name: Upload Artifacts
uses: actions/upload-artifact@v4
with:
name: angle-${{ matrix.arch }}-${{ needs.info.outputs.BUILD_DATE }}
path: angle-${{ matrix.arch }}-${{ needs.info.outputs.BUILD_DATE }}.zip
if-no-files-found: error
compression-level: 0
release:
runs-on: ubuntu-24.04
needs: [info, build]
permissions:
contents: write
env:
GH_TOKEN: ${{ github.token }}
steps:
- name: Create GitHub Release
run: |
echo '[angle commit](https://github.com/google/angle/commit/${{ needs.info.outputs.ANGLE_COMMIT }})' >>notes.txt
gh release create ${{ needs.info.outputs.BUILD_DATE }} -R "${GITHUB_REPOSITORY}" -t '${{ needs.info.outputs.BUILD_DATE }}' -F notes.txt
- name: Get Artifacts From Build Steps
uses: actions/download-artifact@v4
with:
pattern: angle-*-${{ needs.info.outputs.BUILD_DATE }}
merge-multiple: true
- name: Upload Artifacts to GitHub Release
run: gh release upload '${{ needs.info.outputs.BUILD_DATE }}' angle-*-${{ needs.info.outputs.BUILD_DATE }}.zip -R "${GITHUB_REPOSITORY}"