workflows/sorbet: Rename from Tapioca as it does more than Tapioca now

- This uses the `--update` switch to do both RBI file updates and pruning of
  deleted files from `sorbet/files.yaml`. The assumption is that only
  this automated task will run this command.
This commit is contained in:
Issy Long 2020-09-18 16:07:43 +01:00
parent bb0fc2764e
commit 189d10b32b
No known key found for this signature in database
GPG Key ID: 8247C390DADC67D4

View File

@ -1,8 +1,8 @@
name: Update Tapioca definitions
name: Update Sorbet-related files
on:
push:
paths:
- .github/workflows/tapioca.yml
- .github/workflows/sorbet.yml
branches-ignore:
- master
schedule:
@ -26,7 +26,7 @@ jobs:
run: |
git fetch origin
BRANCH="tapioca-update"
BRANCH="sorbet-files-update"
echo "::set-output name=branch::${BRANCH}"
if git ls-remote --exit-code --heads origin "$BRANCH"; then
@ -37,9 +37,9 @@ jobs:
BRANCH_EXISTS="1"
fi
if brew typecheck --prune-files-list --update-definitions --fail-if-not-changed; then
if brew typecheck --update --fail-if-not-changed; then
git add "$GITHUB_WORKSPACE/Library/Homebrew/sorbet"
git commit -m "sorbet: update RBI files using Tapioca." -m "Autogenerated by [a scheduled GitHub Action](https://github.com/Homebrew/brew/blob/master/.github/workflows/tapioca.yml)."
git commit -m "sorbet: Update RBI files and prune files.yaml." -m "Autogenerated by [a scheduled GitHub Action](https://github.com/Homebrew/brew/blob/master/.github/workflows/sorbet.yml)."
echo "::set-output name=committed::true"
if [ -n "$BRANCH_EXISTS" ]; then
echo "::set-output name=pull_request::true"