OPS-6322 Add tags and fix permissions dependencies #3
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
--- | |
# ------------------------------------------------------------------------------------------------- | |
# Job Name | |
# ------------------------------------------------------------------------------------------------- | |
name: lint | |
# ------------------------------------------------------------------------------------------------- | |
# When to run | |
# ------------------------------------------------------------------------------------------------- | |
on: | |
# Runs on Pull Requests | |
pull_request: | |
# ------------------------------------------------------------------------------------------------- | |
# What to run | |
# ------------------------------------------------------------------------------------------------- | |
jobs: | |
lint: | |
name: "Lint" | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: False | |
matrix: | |
target: | |
- lint | |
- gen | |
steps: | |
# ------------------------------------------------------------ | |
# Setup repository | |
# ------------------------------------------------------------ | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
# ------------------------------------------------------------ | |
# Lint repository | |
# ------------------------------------------------------------ | |
- name: "make ${{ matrix.target }}" | |
run: | | |
retry() { | |
for n in $(seq ${RETRIES}); do | |
echo "[${n}/${RETRIES}] ${*}"; | |
if eval "${*}"; then | |
echo "[SUCC] ${n}/${RETRIES}"; | |
return 0; | |
fi; | |
sleep 2; | |
echo "[FAIL] ${n}/${RETRIES}"; | |
done; | |
return 1; | |
} | |
retry make "${TARGET}" | |
git diff --quiet || { echo "Build Changes"; git diff; git status; false; } | |
env: | |
TARGET: ${{ matrix.target }} | |
RETRIES: 20 |