- Update the GitHub workflow actions to their latest versions. - Use the latest Node.js LTS release. - Use the latest Ubuntu version for consistency across all workflows. - The `set-output` command is deprecated and will soon be disabled (https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/) so use the new recommended way. - Use the `$()` expressions for string interpolation instead of the deprecated backticks in Bash. - Format the YAML files. Differential Revision: https://reviews.llvm.org/D143015
29 lines
695 B
YAML
29 lines
695 B
YAML
name: LLVM Project Version Check
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- 'release/**'
|
|
pull_request:
|
|
branches:
|
|
- 'release/**'
|
|
|
|
jobs:
|
|
version_check:
|
|
if: github.repository_owner == 'llvm'
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Fetch LLVM sources
|
|
uses: actions/checkout@v3
|
|
with:
|
|
fetch-depth: 0
|
|
|
|
- name: Install dependencies
|
|
run: |
|
|
pip install -r ./llvm/utils/git/requirements.txt
|
|
|
|
- name: Version Check
|
|
run: |
|
|
version=$(grep -o 'LLVM_VERSION_\(MAJOR\|MINOR\|PATCH\) [0-9]\+' llvm/CMakeLists.txt | cut -d ' ' -f 2 | tr "\n" "." | sed 's/.$//g')
|
|
.github/workflows/version-check.py $version
|