GitXplorerGitXplorer
K

github-actions-deploy-aur

public
117 stars
14 forks
6 issues

Commits

List of commits on branch master.
Verified
88b39eac304723cef47ba1743334198f7a12fe51

Add GitHub Sponsors

KKSXGitHub committed 3 months ago
Verified
a1630144bb5c09eceaa0dec5bac48377f2157f19

docs(readme): add generating PKGBUILD to code snippet

KKSXGitHub committed 4 months ago
Verified
a97f56a8425a7a7f3b8c58607f769c69b089cadb

Merge pull request #42 from Jerry-Terrasse/master

KKSXGitHub committed 5 months ago
Unverified
bc7cf29dc5d3341acbf307befde6d4dbbf1c4e05

add base-devel dependency

JJerry-Terrasse committed 5 months ago
Unverified
32e74b369e077d605a823d29574313d894dd0f31

feat: default `allow_empty_commits` to `false`

KKSXGitHub committed 5 months ago
Verified
e07018655eeea52e5bf4bc4be386e2f503ad290b

Merge pull request #40 from zxkmm/remove_dsa_from_example_usage

KKSXGitHub committed 6 months ago

README

The README file for this repository.

Publish AUR package

GitHub Actions to publish AUR package.

Inputs

pkgname

Required AUR package name.

pkgbuild

Required Path to PKGBUILD file. This file is often generated by prior steps.

assets

Optional Newline-separated glob patterns for additional files to be added to the AUR repository. Glob patterns will be expanded by bash when copying the files to the repository.

updpkgsums

Optional Update checksums using updpkgsums.

test

Optional Check that PKGBUILD could be built.

test_flags

Optional Command line flags for makepkg to build the package (if test is enabled). The default flags are --clean --cleanbuild --nodeps.

post_process

Optional A line of commands to execute after processing the package.

commit_username

Required The username to use when creating the new commit.

commit_email

Required The email to use when creating the new commit.

ssh_private_key

Required Your private key with access to AUR package.

commit_message

Optional Commit message to use when creating the new commit.

allow_empty_commits

Optional Allow empty commits, i.e. commits with no change. The default value is false.

force_push

Optional Use --force when push to the AUR. The default value is false.

ssh_keyscan_types

Optional Comma-separated list of types to use when adding aur.archlinux.org to known hosts.

Example usage

name: aur-publish

on:
  push:
    tags:
      - '*'

jobs:
  aur-publish:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v2

      - name: Generate PKGBUILD
        run: bash ./generate-pkgbuild.bash

      - name: Publish AUR package
        uses: KSXGitHub/github-actions-deploy-aur@<TAG>
        with:
          pkgname: my-awesome-package
          pkgbuild: ./PKGBUILD
          commit_username: ${{ secrets.AUR_USERNAME }}
          commit_email: ${{ secrets.AUR_EMAIL }}
          ssh_private_key: ${{ secrets.AUR_SSH_PRIVATE_KEY }}
          commit_message: Update AUR package
          ssh_keyscan_types: rsa,ecdsa,ed25519

Note: Replace <TAG> in the above code snippet with a tag of this repo.

Tip: To create secrets (such as secrets.AUR_USERNAME, secrets.AUR_EMAIL, and secrets.AUR_SSH_PRIVATE_KEY above), go to $YOUR_GITHUB_REPO_URL/settings/secrets. Read this for more information.

Tip: This action does not generate PKGBUILD for you, you must generate it yourself (e.g. by using actions before this action).

Real-world applications

sane-fmt has a workflow that builds and uploads executables to GitHub Release then generates PKGBUILD files for and use this very action to update aur/sane-fmt and aur/sane-fmt-bin.

pretty-exec has a workflow that builds and uploads executables to GitHub Release then generates PKGBUILD files for and use this very action to update aur/pretty-exec and aur/pretty-exec-bin.

build-fs-tree has a workflow that builds and uploads executables to GitHub Release then generates PKGBUILD files for and use this very action to update aur/build-fs-tree and aur/build-fs-tree-bin.

strip-ansi-cli has a workflow that builds and uploads executables to GitHub Release then generates PKGBUILD files for and use this very action to update aur/strip-ansi and aur/strip-ansi-bin.

parallel-disk-usage has a workflow that builds and uploads executables to GitHub Release then generates PKGBUILD files for and use this very action to update aur/parallel-disk-usage and aur/parallel-disk-usage-bin.

Become a Patron

My Patreon Page.

License

MIT © Hoàng Văn Khải