From c9118ad67a365a4b376ebeaf6a23a87ef33f2561 Mon Sep 17 00:00:00 2001 From: ReenigneArcher <42013603+ReenigneArcher@users.noreply.github.com> Date: Thu, 28 Jul 2022 18:42:50 -0400 Subject: [PATCH] add option to update archlinux-keyring --- README.md | 21 +++++++++++---------- action.yml | 5 +++++ entrypoint.sh | 7 +++++++ 3 files changed, 23 insertions(+), 10 deletions(-) diff --git a/README.md b/README.md index 436fcad..56b396f 100644 --- a/README.md +++ b/README.md @@ -21,16 +21,17 @@ Here's what this action can do: Following inputs can be used as `step.with` keys -| Name | Type | Default | Required | Description | -| ------------ | ------- | ------------------ | -------- | -------------------------------------------------------------------------------- | -| `path` | String | | `false` | Path where PKGBUILD is located. This path always located under $GITHUB_WORKSPACE | -| `pkgver` | String | | `false` | Update `pkgver` on your PKGBUILD | -| `pkgrel` | Integer | | `false` | Update `pkgrel` on your PKGBUILD | -| `updpkgsums` | Boolean | `false` | `false` | Update checksums on your PKGBUILD | -| `srcinfo` | Boolean | `false` | `false` | Generate new .SRCINFO | -| `namcap` | Boolean | `true` | `false` | Validate PKGBUILD | -| `flags` | String | `-cfs --noconfirm` | `false` | Flags after `makepkg` command. Leave this empty will disable this command. | -| `aur` | Boolean | `false` | `false` | Resolve dependencies using paru | +| Name | Type | Default | Required | Description | +| -------------------------- | ------- | ------------------ | -------- | -------------------------------------------------------------------------------- | +| `path` | String | | `false` | Path where PKGBUILD is located. This path always located under $GITHUB_WORKSPACE | +| `pkgver` | String | | `false` | Update `pkgver` on your PKGBUILD | +| `pkgrel` | Integer | | `false` | Update `pkgrel` on your PKGBUILD | +| `updpkgsums` | Boolean | `false` | `false` | Update checksums on your PKGBUILD | +| `srcinfo` | Boolean | `false` | `false` | Generate new .SRCINFO | +| `namcap` | Boolean | `true` | `false` | Validate PKGBUILD | +| `flags` | String | `-cfs --noconfirm` | `false` | Flags after `makepkg` command. Leave this empty will disable this command. | +| `aur` | Boolean | `false` | `false` | Resolve dependencies using paru | +| `update_archlinux_keyring` | Boolean | `true` | `false` | Update the archlinux keyring | ### Examples diff --git a/action.yml b/action.yml index dcce652..b6f1a02 100644 --- a/action.yml +++ b/action.yml @@ -39,6 +39,10 @@ inputs: description: 'Resolve dependencies using paru' default: 'false' required: false + update_archlinux_keyring: + description: 'Update archlinux-keyring' + default: 'true' + required: false runs: using: 'docker' @@ -52,3 +56,4 @@ runs: - ${{ inputs.flags }} - ${{ inputs.namcap }} - ${{ inputs.aur }} + - ${{ inputs.update_archlinux_keyring }} diff --git a/entrypoint.sh b/entrypoint.sh index ea2555f..42cc504 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -13,6 +13,13 @@ cp -rfv "$GITHUB_WORKSPACE"/.git ./ cp -fv "$WORKPATH"/PKGBUILD ./ echo "::endgroup::" +# Update archlinux-keyring +if [[ $INPUT_ARCHLINUX_KEYRING == true ]]; then + echo "::group::Updating archlinux-keyring" + pacman -S archlinux-keyring + echo "::endgroup::" +fi + # Update pkgver if [[ -n $INPUT_PKGVER ]]; then echo "::group::Updating pkgver on PKGBUILD"