arch-package-release/README.md

62 lines
2.6 KiB
Markdown
Raw Normal View History

2024-12-27 15:45:07 +01:00
# Arch Package Release Action
This action pushes Arch packages to a Forgejo Arch package repository. It could
be run inside an `archlinux` container, like the one we provide at
[aur/runner-image](https://git.michaelsasser.org/aur/runner-image), which comes
with all the necessary tools, but it is not required. This action only depends
on curl.
## Inputs
| Name | Default | Required | Description |
| ------------------------- | --------------------------------- | -------- | ------------------------------------------------------ |
| `package` | (Autodetect) | No | Path to the package |
| `package_owner` | `'${{ gitea.repository_owner }}'` | No | The name of the package owner |
| `package_repository_name` | `'extra'` | No | The name of the Arch package repository e.g. os, extra |
| `username` | `'${{ gitea.actor }}'` | No | The username used for pushing the package |
| `forge_url` | `'${{ gitea.server_url }}'` | No | The URL to the forge the package is pushed to. |
| `PERSONAL_ACCESS_TOKEN` | | Yes | The PAT for used for pushing the package |
## Example usage
This example shows how this action can be used together with
[aur/makepkg](https://git.michaelsasser.org/aur/makepkg), which builds the
package beforehand.
```yaml
jobs:
build:
name: Build & Lint
runs-on: ubuntu-latest-amd64
container:
image: "git.michaelsasser.org/aur/runner-image:latest"
credentials:
username: ${{ vars.USERNAME_ACTIONS }}
password: ${{ secrets.PERSONAL_ACCESS_TOKEN_ACTIONS }}
steps:
- name: Checkout
uses: https://git.michaelsasser.org/actions/checkout@v4
- name: Build Package
id: build
uses: https://git.michaelsasser.org/actions/makepkg@main
2024-12-27 16:12:36 +01:00
- name: Push Package
2024-12-27 15:45:07 +01:00
uses: https://git.michaelsasser.org/actions/arch-package-release@main
with:
package: ${{ steps.build.outputs.package }}
PERSONAL_ACCESS_TOKEN: ${{ secrets.PERSONAL_ACCESS_TOKEN }}
```
## Semantic Versioning and Branching Model
This action uses [SemVer](https://semver.org/) for its release cycle and
follows the
[GitHub Flow](https://docs.github.com/en/get-started/using-github/github-flow).
## License
Copyright &copy; 2024 Michael Sasser <Info@MichaelSasser.org>. Released under
the MIT license.