Files
packages/.github/workflows/autobuild.yml
T
lea 4d23ed56c6 feat(ci): better build workflows [attempt 2] (#6006) (#6166)
* feat(ci): better build workflows

* fix(ci/json-build): forgot about the type

* chore: test if autobuild works

* Revert "chore: test if autobuild works"

This reverts commit 73fe8e636f.

* fix(ci/build): delay setup git

* fix(ci/build): need to git add all

* fix(ci/build): compact output from jq

* chore(ci/build): add run-name

* fix(ci/autobuild): inherit secrets

Signed-off-by: madomado <madonuko@outlook.com>

* fix(ci/build): inherit secrets

Signed-off-by: madomado <madonuko@outlook.com>

---------

Signed-off-by: madomado <madonuko@outlook.com>
(cherry picked from commit 4cc7cb792a)

# Conflicts:
#	.github/workflows/autobuild.yml
#	.github/workflows/build.yml
#	.github/workflows/json-build.yml

Co-authored-by: madomado <madonuko@outlook.com>
2025-08-26 22:08:58 -05:00

46 lines
1.1 KiB
YAML

# for each folder in anda/
# generate a new workflow for each folder in anda/
name: Automatically build packages
permissions:
contents: read
on:
push:
paths:
- anda/**
branches:
- f42
pull_request:
branches:
- f42
merge_group:
branches:
- f42
workflow_dispatch:
workflow_call:
jobs:
manifest:
runs-on: ubuntu-22.04
outputs:
build_matrix: ${{ steps.generate_build_matrix.outputs.build_matrix }}
container:
image: ghcr.io/terrapkg/builder:f42
options: --cap-add=SYS_ADMIN --privileged
steps:
- name: Set workspace as safe
run: git config --global --add safe.directory "$GITHUB_WORKSPACE"
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Generate build matrix
id: generate_build_matrix
run: anda ci >> $GITHUB_OUTPUT
build:
needs: manifest
uses: ./.github/workflows/json-build.yml
secrets: inherit
with:
packages: ${{ needs.manifest.outputs.build_matrix }}
publish: ${{ github.event_name == 'push' }}