Files
pyenv/.github/workflows/build.yml
T
2026-08-11 14:46:19 -03:00

63 lines
1.8 KiB
YAML

# SPDX-FileCopyrightText: 2026 Christian Tosta
# SPDX-License-Identifier: GPL-2.0-or-later
# @file .github/workflows/build.yml
# @brief Simplified master workflow using CMake workflows
name: Pyenv Build & Release
on:
push:
tags:
- "v*"
jobs:
release-ci:
runs-on: ubuntu-24.04
outputs:
VERSION: ${{ steps.step_getlatest_tag.outputs.VERSION }}
steps:
- name: Checkout local
uses: actions/checkout@v4
with:
repository: ${{ github.repository }}
sparse-checkout: |
.github/workflows
- name: Install build dependencies
run: sudo apt-get install git -y -qq
- name: Get latest pyenv release tag
id: step_getlatest_tag
run: |
latest_tag=$(git -c 'versionsort.suffix=-' ls-remote --exit-code --refs --sort='version:refname' --tags https://github.com/pyenv/pyenv '*.*' \
| tail --lines=1 | cut --delimiter='/' --fields=3)
test ! -z "$latest_tag" && echo "LATEST_TAG=$latest_tag" >> "$GITHUB_ENV" || exit 1
echo "VERSION=$(echo $latest_tag | sed 's/v//')" >> "$GITHUB_OUTPUT"
- name: Save version
run: echo ${{ steps.step_getlatest_tag.outputs.VERSION }} > VERSION
- name: Upload version
uses: actions/upload-artifact@v4
with:
name: VERSION
path: VERSION
retention-days: 1
debian:
needs: release-ci
uses: ./.github/workflows/targets/debian.yml
with:
containers: "['debian:trixie','debian:bookworm']"
fedora:
needs: release-ci
uses: ./.github/workflows/targets/fedora.yml
with:
containers: "['fedora:44','fedora:45','fedora:latest']"
publish:
needs: [debian, fedora]
uses: ./.github/workflows/release.yml