Test #519
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
name: Test | |
on: | |
push: | |
pull_request: | |
schedule: | |
- cron: '0 0 * * 5' | |
workflow_dispatch: | |
jobs: | |
Docs: | |
name: '📓 Docs' | |
if: github.event_name != 'pull_request' | |
runs-on: ubuntu-latest | |
steps: | |
- name: '🧰 Checkout' | |
uses: actions/checkout@v3 | |
- name: 🛠️ Get bib files from umarcor/umarcor | |
run: | | |
make -C docs references | |
ls -la docs/references | |
- name: '📓 BuildTheDocs (BTD)' | |
uses: buildthedocs/btd@v0 | |
with: | |
token: ${{ github.token }} | |
skip-deploy: github.event_name == 'pull_request' | |
- name: '📤 Upload artifact: HTML' | |
uses: actions/upload-artifact@v3 | |
with: | |
name: docs | |
path: docs/_build/html | |
Release: | |
runs-on: ubuntu-latest | |
env: | |
QUS_RELEASE: 1 | |
BUILD: debian | |
steps: | |
- uses: actions/checkout@v3 | |
- run: ./.github/setup.sh | |
- run: | | |
./run.sh -a | |
./generate_bin_tests.sh | |
cp test-* releases/ | |
ls releases/ | wc -l | |
- run: ./cli/cli.py debian | |
- uses: pyTooling/Actions/releaser@r0 | |
if: startsWith(github.ref, 'refs/tags/') && github.event_name != 'pull_request' | |
with: | |
token: ${{ github.token }} | |
files: releases/* | |
snapshots: false | |
- run: ./cli/cli.py assets | |
- name: '📤 Upload artifact: builddir' | |
uses: actions/upload-artifact@v3 | |
with: | |
path: | | |
debian.md | |
report.md | |
Images: | |
strategy: | |
fail-fast: false | |
matrix: | |
src: | |
- debian | |
- fedora | |
arch: | |
- x86_64 | |
- i686 | |
- aarch64 | |
- ppc64le | |
- s390x | |
- armhf | |
- armel | |
- mipsel | |
- mips64el | |
exclude: | |
- src: fedora | |
arch: ppc64le | |
- src: fedora | |
arch: armhf | |
- src: fedora | |
arch: armel | |
- src: fedora | |
arch: mipsel | |
- src: fedora | |
arch: mips64el | |
name: 'I: ${{ matrix.src }} · ${{ matrix.arch }}' | |
runs-on: ubuntu-latest | |
steps: | |
- name: Install dependencies for extracting rpms | |
run: sudo apt-get install -y rpm2cpio zstd cpio curl | |
if: matrix.src == 'fedora' | |
- uses: actions/checkout@v3 | |
- run: ./.github/setup.sh | |
- run: BUILD=${{ matrix.src }} ./run.sh -b | |
env: | |
BASE_ARCH: ${{ matrix.arch }} | |
- name: Deploy to DockerHub | |
if: github.event_name != 'pull_request' && github.repository == 'dbhi/qus' | |
uses: pyTooling/Actions/with-post-step@r0 | |
with: | |
main: | | |
# Release | |
echo '${{ secrets.DOCKER_PASS }}' | docker login docker.io -u '${{ secrets.DOCKER_USER }}' --password-stdin | |
docker image ls | |
docker push -a aptman/qus | |
post: docker logout docker.io | |
Manifests: | |
if: github.event_name != 'pull_request' && github.repository == 'dbhi/qus' | |
needs: Images | |
runs-on: ubuntu-latest | |
steps: | |
- name: Enable Docker experimental | |
shell: python3 {0} | |
run: | | |
from pathlib import Path | |
from json import load, dump | |
with (Path.home() / ".docker" / "config.json").open("r+") as cfg: | |
data = load(cfg) | |
data['experimental'] = "enabled" | |
cfg.seek(0) | |
dump(data, cfg, indent=2) | |
- uses: actions/checkout@v3 | |
- run: ./.github/setup.sh | |
- name: Update manifests | |
if: github.event_name != 'pull_request' && github.repository == 'dbhi/qus' | |
uses: pyTooling/Actions/with-post-step@r0 | |
with: | |
main: | | |
# Update manifests | |
echo '${{ secrets.DOCKER_PASS }}' | docker login docker.io -u '${{ secrets.DOCKER_USER }}' --password-stdin | |
./run.sh -m | |
post: docker logout docker.io | |
Action-All: | |
needs: Manifests | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: dbhi/qus/action@main | |
- run: | | |
./.github/get_tests.sh | |
./test-aarch64 | |
./test-riscv64 | |
Action: | |
needs: Manifests | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: ./action | |
with: | |
targets: riscv64 aarch64 | |
- run: | | |
./.github/get_tests.sh | |
./test-aarch64 | |
./test-riscv64 | |
Action-literal: | |
needs: Manifests | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: ./action | |
with: | |
targets: | | |
riscv64 | |
aarch64 | |
- run: | | |
./.github/get_tests.sh | |
./test-aarch64 | |
./test-riscv64 | |
Action-folded: | |
needs: Manifests | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: ./action | |
with: | |
targets: > | |
riscv64 | |
aarch64 | |
- run: | | |
./.github/get_tests.sh | |
./test-aarch64 | |
./test-riscv64 | |
Test: | |
needs: Manifests | |
strategy: | |
fail-fast: false | |
matrix: | |
test: | |
- "" | |
- f | |
- F | |
- c | |
- C | |
- v | |
- V | |
- i | |
- I | |
- d | |
- D | |
- r | |
- R | |
- s | |
- n | |
#- h | |
#- H | |
name: 'T: ${{ matrix.test }}' | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: test | |
run: ./test.sh | |
env: | |
QUS_JOB: ${{ matrix.test }} |