You're viewing an older version of this GitHub Action. Do you want to see the latest version instead?
GitHub Action
Shovel Bucket Minion
1.5.0.6
Github actions for Shovel buckets
Set of automated actions, which will save time when maintaining bucket, managing issues/pull requets. Using main
tag instead of specific version is highly recommended.
GITHUB_TOKEN
- REQUIRED
- Use
${{ secrets.GITHUB_TOKEN }}
GITH_EMAIL
**- String
SCOOP_BRANCH
- String
- If specified,
shovel config 'SCOOP_BRANCH' $env:SCOOP_BRANCH
will be configured and shovel updated
SKIP_UPDATED
- Anything. Use
1
- If specified, log of checkver utility will not print latest versions
- Anything. Use
SPECIAL_SNOWFLAKES
- String
- List of manifest names joined with
,
used as parameter for auto-pr utility.
**: GITH_EMAIL
environment variable is not required since 1.0.1, but it is recommended.
If email is not specified, commits will not be pushed using account bounded to the email. This will lead to not adding contributions. (See as example commit from github action without user's email)
- ❗❗❗ Protected master branches are not supported, due to security concern from GitHub side ❗❗❗
- Periodically execute automatic updates for all manifests
- Refer to help page for configuration formats
- https://github.com/ScoopInstaller/Excavator alternative
- No need to have custom device, which could run docker or scheduled task for auto-pr 24/7
As soon as new issue is created or label verify
is added to the issue, action is executed.
Based on issue title, specific sub-action is executed.
It could be one of these:
- Hash check fails
- Checkhashes binary is executed for manifest in title
- Result is parsed
- Hash mismatch
- Pull requests with name
<manifest>@<version>: Fix hash
are listed- There is PR already
- The newest one is selected
- Description of this PR is updated with closing directive for created issue
- Comment to the issue is posted with reference to PR
- Label
duplicate
added
- If none
- New branch
<manifest>-hash-fix-<random>
is created - Changes are commited
- New PR is created from this branch
- New branch
- There is PR already
- Labels
hash-fix-needed
,verified
are added to the issue
- Pull requests with name
- No problem
- Comment on issue is posted about hashes being right with list of possible causes
- Label
hash-fix-needed
is removed - Issue is closed
- Binary error
- Label
manifest-fix-needed
is added
- Label
- Hash mismatch
- Download failed
- All urls defined in manifest are retrieved
- Downloading of all urls is executed
- Comment to issue is posted
- If there is problematic URL
- List of these URLs is attached in comment
- Labels
manifest-fix-needed
,verified
,help wanted
are added
- All URLs could be downloaded without problem
- Possible causes are attached in comment
- If there is problematic URL
As soon as PR is created or comment /verify
posted to it, validation tests are executed (see wiki for detailed desciption):
- ❗❗ Pull request created from forked repository cannot be verified due to security concern from GitHub side ❗❗
- Manual
/verify
comment is needed (Ash258/GithubActionsBucketForTesting#176)
- Manual
- Required properties (
License
,Description
) are in place - Hashes of files are correct
- Checkver functionality
- Autoupdate functionality
- Hash extraction finished
- Names could be changed as desired
if
statements are not required- There are only time savers when finding appropriate action log
- Save GitHub resources
#.github\workflows\schedule.yml
on:
schedule:
- cron: '*/0 * * * *'
name: Excavator
jobs:
excavate:
name: Excavator
runs-on: windows-latest
steps:
- uses: actions/checkout@main
- name: Excavator
uses: shovel-org/GithubActions@main
env:
GITH_EMAIL: youremail@mail.com
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SKIP_UPDATED: '1'
#.github\workflows\issues.yml
on:
issues:
types: [ opened, labeled ]
name: Issue
jobs:
issueHandler:
name: Issue Handler
runs-on: windows-latest
steps:
- uses: actions/checkout@main
- name: Issue Handler
uses: shovel-org/GithubActions@main
if: github.event.action == 'opened' || (github.event.action == 'labeled' && contains(github.event.issue.labels.*.name, 'verify'))
env:
GITH_EMAIL: youremail@mail.com # Not needed, but recommended
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
#.github\workflows\issue_commented.yml
on:
issue_comment:
types: [ created ]
name: Commented Pull Request
jobs:
pullRequestHandler:
name: Pull Request Validator
runs-on: windows-latest
steps:
- uses: actions/checkout@main
- name: Pull Request Validator
uses: shovel-org/GithubActions@main
if: startsWith(github.event.comment.body, '/verify')
env:
GITH_EMAIL: youremail@mail.com # Not needed, but recommended
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
#.github\workflows\pull_request.yml
on:
pull_request:
types: [ opened ]
name: Pull Requests
jobs:
pullRequestHandler:
name: Pull Request Validator
runs-on: windows-latest
steps:
- uses: actions/checkout@main
- name: Pull Request Validator
uses: shovel-org/GithubActions@main
env:
GITH_EMAIL: youremail@mail.com # Not needed, but recommended
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}