👷 Update GitHub Actions format (#1363)

This commit is contained in:
Sebastián Ramírez
2024-09-24 00:29:10 +02:00
committed by GitHub
parent cdc7b50fec
commit 32227c4020
6 changed files with 15 additions and 57 deletions

View File

@@ -1,16 +1,16 @@
version: 2 version: 2
updates: updates:
# GitHub Actions # GitHub Actions
- package-ecosystem: "github-actions" - package-ecosystem: github-actions
directory: "/" directory: /
schedule: schedule:
interval: "daily" interval: daily
commit-message: commit-message:
prefix: prefix:
# Python # Python
- package-ecosystem: "pip" - package-ecosystem: pip
directory: "/" directory: /
schedule: schedule:
interval: "daily" interval: daily
commit-message: commit-message:
prefix: prefix:

View File

@@ -21,7 +21,7 @@ jobs:
node-version: lts/* node-version: lts/*
- uses: actions/setup-python@v5 - uses: actions/setup-python@v5
with: with:
python-version: '3.10' python-version: "3.10"
- name: Install uv - name: Install uv
uses: astral-sh/setup-uv@v2 uses: astral-sh/setup-uv@v2
with: with:
@@ -41,15 +41,3 @@ jobs:
git add frontend/src/client git add frontend/src/client
git diff --staged --quiet || git commit -m "✨ Autogenerate frontend client" git diff --staged --quiet || git commit -m "✨ Autogenerate frontend client"
git push git push
# https://github.com/marketplace/actions/alls-green#why
generate-client-alls-green: # This job does nothing and is only used for the branch protection
if: always()
needs:
- generate-client
runs-on: ubuntu-latest
steps:
- name: Decide whether the needed jobs succeeded or failed
uses: re-actors/alls-green@release/v1
with:
jobs: ${{ toJSON(needs) }}

View File

@@ -12,9 +12,9 @@ on:
description: PR number description: PR number
required: true required: true
debug_enabled: debug_enabled:
description: 'Run the build with tmate debugging enabled (https://github.com/marketplace/actions/debugging-with-tmate)' description: "Run the build with tmate debugging enabled (https://github.com/marketplace/actions/debugging-with-tmate)"
required: false required: false
default: 'false' default: "false"
jobs: jobs:
latest-changes: latest-changes:
@@ -34,7 +34,7 @@ jobs:
with: with:
token: ${{ secrets.GITHUB_TOKEN }} token: ${{ secrets.GITHUB_TOKEN }}
latest_changes_file: ./release-notes.md latest_changes_file: ./release-notes.md
latest_changes_header: '## Latest Changes' latest_changes_header: "## Latest Changes"
end_regex: '^## ' end_regex: "^## "
debug_logs: true debug_logs: true
label_header_prefix: '### ' label_header_prefix: "### "

View File

@@ -10,7 +10,6 @@ on:
- synchronize - synchronize
jobs: jobs:
lint-backend: lint-backend:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
@@ -19,22 +18,10 @@ jobs:
- name: Set up Python - name: Set up Python
uses: actions/setup-python@v5 uses: actions/setup-python@v5
with: with:
python-version: '3.10' python-version: "3.10"
- name: Install uv - name: Install uv
uses: astral-sh/setup-uv@v2 uses: astral-sh/setup-uv@v2
with: with:
version: "0.4.15" version: "0.4.15"
- run: uv run bash scripts/lint.sh - run: uv run bash scripts/lint.sh
working-directory: backend working-directory: backend
# https://github.com/marketplace/actions/alls-green#why
lint-backend-alls-green: # This job does nothing and is only used for the branch protection
if: always()
needs:
- lint-backend
runs-on: ubuntu-latest
steps:
- name: Decide whether the needed jobs succeeded or failed
uses: re-actors/alls-green@release/v1
with:
jobs: ${{ toJSON(needs) }}

View File

@@ -16,17 +16,14 @@ jobs:
steps: steps:
- uses: actions/setup-python@v5 - uses: actions/setup-python@v5
with: with:
python-version: '3.9' python-version: "3.10"
- run: pip install smokeshow - run: pip install smokeshow
- uses: actions/download-artifact@v4 - uses: actions/download-artifact@v4
with: with:
name: coverage-html name: coverage-html
path: backend/htmlcov path: backend/htmlcov
github-token: ${{ secrets.GITHUB_TOKEN }} github-token: ${{ secrets.GITHUB_TOKEN }}
run-id: ${{ github.event.workflow_run.id }} run-id: ${{ github.event.workflow_run.id }}
- run: smokeshow upload backend/htmlcov - run: smokeshow upload backend/htmlcov
env: env:
SMOKESHOW_GITHUB_STATUS_DESCRIPTION: Coverage {coverage-percentage} SMOKESHOW_GITHUB_STATUS_DESCRIPTION: Coverage {coverage-percentage}

View File

@@ -10,17 +10,15 @@ on:
- synchronize - synchronize
jobs: jobs:
test-backend: test-backend:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- name: Checkout - name: Checkout
uses: actions/checkout@v4 uses: actions/checkout@v4
- name: Set up Python - name: Set up Python
uses: actions/setup-python@v5 uses: actions/setup-python@v5
with: with:
python-version: '3.10' python-version: "3.10"
- name: Install uv - name: Install uv
uses: astral-sh/setup-uv@v2 uses: astral-sh/setup-uv@v2
with: with:
@@ -40,15 +38,3 @@ jobs:
name: coverage-html name: coverage-html
path: backend/htmlcov path: backend/htmlcov
include-hidden-files: true include-hidden-files: true
# https://github.com/marketplace/actions/alls-green#why
alls-green: # This job does nothing and is only used for the branch protection
if: always()
needs:
- test-backend
runs-on: ubuntu-latest
steps:
- name: Decide whether the needed jobs succeeded or failed
uses: re-actors/alls-green@release/v1
with:
jobs: ${{ toJSON(needs) }}