Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 24 additions & 0 deletions .github/workflows/build_LoopFollow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,30 @@ jobs:
echo "is_second_instance=false" >> "$GITHUB_OUTPUT"
fi

# When a scheduled run finds nothing new to build, cancel the run so it shows
# as "cancelled" instead of "success" — a green check should always mean a
# new build was made.
cancel_when_no_build:
needs: check_status
name: Cancel run when there is nothing to build
runs-on: ubuntu-latest
permissions:
actions: write
if: |
github.event_name == 'schedule' &&
!(vars.SCHEDULED_BUILD != 'false' && needs.check_status.outputs.IS_SECOND_IN_MONTH == 'true') &&
!(vars.SCHEDULED_SYNC != 'false' && needs.check_status.outputs.NEW_COMMITS == 'true')
steps:
- name: Cancel the run
env:
GH_TOKEN: ${{ github.token }}
run: |
echo "Repository is up to date and no monthly build is due — cancelling this run so it is not reported as a successful build." >> "$GITHUB_STEP_SUMMARY"
gh run cancel ${{ github.run_id }} --repo ${{ github.repository }}
# Keep the job alive until the cancellation lands, so the run ends as
# "cancelled" rather than completing successfully first.
sleep 300

# Checks if Distribution certificate is present and valid, optionally nukes and
# creates new certs if the repository variable ENABLE_NUKE_CERTS == 'true'
# only run if a build is planned
Expand Down
19 changes: 10 additions & 9 deletions fastlane/testflight.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ These instructions allow you to build this Open-Source app without having access
>
> The browser build defaults to automatically updating and building a new version of the app according to this schedule:
>
> * automatically checks for updates weekly on Wednesdays and if updates are found, it will build a new version of the app
> * automatically builds once a month regardless of whether there are updates on the first of the month
> * with each scheduled run (weekly or monthly), a successful Build log appears - if the time is very short, it did not need to build - only the long actions (>5 minutes) built a new app
> * automatically checks for updates weekly on Sundays and if updates are found, it will build a new version of the app
> * automatically builds once a month regardless of whether there are updates, on the second Sunday of the month
> * if a scheduled run finds nothing new to build, the run is cancelled and shows as cancelled (grey) in the Actions list - a green check always means a new build was made and uploaded to TestFlight
>
> It also creates an alive branch, if you don't already have one. See [Why do I have an alive branch?](#why-do-i-have-an-alive-branch).
>
Expand Down Expand Up @@ -195,7 +195,7 @@ You can modify the automation by creating and using some variables.

To configure the automated build more granularly involves creating up to two environment variables: `SCHEDULED_BUILD` and/or `SCHEDULED_SYNC`. See [How to configure a variable](#how-to-configure-a-variable).

Note that the weekly and monthly Build Trio actions will continue, but the actions are modified if one or more of these variables is set to false. **A successful Action Log will still appear, even if no automatic activity happens**.
Note that the weekly and monthly scheduled actions will continue, but the actions are modified if one or more of these variables is set to false. **When a scheduled run ends without building, it shows as cancelled (grey) instead of successful - a green check always means a new build was made**.

* If you want to manually decide when to update your repository to the latest commit, but you want the monthly builds and keep-alive to continue: set `SCHEDULED_SYNC` to false and either do not create `SCHEDULED_BUILD` or set it to true
* If you want to only build when an update has been found: set `SCHEDULED_BUILD` to false and either do not create `SCHEDULED_SYNC` or set it to true
Expand Down Expand Up @@ -228,12 +228,13 @@ Note that the weekly and monthly Build Trio actions will continue, but the actio
Your build will run on the following conditions:

* Default behaviour:
* Run weekly, every Wednesday to check for changes; if there are changes, it will update your repository and build
* Run monthly, every first of the month, if there are changes, it will update your repository; regardless of changes, it will build
* Run weekly, every Sunday to check for changes; if there are changes, it will update your repository and build
* Run monthly, on the second Sunday of the month, if there are changes, it will update your repository; regardless of changes, it will build
* Each time the action runs, it makes a keep-alive commit to the `alive` branch if necessary
* If you disable any automation (both variables set to `false`), no updates, keep-alive or building happens when Build Trio runs
* If you disabled just scheduled synchronization (`SCHEDULED_SYNC` set to`false`), it will only run once a month, on the first of the month, no update will happen; keep-alive will run
* If you disabled just scheduled build (`SCHEDULED_BUILD` set to `false`), it will run once weekly, every Wednesday, to check for changes; if there are changes, it will update and build; keep-alive will run
* If a scheduled run ends without building, it shows as cancelled (grey) instead of successful
* If you disable any automation (both variables set to `false`), no updates, keep-alive or building happens when the scheduled action runs; the run shows as cancelled
* If you disabled just scheduled synchronization (`SCHEDULED_SYNC` set to`false`), it will only build once a month, on the second Sunday of the month, no update will happen; keep-alive will run
* If you disabled just scheduled build (`SCHEDULED_BUILD` set to `false`), it will run once weekly, every Sunday, to check for changes; if there are changes, it will update and build; keep-alive will run

## What if I build using more than one GitHub username

Expand Down
Loading