Update Lua package name for Alpine #36
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
# GitHub Actions workflow file. | |
# | |
# For more information, visit | |
# https://docs.github.com/actions/learn-github-actions. | |
--- | |
name: release | |
# Makes workflow run on Git tag. | |
on: | |
push: | |
tags: | |
- "**" | |
workflow_dispatch: | |
inputs: | |
debug: | |
default: false | |
description: Use Tmate session for debugging | |
type: boolean | |
env: | |
NPM_CONFIG_CACHE: "${{ github.workspace }}/.cache/npm" | |
PIP_CACHE_DIR: "${{ github.workspace }}/.cache/pip" | |
PIP_DISABLE_PIP_VERSION_CHECK: "true" | |
PIP_ROOT_USER_ACTION: ignore | |
POETRY_CACHE_DIR: "${{ github.workspace }}/.cache/pypoetry" | |
POETRY_VIRTUALENVS_IN_PROJECT: "true" | |
PYTHON_KEYRING_BACKEND: "keyring.backends.null.Keyring" | |
jobs: | |
release: | |
name: Make GitHub release | |
permissions: | |
contents: write | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
- name: Cache packages | |
uses: actions/cache@v4 | |
with: | |
path: | | |
.cache | |
.venv | |
node_modules | |
key: >- | |
node-22_python-3.12_${{ runner.os }}_npm-${{ | |
hashFiles('package-lock.json') }}_poetry-${{ | |
hashFiles('poetry.lock') }} | |
- name: Install Just | |
run: >- | |
curl -LSfs https://just.systems/install.sh | bash -s -- --to | |
/usr/local/bin | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v3 | |
- name: Install Node interpreter | |
uses: actions/setup-node@v4 | |
with: | |
node-version: "22" | |
- name: Install Python interpreter | |
uses: actions/setup-python@v5 | |
with: | |
python-version: "3.12" | |
- name: Install development dependencies | |
run: just setup | |
- name: Build packages | |
run: just dist ${{ github.ref_name }} | |
- name: Build and publish collection | |
env: | |
ANSIBLE_GALAXY_TOKEN: ${{ secrets.ANSIBLE_GALAXY_TOKEN }} | |
run: >- | |
poetry run ansible-galaxy collection publish --token | |
"${ANSIBLE_GALAXY_TOKEN}" "dist/scruffaluff-bootware-${{ | |
github.ref_name }}.tar.gz" | |
- name: Create GitHub release | |
id: release | |
uses: softprops/action-gh-release@v2 | |
with: | |
body: >- | |
See the [changelog](https://github.com/scruffaluff/bootware/blob/${{ | |
github.ref_name }}/CHANGELOG.md) for more information. | |
files: | | |
dist/bootware_${{ github.ref_name }}_all.deb | |
dist/bootware_${{ github.ref_name }}_all.deb.sha512 | |
dist/bootware-${{ github.ref_name }}-0-any.pkg.tar.zst | |
dist/bootware-${{ github.ref_name }}-0-any.pkg.tar.zst.sha512 | |
dist/bootware-${{ github.ref_name }}-0.fc33.noarch.rpm | |
dist/bootware-${{ github.ref_name }}-0.fc33.noarch.rpm.sha512 | |
dist/bootware-${{ github.ref_name }}-r0.apk | |
dist/bootware-${{ github.ref_name }}-r0.apk.sha512 | |
dist/scruffaluff-bootware-${{ github.ref_name }}.tar.gz | |
dist/scruffaluff-bootware-${{ github.ref_name }}.tar.gz.sha512 | |
name: Bootware ${{ github.ref_name }} | |
tag_name: ${{ github.ref }} | |
# Homebrew formulas required the checksum of the GitHub release archive | |
# and thus cannot be created before the release. | |
- name: Build Homebrew formula | |
run: scripts/package.sh --version ${{ github.ref_name }} dist brew | |
- name: Upload Homebrew formula to release | |
env: | |
GITHUB_TOKEN: ${{ github.token }} | |
uses: actions/upload-release-asset@v1 | |
with: | |
asset_content_type: text/plain | |
asset_name: bootware.rb | |
asset_path: dist/bootware.rb | |
upload_url: ${{ steps.release.outputs.upload_url }} | |
- name: Setup Tmate session if debug enabled | |
if: >- | |
${{ always() && github.event_name == 'workflow_dispatch' && | |
inputs.debug }} | |
timeout-minutes: 60 | |
uses: mxschmitt/action-tmate@v3 |