This commit is contained in:
1 parent
b6f6b53a70
commit
14cb687f7d
2 files changed
+69
No files matched your search
@@ -0,0 +1,63 @@
|
||||
name: Quality Gate
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
pull_request:
|
||||
branches:
|
||||
- main
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
quality-gate:
|
||||
name: Quality Gate
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 15
|
||||
env:
|
||||
GODOT_VERSION: 4.7.2
|
||||
GODOT_BIN: /tmp/godot-4.7.2/Godot_v4.7.2-stable_linux.x86_64
|
||||
GODOT_SHA512: 9aa00f7a605200940bce3027a567b782f49bd8e940dd06ae9e987bd65aee1b1467edd56ed84fcdcbdd44354bf613bdb4e5d2913e925850368e150c59ed54c65
|
||||
|
||||
steps:
|
||||
- name: Check out repository
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Install system dependencies
|
||||
shell: bash
|
||||
run: |
|
||||
set -euo pipefail
|
||||
if command -v sudo >/dev/null 2>&1; then
|
||||
sudo apt-get update
|
||||
sudo apt-get install -y --no-install-recommends \
|
||||
ca-certificates curl ripgrep unzip
|
||||
else
|
||||
apt-get update
|
||||
apt-get install -y --no-install-recommends \
|
||||
ca-certificates curl ripgrep unzip
|
||||
fi
|
||||
|
||||
- name: Install Godot 4.7.2
|
||||
shell: bash
|
||||
run: |
|
||||
set -euo pipefail
|
||||
archive="Godot_v${GODOT_VERSION}-stable_linux.x86_64.zip"
|
||||
release_url="https://github.com/godotengine/godot-builds/releases/download/${GODOT_VERSION}-stable"
|
||||
download_directory="$(mktemp -d)"
|
||||
install_directory="$(dirname "$GODOT_BIN")"
|
||||
|
||||
curl --fail --location --silent --show-error \
|
||||
"$release_url/$archive" \
|
||||
--output "$download_directory/$archive"
|
||||
printf '%s %s\n' \
|
||||
"$GODOT_SHA512" "$download_directory/$archive" \
|
||||
| sha512sum --check
|
||||
|
||||
mkdir -p "$install_directory"
|
||||
unzip -q "$download_directory/$archive" -d "$install_directory"
|
||||
chmod +x "$GODOT_BIN"
|
||||
"$GODOT_BIN" --version
|
||||
|
||||
- name: Run the repository quality gate
|
||||
shell: bash
|
||||
run: bash scripts/quality_gate.sh
|
||||
Reference in new issue
Block a user