From a68758871bd4ed8545fc011d04c23c72eb3f2ce8 Mon Sep 17 00:00:00 2001 From: Pete Schwamb Date: Sat, 13 Jul 2024 15:34:27 -0500 Subject: [PATCH 01/24] Update LoopWorkspace to 3.5.0 dev Loop --- Loop | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Loop b/Loop index 6cf0285e13..1aaee2db49 160000 --- a/Loop +++ b/Loop @@ -1 +1 @@ -Subproject commit 6cf0285e13f6523339b6a4758558cd66d0153c2e +Subproject commit 1aaee2db4953dbcdbe71a15cad967dbb190dc238 From 37cb1a010c2b906fb2c8bb0ffa9170d81de168e5 Mon Sep 17 00:00:00 2001 From: Pete Schwamb Date: Wed, 21 Aug 2024 09:40:02 -0500 Subject: [PATCH 02/24] Omnipod changes --- OmniBLE | 2 +- OmniKit | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/OmniBLE b/OmniBLE index 85fc3c6d48..e398345845 160000 --- a/OmniBLE +++ b/OmniBLE @@ -1 +1 @@ -Subproject commit 85fc3c6d4805d580acdf6592b220717b6e842558 +Subproject commit e39834584548821adf442f13abed0d5cfd237a72 diff --git a/OmniKit b/OmniKit index a80e38b1b7..849dc7abc8 160000 --- a/OmniKit +++ b/OmniKit @@ -1 +1 @@ -Subproject commit a80e38b1b7f203014b461f8aff8cead2c067e39d +Subproject commit 849dc7abc821728dae7e064176a409e6ceb0dadd From a32a19d50eab5e7ad6f2d3bd1db9b6bcb9578271 Mon Sep 17 00:00:00 2001 From: Pete Schwamb Date: Wed, 21 Aug 2024 10:08:01 -0500 Subject: [PATCH 03/24] Update submodules --- CGMBLEKit | 2 +- G7SensorKit | 2 +- LoopKit | 2 +- OmniBLE | 2 +- OmniKit | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/CGMBLEKit b/CGMBLEKit index 905cc0a585..4adef26620 160000 --- a/CGMBLEKit +++ b/CGMBLEKit @@ -1 +1 @@ -Subproject commit 905cc0a58509e417aa7bb2ef9dacfb36f009231c +Subproject commit 4adef2662060f7d11d1abd8d099c3e022bf00cef diff --git a/G7SensorKit b/G7SensorKit index b5e992e211..2be3eb29b0 160000 --- a/G7SensorKit +++ b/G7SensorKit @@ -1 +1 @@ -Subproject commit b5e992e211d2ac6224acb105dd97fb484767da72 +Subproject commit 2be3eb29b0a18aa89f8b60281341e46e07d024e5 diff --git a/LoopKit b/LoopKit index 873b3b7c40..3ce43ded23 160000 --- a/LoopKit +++ b/LoopKit @@ -1 +1 @@ -Subproject commit 873b3b7c406cfc982f9061afb5f5e27e88d9208d +Subproject commit 3ce43ded238a776f7c8a8a9bea339db47adc0c20 diff --git a/OmniBLE b/OmniBLE index e398345845..b82d2e1fff 160000 --- a/OmniBLE +++ b/OmniBLE @@ -1 +1 @@ -Subproject commit e39834584548821adf442f13abed0d5cfd237a72 +Subproject commit b82d2e1fff5f0fccc42145fcbbe4731b80898fff diff --git a/OmniKit b/OmniKit index 849dc7abc8..3a75484ba0 160000 --- a/OmniKit +++ b/OmniKit @@ -1 +1 @@ -Subproject commit 849dc7abc821728dae7e064176a409e6ceb0dadd +Subproject commit 3a75484ba062f647e9c5ff0291948859c77ba9b2 From e31c438f37890ef81a2bd7af351d94a25bd66eaf Mon Sep 17 00:00:00 2001 From: Mike Plante <82073483+MikePlante1@users.noreply.github.com> Date: Sat, 5 Oct 2024 12:17:54 -0400 Subject: [PATCH 04/24] Add branch+commit to "What to Test" field in TestFlight. (#97) Adds the branch and last commit to the "What to Test" field in TestFlight to more easily determine the version of each available option in your TestFlight is. --- fastlane/Fastfile | 1 + 1 file changed, 1 insertion(+) diff --git a/fastlane/Fastfile b/fastlane/Fastfile index f918b3aa41..a8cb9278e9 100644 --- a/fastlane/Fastfile +++ b/fastlane/Fastfile @@ -156,6 +156,7 @@ platform :ios do skip_submission: false, ipa: "Loop.ipa", skip_waiting_for_build_processing: true, + changelog: git_branch+" "+last_git_commit[:abbreviated_commit_hash], ) end From b36318a803ee3f98f7cd3155161de5714583b230 Mon Sep 17 00:00:00 2001 From: Bastien Date: Sat, 5 Oct 2024 18:19:02 +0200 Subject: [PATCH 05/24] update actions/checkout to v4 (#118) From ec86060d1004e77adb993937ca639b022e2214b0 Mon Sep 17 00:00:00 2001 From: Marion Barker <19607791+marionbarker@users.noreply.github.com> Date: Sun, 6 Oct 2024 11:40:58 -0700 Subject: [PATCH 06/24] Update Gemfile.lock for Fastlane 2.223.1 (#207) --- Gemfile.lock | 49 +++++++++++++++++++++++-------------------------- 1 file changed, 23 insertions(+), 26 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index 1ff12d5487..8caeede216 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -10,20 +10,20 @@ GEM artifactory (3.0.17) atomos (0.1.3) aws-eventstream (1.3.0) - aws-partitions (1.949.0) - aws-sdk-core (3.200.0) + aws-partitions (1.981.0) + aws-sdk-core (3.209.1) aws-eventstream (~> 1, >= 1.3.0) aws-partitions (~> 1, >= 1.651.0) - aws-sigv4 (~> 1.8) + aws-sigv4 (~> 1.9) jmespath (~> 1, >= 1.6.1) - aws-sdk-kms (1.87.0) - aws-sdk-core (~> 3, >= 3.199.0) - aws-sigv4 (~> 1.1) - aws-sdk-s3 (1.155.0) - aws-sdk-core (~> 3, >= 3.199.0) + aws-sdk-kms (1.94.0) + aws-sdk-core (~> 3, >= 3.207.0) + aws-sigv4 (~> 1.5) + aws-sdk-s3 (1.166.0) + aws-sdk-core (~> 3, >= 3.207.0) aws-sdk-kms (~> 1) - aws-sigv4 (~> 1.8) - aws-sigv4 (1.8.0) + aws-sigv4 (~> 1.5) + aws-sigv4 (1.10.0) aws-eventstream (~> 1, >= 1.0.2) babosa (1.0.4) base64 (0.2.0) @@ -40,7 +40,7 @@ GEM dotenv (2.8.1) emoji_regex (3.2.3) excon (0.109.0) - faraday (1.10.3) + faraday (1.10.4) faraday-em_http (~> 1.0) faraday-em_synchrony (~> 1.0) faraday-excon (~> 1.1) @@ -61,15 +61,15 @@ GEM faraday-httpclient (1.0.1) faraday-multipart (1.0.4) multipart-post (~> 2) - faraday-net_http (1.0.1) + faraday-net_http (1.0.2) faraday-net_http_persistent (1.2.0) faraday-patron (1.0.0) faraday-rack (1.0.0) faraday-retry (1.0.3) - faraday_middleware (1.2.0) + faraday_middleware (1.2.1) faraday (~> 1.0) fastimage (2.3.1) - fastlane (2.221.1) + fastlane (2.223.1) CFPropertyList (>= 2.3, < 4.0.0) addressable (>= 2.8, < 3.0.0) artifactory (~> 3.0) @@ -148,14 +148,14 @@ GEM os (>= 0.9, < 2.0) signet (>= 0.16, < 2.a) highline (2.0.3) - http-cookie (1.0.6) + http-cookie (1.0.7) domain_name (~> 0.5) httpclient (2.8.3) jmespath (1.6.2) json (2.7.2) - jwt (2.8.2) + jwt (2.9.1) base64 - mini_magick (4.13.1) + mini_magick (4.13.2) mini_mime (1.1.5) multi_json (1.15.0) multipart-post (2.4.1) @@ -172,8 +172,7 @@ GEM trailblazer-option (>= 0.1.1, < 0.2.0) uber (< 0.2.0) retriable (3.1.2) - rexml (3.2.9) - strscan + rexml (3.3.7) rouge (2.0.7) ruby2_keywords (0.0.5) rubyzip (2.3.2) @@ -186,7 +185,6 @@ GEM simctl (1.6.10) CFPropertyList naturally - strscan (3.1.0) terminal-notifier (2.0.0) terminal-table (3.0.2) unicode-display_width (>= 1.1.1, < 3) @@ -196,18 +194,16 @@ GEM tty-spinner (0.9.3) tty-cursor (~> 0.7) uber (0.1.0) - unf (0.1.4) - unf_ext - unf_ext (0.0.9.1) - unicode-display_width (2.5.0) + unf (0.2.0) + unicode-display_width (2.6.0) word_wrap (1.0.0) - xcodeproj (1.24.0) + xcodeproj (1.25.0) CFPropertyList (>= 2.3.3, < 4.0) atomos (~> 0.1.3) claide (>= 1.0.2, < 2.0) colored2 (~> 3.1) nanaimo (~> 0.3.0) - rexml (~> 3.2.4) + rexml (>= 3.3.2, < 4.0) xcpretty (0.3.0) rouge (~> 2.0.7) xcpretty-travis-formatter (1.0.1) @@ -218,6 +214,7 @@ PLATFORMS arm64-darwin-22 arm64-darwin-23 x86_64-darwin-19 + x86_64-darwin-24 x86_64-linux DEPENDENCIES From ab1c67e17c7d564a6b6020fae839d003a8b1102b Mon Sep 17 00:00:00 2001 From: marionbarker Date: Sat, 25 Jan 2025 14:54:21 -0800 Subject: [PATCH 07/24] update Browser Build features to match main branch --- .github/workflows/add_identifiers.yml | 11 +- .github/workflows/build_loop.yml | 325 ++++++++++++++----------- .github/workflows/create_certs.yml | 11 +- .github/workflows/validate_secrets.yml | 40 +-- fastlane/Fastfile | 1 - 5 files changed, 219 insertions(+), 169 deletions(-) diff --git a/.github/workflows/add_identifiers.yml b/.github/workflows/add_identifiers.yml index aab334ab6c..8ff87a55f5 100644 --- a/.github/workflows/add_identifiers.yml +++ b/.github/workflows/add_identifiers.yml @@ -24,8 +24,15 @@ jobs: # Patch Fastlane Match to not print tables - name: Patch Match Tables - run: find /usr/local/lib/ruby/gems -name table_printer.rb | xargs sed -i "" "/puts(Terminal::Table.new(params))/d" - + run: | + TABLE_PRINTER_PATH=$(ruby -e 'puts Gem::Specification.find_by_name("fastlane").gem_dir')/match/lib/match/table_printer.rb + if [ -f "$TABLE_PRINTER_PATH" ]; then + sed -i "" "/puts(Terminal::Table.new(params))/d" "$TABLE_PRINTER_PATH" + else + echo "table_printer.rb not found" + exit 1 + fi + # Install project dependencies - name: Install Project Dependencies run: bundle install diff --git a/.github/workflows/build_loop.yml b/.github/workflows/build_loop.yml index dc84dbee88..254c4015fb 100644 --- a/.github/workflows/build_loop.yml +++ b/.github/workflows/build_loop.yml @@ -2,26 +2,27 @@ name: 4. Build Loop run-name: Build Loop (${{ github.ref_name }}) on: workflow_dispatch: - + ## Remove the "#" sign from the beginning of the line below to get automated builds on push (code changes in your repository) #push: - + schedule: - - cron: '0 8 * * 3' # Checks for updates at 08:00 UTC every Wednesday - - cron: '0 6 1 * *' # Builds the app on the 1st of every month at 06:00 UTC + - cron: "0 8 * * 3" # Checks for updates at 08:00 UTC every Wednesday + - cron: "0 6 1 * *" # Builds the app on the 1st of every month at 06:00 UTC env: UPSTREAM_REPO: LoopKit/LoopWorkspace UPSTREAM_BRANCH: ${{ github.ref_name }} # branch on upstream repository to sync from (replace with specific branch name if needed) TARGET_BRANCH: ${{ github.ref_name }} # target branch on fork to be kept in sync, and target branch on upstream to be kept alive (replace with specific branch name if needed) - ALIVE_BRANCH: alive + ALIVE_BRANCH_MAIN: alive-main + ALIVE_BRANCH_DEV: alive-dev jobs: validate: name: Validate uses: ./.github/workflows/validate_secrets.yml secrets: inherit - + # Checks if GH_PAT holds workflow permissions # Checks for existence of alive branch; if non-existent creates it check_alive_and_permissions: @@ -32,126 +33,155 @@ jobs: contents: write outputs: WORKFLOW_PERMISSION: ${{ steps.workflow-permission.outputs.has_permission }} - + steps: - - name: Check for workflow permissions - id: workflow-permission - env: - TOKEN_TO_CHECK: ${{ secrets.GH_PAT }} - run: | - PERMISSIONS=$(curl -sS -f -I -H "Authorization: token ${{ env.TOKEN_TO_CHECK }}" https://api.github.com | grep ^x-oauth-scopes: | cut -d' ' -f2-); - - if [[ $PERMISSIONS =~ "workflow" || $PERMISSIONS == "" ]]; then - echo "GH_PAT holds workflow permissions or is fine-grained PAT." - echo "has_permission=true" >> $GITHUB_OUTPUT # Set WORKFLOW_PERMISSION to false. - else - echo "GH_PAT lacks workflow permissions." - echo "Automated build features will be skipped!" - echo "has_permission=false" >> $GITHUB_OUTPUT # Set WORKFLOW_PERMISSION to false. - fi - - - name: Check for alive branch - if: steps.workflow-permission.outputs.has_permission == 'true' - env: - GITHUB_TOKEN: ${{ secrets.GH_PAT }} - run: | - if [[ "$(gh api -H "Accept: application/vnd.github+json" /repos/${{ github.repository_owner }}/LoopWorkspace/branches | jq --raw-output 'any(.name=="alive")')" == "true" ]]; then - echo "Branch 'alive' exists." - echo "ALIVE_BRANCH_EXISTS=true" >> $GITHUB_ENV # Set ALIVE_BRANCH_EXISTS to true - else - echo "Branch 'alive' does not exist." - echo "ALIVE_BRANCH_EXISTS=false" >> $GITHUB_ENV # Set ALIVE_BRANCH_EXISTS to false - fi - - - name: Create alive branch - if: env.ALIVE_BRANCH_EXISTS == 'false' - env: - GITHUB_TOKEN: ${{ secrets.GH_PAT }} - run: | - # Get ref for LoopKit/LoopWorkspace:dev - SHA=$(curl -sS https://api.github.com/repos/${{ env.UPSTREAM_REPO }}/git/refs \ - | jq '.[] | select(.ref == "refs/heads/dev" ) | .object.sha' \ - | tr -d '"' - ); - - # Create alive branch based on LoopKit/LoopWorkspace:dev - gh api \ - --method POST \ - -H "Authorization: token $GITHUB_TOKEN" \ - -H "Accept: application/vnd.github.v3+json" \ - /repos/${{ github.repository_owner }}/LoopWorkspace/git/refs \ - -f ref='refs/heads/alive' \ - -f sha=$SHA - + - name: Check for workflow permissions + id: workflow-permission + env: + TOKEN_TO_CHECK: ${{ secrets.GH_PAT }} + run: | + PERMISSIONS=$(curl -sS -f -I -H "Authorization: token ${{ env.TOKEN_TO_CHECK }}" https://api.github.com | grep ^x-oauth-scopes: | cut -d' ' -f2-); + + if [[ $PERMISSIONS =~ "workflow" || $PERMISSIONS == "" ]]; then + echo "GH_PAT holds workflow permissions or is fine-grained PAT." + echo "has_permission=true" >> $GITHUB_OUTPUT # Set WORKFLOW_PERMISSION to false. + else + echo "GH_PAT lacks workflow permissions." + echo "Automated build features will be skipped!" + echo "has_permission=false" >> $GITHUB_OUTPUT # Set WORKFLOW_PERMISSION to false. + fi + + - name: Check for alive branches + if: steps.workflow-permission.outputs.has_permission == 'true' + env: + GITHUB_TOKEN: ${{ secrets.GH_PAT }} + run: | + if [[ $(gh api -H "Accept: application/vnd.github+json" /repos/${{ github.repository_owner }}/LoopWorkspace/branches | jq --raw-output '[.[] | select(.name == "alive-main" or .name == "alive-dev")] | length > 0') == "true" ]]; then + echo "Branches 'alive-main' or 'alive-dev' exist." + echo "ALIVE_BRANCH_EXISTS=true" >> $GITHUB_ENV + else + echo "Branches 'alive-main' and 'alive-dev' do not exist." + echo "ALIVE_BRANCH_EXISTS=false" >> $GITHUB_ENV + fi + + - name: Create alive branches + if: env.ALIVE_BRANCH_EXISTS == 'false' + env: + GITHUB_TOKEN: ${{ secrets.GH_PAT }} + run: | + # Get ref for LoopKit/LoopWorkspace:main + SHA_MAIN=$(curl -sS -H "Authorization: token $GITHUB_TOKEN" https://api.github.com/repos/${{ env.UPSTREAM_REPO }}/git/refs/heads/main | jq -r '.object.sha') + + # Get ref for LoopKit/LoopWorkspace:dev + SHA_DEV=$(curl -sS -H "Authorization: token $GITHUB_TOKEN" https://api.github.com/repos/${{ env.UPSTREAM_REPO }}/git/refs/heads/dev | jq -r '.object.sha') + + # Create alive-main branch based on LoopKit/LoopWorkspace:main + gh api \ + --method POST \ + -H "Authorization: token $GITHUB_TOKEN" \ + -H "Accept: application/vnd.github.v3+json" \ + /repos/${{ github.repository_owner }}/LoopWorkspace/git/refs \ + -f ref='refs/heads/alive-main' \ + -f sha=$SHA_MAIN + + # Create alive-dev branch based on LoopKit/LoopWorkspace:dev + gh api \ + --method POST \ + -H "Authorization: token $GITHUB_TOKEN" \ + -H "Accept: application/vnd.github.v3+json" \ + /repos/${{ github.repository_owner }}/LoopWorkspace/git/refs \ + -f ref='refs/heads/alive-dev' \ + -f sha=$SHA_DEV + # Checks for changes in upstream repository; if changes exist prompts sync for build # Performs keepalive to avoid stale fork check_latest_from_upstream: needs: [validate, check_alive_and_permissions] runs-on: ubuntu-latest name: Check upstream and keep alive - outputs: + outputs: NEW_COMMITS: ${{ steps.sync.outputs.has_new_commits }} - + ABORT_SYNC: ${{ steps.check_branch.outputs.ABORT_SYNC }} + steps: - - name: Checkout target repo - if: | - needs.check_alive_and_permissions.outputs.WORKFLOW_PERMISSION == 'true' && - (vars.SCHEDULED_BUILD != 'false' || vars.SCHEDULED_SYNC != 'false') - uses: actions/checkout@v4 - with: - token: ${{ secrets.GH_PAT }} - ref: alive - - - name: Sync upstream changes - if: | # do not run the upstream sync action on the upstream repository - needs.check_alive_and_permissions.outputs.WORKFLOW_PERMISSION == 'true' && - vars.SCHEDULED_SYNC != 'false' && github.repository_owner != 'LoopKit' - id: sync - uses: aormsby/Fork-Sync-With-Upstream-action@v3.4.1 - with: - target_sync_branch: ${{ env.ALIVE_BRANCH }} - shallow_since: 6 months ago - target_repo_token: ${{ secrets.GH_PAT }} - upstream_sync_branch: ${{ env.UPSTREAM_BRANCH }} - upstream_sync_repo: ${{ env.UPSTREAM_REPO }} - - # Display a sample message based on the sync output var 'has_new_commits' - - name: New commits found - if: | - needs.check_alive_and_permissions.outputs.WORKFLOW_PERMISSION == 'true' && - vars.SCHEDULED_SYNC != 'false' && steps.sync.outputs.has_new_commits == 'true' - run: echo "New commits were found to sync." - - - name: No new commits - if: | - needs.check_alive_and_permissions.outputs.WORKFLOW_PERMISSION == 'true' && - vars.SCHEDULED_SYNC != 'false' && steps.sync.outputs.has_new_commits == 'false' - run: echo "There were no new commits." - - - name: Show value of 'has_new_commits' - if: needs.check_alive_and_permissions.outputs.WORKFLOW_PERMISSION == 'true' && vars.SCHEDULED_SYNC != 'false' - run: | - echo ${{ steps.sync.outputs.has_new_commits }} - echo "NEW_COMMITS=${{ steps.sync.outputs.has_new_commits }}" >> $GITHUB_OUTPUT - - # Keep repository "alive": add empty commits to ALIVE_BRANCH after "time_elapsed" days of inactivity to avoid inactivation of scheduled workflows - - name: Keep alive - if: | - needs.check_alive_and_permissions.outputs.WORKFLOW_PERMISSION == 'true' && - (vars.SCHEDULED_BUILD != 'false' || vars.SCHEDULED_SYNC != 'false') - uses: gautamkrishnar/keepalive-workflow@v1 # using the workflow with default settings - with: - time_elapsed: 20 # Time elapsed from the previous commit to trigger a new automated commit (in days) - - - name: Show scheduled build configuration message - if: needs.check_alive_and_permissions.outputs.WORKFLOW_PERMISSION != 'true' - run: | - echo "### :calendar: Scheduled Sync and Build Disabled :mobile_phone_off:" >> $GITHUB_STEP_SUMMARY - echo "You have not yet configured the scheduled sync and build for Loop's browser build." >> $GITHUB_STEP_SUMMARY - echo "Synchronizing your fork of LoopWorkspace with the upstream repository LoopKit/LoopWorkspace will be skipped." >> $GITHUB_STEP_SUMMARY - echo "If you want to enable automatic builds and updates for your Loop, please follow the instructions \ - under the following path LoopWorkspace/fastlane/testflight.md." >> $GITHUB_STEP_SUMMARY - + - name: Check if running on main or dev branch + if: | + needs.check_alive_and_permissions.outputs.WORKFLOW_PERMISSION == 'true' && + (vars.SCHEDULED_BUILD != 'false' || vars.SCHEDULED_SYNC != 'false') + id: check_branch + run: | + if [ "${GITHUB_REF##*/}" = "main" ]; then + echo "Running on main branch" + echo "ALIVE_BRANCH=${ALIVE_BRANCH_MAIN}" >> $GITHUB_OUTPUT + echo "ABORT_SYNC=false" >> $GITHUB_OUTPUT + elif [ "${GITHUB_REF##*/}" = "dev" ]; then + echo "Running on dev branch" + echo "ALIVE_BRANCH=${ALIVE_BRANCH_DEV}" >> $GITHUB_OUTPUT + echo "ABORT_SYNC=false" >> $GITHUB_OUTPUT + else + echo "Not running on main or dev branch" + echo "ABORT_SYNC=true" >> $GITHUB_OUTPUT + fi + + - name: Checkout target repo + if: | + needs.check_alive_and_permissions.outputs.WORKFLOW_PERMISSION == 'true' && + (vars.SCHEDULED_BUILD != 'false' || vars.SCHEDULED_SYNC != 'false') + uses: actions/checkout@v4 + with: + token: ${{ secrets.GH_PAT }} + ref: ${{ steps.check_branch.outputs.ALIVE_BRANCH }} + + - name: Sync upstream changes + if: | # do not run the upstream sync action on the upstream repository + needs.check_alive_and_permissions.outputs.WORKFLOW_PERMISSION == 'true' && + vars.SCHEDULED_SYNC != 'false' && github.repository_owner != 'LoopKit' && steps.check_branch.outputs.ABORT_SYNC == 'false' + id: sync + uses: aormsby/Fork-Sync-With-Upstream-action@v3.4.1 + with: + target_sync_branch: ${{ steps.check_branch.outputs.ALIVE_BRANCH }} + shallow_since: 6 months ago + target_repo_token: ${{ secrets.GH_PAT }} + upstream_sync_branch: ${{ env.UPSTREAM_BRANCH }} + upstream_sync_repo: ${{ env.UPSTREAM_REPO }} + + # Display a sample message based on the sync output var 'has_new_commits' + - name: New commits found + if: | + needs.check_alive_and_permissions.outputs.WORKFLOW_PERMISSION == 'true' && + vars.SCHEDULED_SYNC != 'false' && steps.sync.outputs.has_new_commits == 'true' + run: echo "New commits were found to sync." + + - name: No new commits + if: | + needs.check_alive_and_permissions.outputs.WORKFLOW_PERMISSION == 'true' && + vars.SCHEDULED_SYNC != 'false' && steps.sync.outputs.has_new_commits == 'false' + run: echo "There were no new commits." + + - name: Show value of 'has_new_commits' + if: needs.check_alive_and_permissions.outputs.WORKFLOW_PERMISSION == 'true' && vars.SCHEDULED_SYNC != 'false' && steps.check_branch.outputs.ABORT_SYNC == 'false' + run: | + echo ${{ steps.sync.outputs.has_new_commits }} + echo "NEW_COMMITS=${{ steps.sync.outputs.has_new_commits }}" >> $GITHUB_OUTPUT + + # Keep repository "alive": add empty commits to ALIVE_BRANCH after "time_elapsed" days of inactivity to avoid inactivation of scheduled workflows + - name: Keep alive + if: | + needs.check_alive_and_permissions.outputs.WORKFLOW_PERMISSION == 'true' && + (vars.SCHEDULED_BUILD != 'false' || vars.SCHEDULED_SYNC != 'false') + uses: gautamkrishnar/keepalive-workflow@v1 # using the workflow with default settings + with: + time_elapsed: 20 # Time elapsed from the previous commit to trigger a new automated commit (in days) + + - name: Show scheduled build configuration message + if: needs.check_alive_and_permissions.outputs.WORKFLOW_PERMISSION != 'true' + run: | + echo "### :calendar: Scheduled Sync and Build Disabled :mobile_phone_off:" >> $GITHUB_STEP_SUMMARY + echo "You have not yet configured the scheduled sync and build for Loop's browser build." >> $GITHUB_STEP_SUMMARY + echo "Synchronizing your fork of LoopWorkspace with the upstream repository LoopKit/LoopWorkspace will be skipped." >> $GITHUB_STEP_SUMMARY + echo "If you want to enable automatic builds and updates for your Loop, please follow the instructions \ + under the following path LoopWorkspace/fastlane/testflight.md." >> $GITHUB_STEP_SUMMARY + # Builds Loop build: name: Build @@ -159,16 +189,17 @@ jobs: runs-on: macos-14 permissions: contents: write - if: | # runs if started manually, or if sync schedule is set and enabled and scheduled on the first Saturday each month, or if sync schedule is set and enabled and new commits were found - github.event_name == 'workflow_dispatch' || - (needs.check_alive_and_permissions.outputs.WORKFLOW_PERMISSION == 'true' && - (vars.SCHEDULED_BUILD != 'false' && github.event.schedule == '0 6 1 * *') || - (vars.SCHEDULED_SYNC != 'false' && needs.check_latest_from_upstream.outputs.NEW_COMMITS == 'true' ) - ) + if: + | # runs if started manually, or if sync schedule is set and enabled and scheduled on the first Saturday each month, or if sync schedule is set and enabled and new commits were found + github.event_name == 'workflow_dispatch' || + (needs.check_alive_and_permissions.outputs.WORKFLOW_PERMISSION == 'true' && + (vars.SCHEDULED_BUILD != 'false' && github.event.schedule == '0 6 1 * *') || + (vars.SCHEDULED_SYNC != 'false' && needs.check_latest_from_upstream.outputs.NEW_COMMITS == 'true' ) + ) steps: - name: Select Xcode version run: "sudo xcode-select --switch /Applications/Xcode_15.4.app/Contents/Developer" - + - name: Checkout Repo for syncing if: | needs.check_alive_and_permissions.outputs.WORKFLOW_PERMISSION == 'true' && @@ -176,12 +207,12 @@ jobs: uses: actions/checkout@v4 with: token: ${{ secrets.GH_PAT }} - ref: ${{ env.TARGET_BRANCH }} - + ref: ${{ env.TARGET_BRANCH }} + - name: Sync upstream changes if: | # do not run the upstream sync action on the upstream repository needs.check_alive_and_permissions.outputs.WORKFLOW_PERMISSION == 'true' && - vars.SCHEDULED_SYNC != 'false' && github.repository_owner != 'LoopKit' + vars.SCHEDULED_SYNC != 'false' && github.repository_owner != 'LoopKit' && needs.check_latest_from_upstream.outputs.ABORT_SYNC == 'false' id: sync uses: aormsby/Fork-Sync-With-Upstream-action@v3.4.1 with: @@ -190,24 +221,24 @@ jobs: target_repo_token: ${{ secrets.GH_PAT }} upstream_sync_branch: ${{ env.UPSTREAM_BRANCH }} upstream_sync_repo: ${{ env.UPSTREAM_REPO }} - + # Display a sample message based on the sync output var 'has_new_commits' - name: New commits found if: | needs.check_alive_and_permissions.outputs.WORKFLOW_PERMISSION == 'true' && - vars.SCHEDULED_SYNC != 'false' && steps.sync.outputs.has_new_commits == 'true' + vars.SCHEDULED_SYNC != 'false' && steps.sync.outputs.has_new_commits == 'true' && needs.check_latest_from_upstream.outputs.ABORT_SYNC == 'false' run: echo "New commits were found to sync." - + - name: No new commits if: | needs.check_alive_and_permissions.outputs.WORKFLOW_PERMISSION == 'true' && - vars.SCHEDULED_SYNC != 'false' && steps.sync.outputs.has_new_commits == 'false' + vars.SCHEDULED_SYNC != 'false' && steps.sync.outputs.has_new_commits == 'false' && needs.check_latest_from_upstream.outputs.ABORT_SYNC == 'false' run: echo "There were no new commits." - + - name: Show value of 'has_new_commits' if: | needs.check_alive_and_permissions.outputs.WORKFLOW_PERMISSION == 'true' - && vars.SCHEDULED_SYNC != 'false' + && vars.SCHEDULED_SYNC != 'false' && needs.check_latest_from_upstream.outputs.ABORT_SYNC == 'false' run: | echo ${{ steps.sync.outputs.has_new_commits }} echo "NEW_COMMITS=${{ steps.sync.outputs.has_new_commits }}" >> $GITHUB_OUTPUT @@ -218,7 +249,7 @@ jobs: token: ${{ secrets.GH_PAT }} submodules: recursive ref: ${{ env.TARGET_BRANCH }} - + # Customize Loop: Download and apply patches - name: Customize Loop run: | @@ -233,24 +264,30 @@ jobs: # Template for customizing submodule Loop (changes Loop app name to "CustomLoop") # Remove the "#" sign from the beginning of the line below to activate: #curl https://github.com/loopnlearn/Loop/commit/d206432b024279ef710df462b20bd464cd9682d4.patch | git apply --directory=Loop -v --whitespace=fix - + # Submodule LoopKit patches: # General template for customizing submodule LoopKit # Copy url from a GitHub commit or pull request and insert below, and remove the "#" sign from the beginning of the line to activate: #curl url_to_github_commit.patch | git apply --directory=LoopKit -v --whitespace=fix - + # Submodule xxxxx patches: # Add patches for customization of additional submodules by following the templates above, # and make sure to specify the submodule by setting "--directory=(submodule_name)". # Several patches may be added per submodule. # Adding comments (#) may be useful to easily tell the individual patches apart. - - + # Patch Fastlane Match to not print tables - name: Patch Match Tables - run: find /usr/local/lib/ruby/gems -name table_printer.rb | xargs sed -i "" "/puts(Terminal::Table.new(params))/d" - + run: | + TABLE_PRINTER_PATH=$(ruby -e 'puts Gem::Specification.find_by_name("fastlane").gem_dir')/match/lib/match/table_printer.rb + if [ -f "$TABLE_PRINTER_PATH" ]; then + sed -i "" "/puts(Terminal::Table.new(params))/d" "$TABLE_PRINTER_PATH" + else + echo "table_printer.rb not found" + exit 1 + fi + # Install project dependencies - name: Install Project Dependencies run: bundle install @@ -258,10 +295,10 @@ jobs: # Sync the GitHub runner clock with the Windows time server (workaround as suggested in https://github.com/actions/runner/issues/2996) - name: Sync clock run: sudo sntp -sS time.windows.com - + # Build signed Loop IPA file - name: Fastlane Build & Archive - run: bundle exec fastlane build_loop + run: bundle exec fastlane build_loop env: TEAMID: ${{ secrets.TEAMID }} GH_PAT: ${{ secrets.GH_PAT }} @@ -269,7 +306,7 @@ jobs: FASTLANE_ISSUER_ID: ${{ secrets.FASTLANE_ISSUER_ID }} FASTLANE_KEY: ${{ secrets.FASTLANE_KEY }} MATCH_PASSWORD: ${{ secrets.MATCH_PASSWORD }} - + # Upload to TestFlight - name: Fastlane upload to TestFlight run: bundle exec fastlane release @@ -289,4 +326,4 @@ jobs: name: build-artifacts path: | artifacts - buildlog + buildlog \ No newline at end of file diff --git a/.github/workflows/create_certs.yml b/.github/workflows/create_certs.yml index 90bb4f75b0..9c4b517228 100644 --- a/.github/workflows/create_certs.yml +++ b/.github/workflows/create_certs.yml @@ -24,8 +24,15 @@ jobs: # Patch Fastlane Match to not print tables - name: Patch Match Tables - run: find /usr/local/lib/ruby/gems -name table_printer.rb | xargs sed -i "" "/puts(Terminal::Table.new(params))/d" - + run: | + TABLE_PRINTER_PATH=$(ruby -e 'puts Gem::Specification.find_by_name("fastlane").gem_dir')/match/lib/match/table_printer.rb + if [ -f "$TABLE_PRINTER_PATH" ]; then + sed -i "" "/puts(Terminal::Table.new(params))/d" "$TABLE_PRINTER_PATH" + else + echo "table_printer.rb not found" + exit 1 + fi + # Install project dependencies - name: Install Project Dependencies run: bundle install diff --git a/.github/workflows/validate_secrets.yml b/.github/workflows/validate_secrets.yml index 5ad976a01f..15562a7406 100644 --- a/.github/workflows/validate_secrets.yml +++ b/.github/workflows/validate_secrets.yml @@ -16,14 +16,14 @@ jobs: id: access-token run: | # Validate Access Token - + # Ensure that gh exit codes are handled when output is piped. set -o pipefail - + # Define patterns to validate the access token (GH_PAT) and distinguish between classic and fine-grained tokens. GH_PAT_CLASSIC_PATTERN='^ghp_[a-zA-Z0-9]{36}$' GH_PAT_FINE_GRAINED_PATTERN='^github_pat_[a-zA-Z0-9]{22}_[a-zA-Z0-9]{59}$' - + # Validate Access Token (GH_PAT) if [ -z "$GH_PAT" ]; then failed=true @@ -65,12 +65,12 @@ jobs: echo "has_workflow_permission=true" >> $GITHUB_OUTPUT fi fi - + # Exit unsuccessfully if secret validation failed. if [ $failed ]; then exit 2 fi - + validate-match-secrets: name: Match-Secrets needs: validate-access-token @@ -81,10 +81,10 @@ jobs: - name: Validate Match-Secrets run: | # Validate Match-Secrets - + # Ensure that gh exit codes are handled when output is piped. set -o pipefail - + # If a Match-Secrets repository does not exist, attempt to create one. if ! visibility=$(gh repo view ${{ github.repository_owner }}/Match-Secrets --json visibility | jq --raw-output '.visibility | ascii_downcase'); then echo "A '${{ github.repository_owner }}/Match-Secrets' repository could not be found using the GH_PAT secret. Attempting to create one..." @@ -103,12 +103,12 @@ jobs: else echo "Found a private '${{ github.repository_owner }}/Match-Secrets' repository to use." fi - + # Exit unsuccessfully if secret validation failed. if [ $failed ]; then exit 2 fi - + validate-fastlane-secrets: name: Fastlane needs: [validate-access-token, validate-match-secrets] @@ -124,18 +124,18 @@ jobs: steps: - name: Checkout Repo uses: actions/checkout@v4 - + - name: Install Project Dependencies run: bundle install # Sync the GitHub runner clock with the Windows time server (workaround as suggested in https://github.com/actions/runner/issues/2996) - name: Sync clock run: sudo sntp -sS time.windows.com - + - name: Validate Fastlane Secrets run: | # Validate Fastlane Secrets - + # Validate TEAMID if [ -z "$TEAMID" ]; then failed=true @@ -147,20 +147,20 @@ jobs: failed=true echo "::error::The TEAMID secret is set but invalid. Verify that it is set correctly (only uppercase letters and numbers) and try again." fi - + # Validate MATCH_PASSWORD if [ -z "$MATCH_PASSWORD" ]; then failed=true echo "::error::The MATCH_PASSWORD secret is unset or empty. Set it and try again." fi - + # Ensure that fastlane exit codes are handled when output is piped. set -o pipefail - + # Validate FASTLANE_ISSUER_ID, FASTLANE_KEY_ID, and FASTLANE_KEY FASTLANE_KEY_ID_PATTERN='^[A-Z0-9]+$' FASTLANE_ISSUER_ID_PATTERN='^\{?[A-F0-9a-f]{8}-[A-F0-9a-f]{4}-[A-F0-9a-f]{4}-[A-F0-9a-f]{4}-[A-F0-9a-f]{12}\}?$' - + if [ -z "$FASTLANE_ISSUER_ID" ] || [ -z "$FASTLANE_KEY_ID" ] || [ -z "$FASTLANE_KEY" ]; then failed=true [ -z "$FASTLANE_ISSUER_ID" ] && echo "::error::The FASTLANE_ISSUER_ID secret is unset or empty. Set it and try again." @@ -168,13 +168,13 @@ jobs: [ -z "$FASTLANE_KEY" ] && echo "::error::The FASTLANE_KEY secret is unset or empty. Set it and try again." elif [ ${#FASTLANE_KEY_ID} -ne 10 ]; then failed=true - echo "::error::The FASTLANE_KEY_ID secret is set but has wrong length. Verify that you copied it correctly from the 'Keys' tab at https://appstoreconnect.apple.com/access/api and try again." + echo "::error::The FASTLANE_KEY_ID secret is set but has wrong length. Verify that you copied it correctly from the 'Keys' tab at https://appstoreconnect.apple.com/access/integrations/api and try again." elif ! [[ $FASTLANE_KEY_ID =~ $FASTLANE_KEY_ID_PATTERN ]]; then failed=true - echo "::error::The FASTLANE_KEY_ID secret is set but invalid. Verify that you copied it correctly from the 'Keys' tab at https://appstoreconnect.apple.com/access/api and try again." + echo "::error::The FASTLANE_KEY_ID secret is set but invalid. Verify that you copied it correctly from the 'Keys' tab at https://appstoreconnect.apple.com/access/integrations/api and try again." elif ! [[ $FASTLANE_ISSUER_ID =~ $FASTLANE_ISSUER_ID_PATTERN ]]; then failed=true - echo "::error::The FASTLANE_ISSUER_ID secret is set but invalid. Verify that you copied it correctly from the 'Keys' tab at https://appstoreconnect.apple.com/access/api and try again." + echo "::error::The FASTLANE_ISSUER_ID secret is set but invalid. Verify that you copied it correctly from the 'Keys' tab at https://appstoreconnect.apple.com/access/integrations/api and try again." elif ! echo "$FASTLANE_KEY" | openssl pkcs8 -nocrypt >/dev/null; then failed=true echo "::error::The FASTLANE_KEY secret is set but invalid. Verify that you copied it correctly from the API Key file (*.p8) you downloaded and try again." @@ -190,7 +190,7 @@ jobs: echo "::error::Unable to create a valid authorization token for the App Store Connect API. Verify that the FASTLANE_ISSUER_ID, FASTLANE_KEY_ID, and FASTLANE_KEY secrets are set correctly and try again." fi fi - + # Exit unsuccessfully if secret validation failed. if [ $failed ]; then exit 2 diff --git a/fastlane/Fastfile b/fastlane/Fastfile index a8cb9278e9..f918b3aa41 100644 --- a/fastlane/Fastfile +++ b/fastlane/Fastfile @@ -156,7 +156,6 @@ platform :ios do skip_submission: false, ipa: "Loop.ipa", skip_waiting_for_build_processing: true, - changelog: git_branch+" "+last_git_commit[:abbreviated_commit_hash], ) end From 72b08874981a3a69dce58591081601fefd152c01 Mon Sep 17 00:00:00 2001 From: marionbarker Date: Sat, 25 Jan 2025 17:00:17 -0800 Subject: [PATCH 08/24] update Loop: restore TestFlight expiration date --- Loop | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Loop b/Loop index 1aaee2db49..ae76f90955 160000 --- a/Loop +++ b/Loop @@ -1 +1 @@ -Subproject commit 1aaee2db4953dbcdbe71a15cad967dbb190dc238 +Subproject commit ae76f90955843df0e1e4297f6c7c669d21e5eae2 From 0a2104b0a90adfc612e9b97b7ac618e8a9192f44 Mon Sep 17 00:00:00 2001 From: marionbarker Date: Sat, 25 Jan 2025 15:00:59 -0800 Subject: [PATCH 09/24] update LibreTransmitter: add new libre 2 plus EU sensors --- LibreTransmitter | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/LibreTransmitter b/LibreTransmitter index c01eba63e9..f6c2d0f552 160000 --- a/LibreTransmitter +++ b/LibreTransmitter @@ -1 +1 @@ -Subproject commit c01eba63e94e9f6f2841a8835680c4e39c61b18d +Subproject commit f6c2d0f552e07aa778ec639d3faca571eaa0a97b From af935829d77c2f7267cf8b937e9140308419bde1 Mon Sep 17 00:00:00 2001 From: marionbarker Date: Sat, 25 Jan 2025 15:03:30 -0800 Subject: [PATCH 10/24] update OmniXXX: pod improvements, protect against 0x31 --- OmniBLE | 2 +- OmniKit | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/OmniBLE b/OmniBLE index b82d2e1fff..1fa2874419 160000 --- a/OmniBLE +++ b/OmniBLE @@ -1 +1 @@ -Subproject commit b82d2e1fff5f0fccc42145fcbbe4731b80898fff +Subproject commit 1fa2874419225c8c7af0d9afbd9faf823cda34e5 diff --git a/OmniKit b/OmniKit index 3a75484ba0..48a35efa52 160000 --- a/OmniKit +++ b/OmniKit @@ -1 +1 @@ -Subproject commit 3a75484ba062f647e9c5ff0291948859c77ba9b2 +Subproject commit 48a35efa52f42e0b72fe2e984f60d4482a11a75f From 01d91a438d14b784ddaf43a88d3df6095ae2750d Mon Sep 17 00:00:00 2001 From: marionbarker Date: Sat, 25 Jan 2025 15:04:46 -0800 Subject: [PATCH 11/24] update LoopKit: improve visibility for options to select --- LoopKit | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/LoopKit b/LoopKit index 3ce43ded23..a03be5768e 160000 --- a/LoopKit +++ b/LoopKit @@ -1 +1 @@ -Subproject commit 3ce43ded238a776f7c8a8a9bea339db47adc0c20 +Subproject commit a03be5768e8d9cec87d93f0af9e72c97b7200b9a From 7e4fba15b257ed2737e3363b9ce5c4358ed896ec Mon Sep 17 00:00:00 2001 From: marionbarker Date: Sat, 25 Jan 2025 15:06:23 -0800 Subject: [PATCH 12/24] update to Fastlane 2.225.0 --- Gemfile.lock | 38 +++++++++++++++++++++----------------- 1 file changed, 21 insertions(+), 17 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index 8caeede216..6196cbe67e 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -10,20 +10,20 @@ GEM artifactory (3.0.17) atomos (0.1.3) aws-eventstream (1.3.0) - aws-partitions (1.981.0) - aws-sdk-core (3.209.1) + aws-partitions (1.1007.0) + aws-sdk-core (3.213.0) aws-eventstream (~> 1, >= 1.3.0) - aws-partitions (~> 1, >= 1.651.0) + aws-partitions (~> 1, >= 1.992.0) aws-sigv4 (~> 1.9) jmespath (~> 1, >= 1.6.1) - aws-sdk-kms (1.94.0) - aws-sdk-core (~> 3, >= 3.207.0) + aws-sdk-kms (1.95.0) + aws-sdk-core (~> 3, >= 3.210.0) aws-sigv4 (~> 1.5) - aws-sdk-s3 (1.166.0) - aws-sdk-core (~> 3, >= 3.207.0) + aws-sdk-s3 (1.171.0) + aws-sdk-core (~> 3, >= 3.210.0) aws-sdk-kms (~> 1) aws-sigv4 (~> 1.5) - aws-sigv4 (1.10.0) + aws-sigv4 (1.10.1) aws-eventstream (~> 1, >= 1.0.2) babosa (1.0.4) base64 (0.2.0) @@ -69,7 +69,7 @@ GEM faraday_middleware (1.2.1) faraday (~> 1.0) fastimage (2.3.1) - fastlane (2.223.1) + fastlane (2.225.0) CFPropertyList (>= 2.3, < 4.0.0) addressable (>= 2.8, < 3.0.0) artifactory (~> 3.0) @@ -85,6 +85,7 @@ GEM faraday-cookie_jar (~> 0.0.6) faraday_middleware (~> 1.0) fastimage (>= 2.1.0, < 3.0.0) + fastlane-sirp (>= 1.0.0) gh_inspector (>= 1.1.2, < 2.0.0) google-apis-androidpublisher_v3 (~> 0.3) google-apis-playcustomapp_v1 (~> 0.1) @@ -110,6 +111,8 @@ GEM xcodeproj (>= 1.13.0, < 2.0.0) xcpretty (~> 0.3.0) xcpretty-travis-formatter (>= 0.0.3, < 2.0.0) + fastlane-sirp (1.0.0) + sysrandom (~> 1.0) gh_inspector (1.1.3) google-apis-androidpublisher_v3 (0.54.0) google-apis-core (>= 0.11.0, < 2.a) @@ -152,17 +155,17 @@ GEM domain_name (~> 0.5) httpclient (2.8.3) jmespath (1.6.2) - json (2.7.2) - jwt (2.9.1) + json (2.7.6) + jwt (2.9.3) base64 mini_magick (4.13.2) mini_mime (1.1.5) multi_json (1.15.0) multipart-post (2.4.1) - nanaimo (0.3.0) + nanaimo (0.4.0) naturally (2.2.1) nkf (0.2.0) - optparse (0.5.0) + optparse (0.6.0) os (1.1.4) plist (3.7.1) public_suffix (5.1.1) @@ -172,7 +175,7 @@ GEM trailblazer-option (>= 0.1.1, < 0.2.0) uber (< 0.2.0) retriable (3.1.2) - rexml (3.3.7) + rexml (3.3.9) rouge (2.0.7) ruby2_keywords (0.0.5) rubyzip (2.3.2) @@ -185,6 +188,7 @@ GEM simctl (1.6.10) CFPropertyList naturally + sysrandom (1.0.5) terminal-notifier (2.0.0) terminal-table (3.0.2) unicode-display_width (>= 1.1.1, < 3) @@ -197,13 +201,13 @@ GEM unf (0.2.0) unicode-display_width (2.6.0) word_wrap (1.0.0) - xcodeproj (1.25.0) + xcodeproj (1.27.0) CFPropertyList (>= 2.3.3, < 4.0) atomos (~> 0.1.3) claide (>= 1.0.2, < 2.0) colored2 (~> 3.1) - nanaimo (~> 0.3.0) - rexml (>= 3.3.2, < 4.0) + nanaimo (~> 0.4.0) + rexml (>= 3.3.6, < 4.0) xcpretty (0.3.0) rouge (~> 2.0.7) xcpretty-travis-formatter (1.0.1) From 967d5eccdceee660dec7c7120727b9a4a261b7f4 Mon Sep 17 00:00:00 2001 From: marionbarker Date: Sat, 25 Jan 2025 16:45:05 -0800 Subject: [PATCH 13/24] update using Trio (PR 453) to automate new certificates, credit @bjornoleh --- .github/workflows/build_loop.yml | 14 ++-- .github/workflows/create_certs.yml | 105 ++++++++++++++++++++----- .github/workflows/validate_secrets.yml | 9 +-- fastlane/Fastfile | 57 +++++++++++++- fastlane/testflight.md | 49 ++++++++---- 5 files changed, 186 insertions(+), 48 deletions(-) diff --git a/.github/workflows/build_loop.yml b/.github/workflows/build_loop.yml index 254c4015fb..137b367fc6 100644 --- a/.github/workflows/build_loop.yml +++ b/.github/workflows/build_loop.yml @@ -18,15 +18,17 @@ env: ALIVE_BRANCH_DEV: alive-dev jobs: - validate: - name: Validate - uses: ./.github/workflows/validate_secrets.yml + # Checks if Distribution certificate is present and valid, optionally nukes and + # creates new certs if the repository variable ENABLE_NUKE_CERTS == 'true' + check_certs: + name: Check certificates + uses: ./.github/workflows/create_certs.yml secrets: inherit # Checks if GH_PAT holds workflow permissions # Checks for existence of alive branch; if non-existent creates it check_alive_and_permissions: - needs: validate + needs: check_certs runs-on: ubuntu-latest name: Check alive branch and permissions permissions: @@ -96,7 +98,7 @@ jobs: # Checks for changes in upstream repository; if changes exist prompts sync for build # Performs keepalive to avoid stale fork check_latest_from_upstream: - needs: [validate, check_alive_and_permissions] + needs: [check_certs, check_alive_and_permissions] runs-on: ubuntu-latest name: Check upstream and keep alive outputs: @@ -185,7 +187,7 @@ jobs: # Builds Loop build: name: Build - needs: [validate, check_alive_and_permissions, check_latest_from_upstream] + needs: [check_certs, check_alive_and_permissions, check_latest_from_upstream] runs-on: macos-14 permissions: contents: write diff --git a/.github/workflows/create_certs.yml b/.github/workflows/create_certs.yml index 9c4b517228..025c0cb277 100644 --- a/.github/workflows/create_certs.yml +++ b/.github/workflows/create_certs.yml @@ -1,23 +1,32 @@ name: 3. Create Certificates run-name: Create Certificates (${{ github.ref_name }}) -on: - workflow_dispatch: + +on: [workflow_call, workflow_dispatch] + +env: + TEAMID: ${{ secrets.TEAMID }} + GH_PAT: ${{ secrets.GH_PAT }} + GH_TOKEN: ${{ secrets.GH_PAT }} + MATCH_PASSWORD: ${{ secrets.MATCH_PASSWORD }} + FASTLANE_KEY_ID: ${{ secrets.FASTLANE_KEY_ID }} + FASTLANE_ISSUER_ID: ${{ secrets.FASTLANE_ISSUER_ID }} + FASTLANE_KEY: ${{ secrets.FASTLANE_KEY }} jobs: validate: name: Validate uses: ./.github/workflows/validate_secrets.yml secrets: inherit - - certificates: - name: Create Certificates + + + create_certs: + name: Certificates needs: validate - runs-on: macos-14 + runs-on: macos-15 + outputs: + new_certificate_needed: ${{ steps.set_output.outputs.new_certificate_needed }} + steps: - # Uncomment to manually select latest Xcode if needed - #- name: Select Latest Xcode - # run: "sudo xcode-select --switch /Applications/Xcode_13.0.app/Contents/Developer" - # Checks-out the repo - name: Checkout Repo uses: actions/checkout@v4 @@ -41,13 +50,69 @@ jobs: - name: Sync clock run: sudo sntp -sS time.windows.com - # Create or update certificates for app - - name: Create Certificates - run: bundle exec fastlane certs - env: - TEAMID: ${{ secrets.TEAMID }} - GH_PAT: ${{ secrets.GH_PAT }} - MATCH_PASSWORD: ${{ secrets.MATCH_PASSWORD }} - FASTLANE_KEY_ID: ${{ secrets.FASTLANE_KEY_ID }} - FASTLANE_ISSUER_ID: ${{ secrets.FASTLANE_ISSUER_ID }} - FASTLANE_KEY: ${{ secrets.FASTLANE_KEY }} + # Create or update Distribution certificate and provisioning profiles + - name: Check and create or update Distribution certificate and profiles if needed + run: | + echo "Running Fastlane certs lane..." + bundle exec fastlane certs || true # ignore and continue on errors without annotating an exit code + - name: Check Distribution certificate and launch Nuke certificates if needed + run: bundle exec fastlane check_and_renew_certificates + id: check_certs + + - name: Set output and annotations based on Fastlane result + id: set_output + run: | + CERT_STATUS_FILE="${{ github.workspace }}/fastlane/new_certificate_needed.txt" + ENABLE_NUKE_CERTS=${{ vars.ENABLE_NUKE_CERTS }} + + if [ -f "$CERT_STATUS_FILE" ]; then + CERT_STATUS=$(cat "$CERT_STATUS_FILE" | tr -d '\n' | tr -d '\r') # Read file content and strip newlines + echo "new_certificate_needed: $CERT_STATUS" + echo "new_certificate_needed=$CERT_STATUS" >> $GITHUB_OUTPUT + else + echo "Certificate status file not found. Defaulting to false." + echo "new_certificate_needed=false" >> $GITHUB_OUTPUT + fi + # Check if ENABLE_NUKE_CERTS is not set to true when certs are valid + if [ "$CERT_STATUS" != "true" ] && [ "$ENABLE_NUKE_CERTS" != "true" ]; then + echo "::notice::🔔 Automated renewal of certificates is disabled because the repository variable ENABLE_NUKE_CERTS is not set to 'true'." + fi + # Check if ENABLE_NUKE_CERTS is not set to true when certs are not valid + if [ "$CERT_STATUS" = "true" ] && [ "$ENABLE_NUKE_CERTS" != "true" ]; then + echo "::error::❌ No valid distribution certificate found. Automated renewal of certificates was skipped because the repository variable ENABLE_NUKE_CERTS is not set to 'true'." + exit 1 + fi + # Check if vars.FORCE_NUKE_CERTS is not set to true + if [ vars.FORCE_NUKE_CERTS = "true" ]; then + echo "::warning::‼️ Nuking of certificates was forced because the repository variable FORCE_NUKE_CERTS is set to 'true'." + fi + # Nuke Certs if needed, and if the repository variable ENABLE_NUKE_CERTS is set to 'true', or if FORCE_NUKE_CERTS is set to 'true', which will always force certs to be nuked + nuke_certs: + name: Nuke certificates + needs: [validate, create_certs] + runs-on: macos-14 + if: ${{ (needs.create_certs.outputs.new_certificate_needed == 'true' && vars.ENABLE_NUKE_CERTS == 'true') || vars.FORCE_NUKE_CERTS == 'true' }} + steps: + - name: Output from step id 'check_certs' + run: echo "new_certificate_needed=${{ needs.create_certs.outputs.new_certificate_needed }}" + + - name: Checkout repository + uses: actions/checkout@v4 + + - name: Install dependencies + run: bundle install + + - name: Run Fastlane nuke_certs + run: | + set -e # Set error immediately after this step if error occurs + bundle exec fastlane nuke_certs + - name: Recreate Distribution certificate after nuking + run: | + set -e # Set error immediately after this step if error occurs + bundle exec fastlane certs + - name: Add success annotations for nuke and certificate recreation + if: ${{ success() }} + run: | + echo "::warning::⚠️ All Distribution certificates and TestFlight profiles have been revoked and recreated." + echo "::warning::❗️ If you have other apps being distributed by GitHub Actions / Fastlane / TestFlight that does not renew certificates automatically, please run the '3. Create Certificates' workflow for each of these apps to allow these apps to be built." + echo "::warning::✅ But don't worry about your existing TestFlight builds, they will keep working!" diff --git a/.github/workflows/validate_secrets.yml b/.github/workflows/validate_secrets.yml index 15562a7406..dbbec0f5e5 100644 --- a/.github/workflows/validate_secrets.yml +++ b/.github/workflows/validate_secrets.yml @@ -178,16 +178,15 @@ jobs: elif ! echo "$FASTLANE_KEY" | openssl pkcs8 -nocrypt >/dev/null; then failed=true echo "::error::The FASTLANE_KEY secret is set but invalid. Verify that you copied it correctly from the API Key file (*.p8) you downloaded and try again." - elif ! bundle exec fastlane validate_secrets 2>&1 | tee fastlane.log; then + elif ! (bundle exec fastlane validate_secrets 2>&1 || true) | tee fastlane.log; then # ignore "fastlane validate_secrets" errors and continue on errors without annotating an exit code if grep -q "bad decrypt" fastlane.log; then failed=true echo "::error::Unable to decrypt the Match-Secrets repository using the MATCH_PASSWORD secret. Verify that it is set correctly and try again." elif grep -q -e "required agreement" -e "license agreement" fastlane.log; then failed=true - echo "::error::Unable to create a valid authorization token for the App Store Connect API. Verify that the latest developer program license agreement has been accepted at https://developer.apple.com/account (review and accept any updated agreement), then wait a few minutes for changes to propagate and try again." - elif ! grep -q -e "No code signing identity found" -e "Could not install WWDR certificate" fastlane.log; then - failed=true - echo "::error::Unable to create a valid authorization token for the App Store Connect API. Verify that the FASTLANE_ISSUER_ID, FASTLANE_KEY_ID, and FASTLANE_KEY secrets are set correctly and try again." + echo "::error::❗️ Verify that the latest developer program license agreement has been accepted at https://developer.apple.com/account (review and accept any updated agreement), then wait a few minutes for changes to take effect and try again." + elif grep -q "Your certificate .* is not valid" fastlane.log; then + echo "::notice::Your Distribution certificate is invalid or expired. Automated renewal of the certificate will be attempted." fi fi diff --git a/fastlane/Fastfile b/fastlane/Fastfile index f918b3aa41..e71a3ee16c 100644 --- a/fastlane/Fastfile +++ b/fastlane/Fastfile @@ -220,7 +220,8 @@ platform :ios do match( type: "appstore", - force: true, + force: false, + verbose: true, git_basic_authorization: Base64.strict_encode64("#{GITHUB_REPOSITORY_OWNER}:#{GH_PAT}"), app_identifier: [ "com.#{TEAMID}.loopkit.Loop", @@ -276,4 +277,56 @@ platform :ios do git_basic_authorization: Base64.strict_encode64("#{GITHUB_REPOSITORY_OWNER}:#{GH_PAT}") ) end -end + + desc "Check Certificates and Trigger Workflow for Expired or Missing Certificates" + lane :check_and_renew_certificates do + setup_ci if ENV['CI'] + ENV["MATCH_READONLY"] = false.to_s + + # Authenticate using App Store Connect API Key + api_key = app_store_connect_api_key( + key_id: ENV["FASTLANE_KEY_ID"], + issuer_id: ENV["FASTLANE_ISSUER_ID"], + key_content: ENV["FASTLANE_KEY"] # Ensure valid key content + ) + + # Initialize flag to track if renewal of certificates is needed + new_certificate_needed = false + + # Fetch all certificates + certificates = Spaceship::ConnectAPI::Certificate.all + + # Filter for Distribution Certificates + distribution_certs = certificates.select { |cert| cert.certificate_type == "DISTRIBUTION" } + + # Handle case where no distribution certificates are found + if distribution_certs.empty? + puts "No Distribution certificates found! Triggering action to create certificate." + new_certificate_needed = true + else + # Check for expiration + distribution_certs.each do |cert| + expiration_date = Time.parse(cert.expiration_date) + + puts "Current Distribution Certificate: #{cert.id}, Expiration date: #{expiration_date}" + + if expiration_date < Time.now + puts "Distribution Certificate #{cert.id} is expired! Triggering action to renew certificate." + new_certificate_needed = true + else + puts "Distribution certificate #{cert.id} is valid. No action required." + end + end + end + + # Write result to new_certificate_needed.txt + file_path = File.expand_path('new_certificate_needed.txt') + File.write(file_path, new_certificate_needed ? 'true' : 'false') + + # Log the absolute path and contents of the new_certificate_needed.txt file + puts "" + puts "Absolute path of new_certificate_needed.txt: #{file_path}" + new_certificate_needed_content = File.read(file_path) + puts "Certificate creation or renewal needed: #{new_certificate_needed_content}" + end +end \ No newline at end of file diff --git a/fastlane/testflight.md b/fastlane/testflight.md index abe99314eb..c344e91dc5 100644 --- a/fastlane/testflight.md +++ b/fastlane/testflight.md @@ -2,14 +2,14 @@ These instructions allow you to build Loop without having access to a Mac. -* You can install Loop on phones via TestFlight that are not connected to your computer +* You can install Loop on phones using TestFlight that are not connected to your computer * You can send builds and updates to those you care for * You can install Loop on your phone using only the TestFlight app if a phone was lost or the app is accidentally deleted * You do not need to worry about specific Xcode/Mac versions for a given iOS ## **Automatic Builds** > -> This new version of the browser build **defaults to** automatically updating and building a new version of Loop according to this schedule: +> The browser build **defaults to** automatically updating and building a new version of Loop 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 Loop log appears - if the time is very short, it did not need to build - only the long actions (>20 minutes) built a new Loop app @@ -33,6 +33,8 @@ There are more detailed instructions in LoopDocs for using GitHub for Browser Bu Note that installing with TestFlight, (in the US), requires the Apple ID account holder to be 13 years or older. For younger Loopers, an adult must log into Media & Purchase on the child's phone to install Loop. More details on this can be found in [LoopDocs](https://loopkit.github.io/loopdocs/gh-actions/gh-deploy/#install-testflight-loop-for-child). +If you build multiple apps, it is strongly recommended that you configure a free *GitHub* organization and do all your building in the organization. This means you enter items one time for the organization (6 SECRETS required to build and 1 VARIABLE required to automatically update your certificates annually). Otherwise, those 6 SECRETS must be entered for every repository. Please refer to [LoopDocs: Use a *GitHub* Organization Account](https://loopkit.github.io/loopdocs/gh-actions/gh-other-apps/#use-a-github-organization-account). + ## Prerequisites * A [GitHub account](https://github.com/signup). The free level comes with plenty of storage and free compute time to build loop, multiple times a day, if you wanted to. @@ -48,6 +50,8 @@ You require 6 Secrets (alphanumeric items) to use the GitHub build method and if * Be sure to save the 6 Secrets in a text file using a text editor - Do **NOT** use a smart editor, which might auto-correct and change case, because these Secrets are case sensitive +Refer to [LoopDocs: Make a Secrets Reference File](https://loopkit.github.io/loopdocs/gh-actions/gh-first-time/#make-a-secrets-reference-file) for a handy template to use when saving your Secrets. + ## Generate App Store Connect API Key This step is common for all GitHub Browser Builds; do this step only once. You will be saving 4 Secrets from your Apple Account in this step. @@ -61,6 +65,8 @@ This step is common for all GitHub Browser Builds; do this step only once. You w ## Create GitHub Personal Access Token +If you have previously built another app using the "browser build" method, you use the same personal access token (`GH_PAT`), so skip this step. If you use a free GitHub organization to build, you still use the same personal access token. This is created using your personal GitHub username. + Log into your GitHub account to create a personal access token; this is one of two GitHub secrets needed for your build. 1. Create a [new personal access token](https://github.com/settings/tokens/new): @@ -76,25 +82,26 @@ This is the second one of two GitHub secrets needed for your build. The first time you build with the GitHub Browser Build method for any DIY app, you will make up a password and record it as `MATCH_PASSWORD`. Note, if you later lose `MATCH_PASSWORD`, you will need to delete and make a new Match-Secrets repository (next step). -## Setup GitHub Match-Secrets Repository - -The creation of the Match-Secrets repository is a common step for all GitHub Browser Builds; do this step only once. You must be logged into your GitHub account. +## GitHub Match-Secrets Repository -1. Create a [new empty repository](https://github.com/new) titled `Match-Secrets`. It should be private. - -Once created, you will not take any direct actions with this repository; it needs to be there for the GitHub to use as you progress through the steps. +A private Match-Secrets repository is automatically created under your GitHub username the first time you run a GitHub Action. Because it is a private repository - only you can see it. You will not take any direct actions with this repository; it needs to be there for GitHub to use as you progress through the steps. ## Setup GitHub LoopWorkspace Repository -1. Fork https://github.com/LoopKit/LoopWorkspace into your account. -1. In the forked LoopWorkspace repo, go to Settings -> Secrets and variables -> Actions. -1. For each of the following secrets, tap on "New repository secret", then add the name of the secret, along with the value you recorded for it: +1. Fork https://github.com/LoopKit/LoopWorkspace into your GitHub username (using your organization if you have one). If you already have a fork of Trio in that username, you should not make another one. Do not rename the repository. You can continue to work with your existing fork, or delete that from GitHub and then fork again. +1. If you are using an organization, do this step at the organization level, e.g., username-org. If you are not using an organization, do this step at the repository level, e.g., username/LoopWorkspace: + * Go to Settings -> Secrets and variables -> Actions and make sure the Secrets tab is open +1. For each of the following secrets, tap on "New organization secret" or "New repository secret", then add the name of the secret, along with the value you recorded for it: * `TEAMID` * `FASTLANE_ISSUER_ID` * `FASTLANE_KEY_ID` * `FASTLANE_KEY` * `GH_PAT` * `MATCH_PASSWORD` +1. If you are using an organization, do this step at the organization level, e.g., username-org. If you are not using an organization, do this step at the repository level, e.g., username/LoopWorkspace: + * Go to Settings -> Secrets and variables -> Actions and make sure the Variables tab is open +1. Tap on "Create new organization variable" or "Create new repository variable", then add the name below and enter the value true. Unlike secrets variables are visible and can be edited. + * `ENABLE_NUKE_CERTS` ## Validate repository secrets @@ -106,6 +113,8 @@ This step validates most of your six Secrets and provides error messages if it d 1. Wait, and within a minute or two you should see a green checkmark indicating the workflow succeeded. 1. The workflow will check if the required secrets are added and that they are correctly formatted. If errors are detected, please check the run log for details. +There can be a delay after you start a workflow before the screen changes. Refresh your browser to see if it started. And if it seems to take a long time to finish - refresh your browser to see if it is done. + ## Add Identifiers for Loop App 1. Click on the "Actions" tab of your LoopWorkspace repository. @@ -171,10 +180,9 @@ You do not need to fill out the next form. That is for submitting to the app sto ## Create Building Certificates -1. Go back to the "Actions" tab of your LoopWorkspace repository in GitHub. -1. On the left side, select "3. Create Certificates". -1. On the right side, click "Run Workflow", and tap the green `Run workflow` button. -1. Wait, and within a minute or two you should see a green checkmark indicating the workflow succeeded. +This step is no longer required. The Build Loop function now takes care of this for you. It does not hurt to run it but is not needed. + +Once a year, you will get an email from Apple indicating your certificate will expire in 30 days. You can ignore that email. When it does expire, the next time an automatic or manual build happens, the expired certificate information will be removed (nuked) from your Match-Secrets repository and a new one created. This should happen without you needing to take any action. ## Build Loop @@ -267,3 +275,14 @@ Your build will run on the following conditions: - If you disable any automation (both variables set to `false`), no updates, keep-alive or building happens when Build Loop 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 + +## What if I build using more than one GitHub username + +This is not typical. But if you do use more than one GitHub username, follow these steps at the time of the annual certificate renewal. + +1. After the certificates were removed (nuked) from username1 Match-Secrets storage, you need to switch to username2 +1. Add the variable FORCE_NUKE_CERTS=true to the username2/Trio repository +1. Run the action Create Certificate (or Build, but Create is faster) +1. Immediately set FORCE_NUKE_CERTS=false or delete the variable + +Now certificates for username2 have been cleared out of Match-Secrets storage for username2. Building can proceed as usual for both username1 and username2. From 77dc12ea9d73b03995aad572ffc42747ae1c74e3 Mon Sep 17 00:00:00 2001 From: marionbarker Date: Tue, 11 Feb 2025 19:57:33 -0800 Subject: [PATCH 14/24] modify time of day for automatic run, deconflict possible nuke cert from other OS apps --- .github/workflows/build_loop.yml | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build_loop.yml b/.github/workflows/build_loop.yml index 137b367fc6..c64d752b5f 100644 --- a/.github/workflows/build_loop.yml +++ b/.github/workflows/build_loop.yml @@ -6,9 +6,12 @@ on: ## Remove the "#" sign from the beginning of the line below to get automated builds on push (code changes in your repository) #push: + # Automated builds now include automatic certificate update - the nuke certs part of that process could + # affect other OS apps if run simultaneously. + # Each OS needs a time of day distinct from other apps, LoopWorkspace uses 9 every Wed and 7 every 1st of month schedule: - - cron: "0 8 * * 3" # Checks for updates at 08:00 UTC every Wednesday - - cron: "0 6 1 * *" # Builds the app on the 1st of every month at 06:00 UTC + - cron: "0 9 * * 3" # Checks for updates at 09:00 UTC every Wednesday + - cron: "0 7 1 * *" # Builds the app on the 1st of every month at 07:00 UTC env: UPSTREAM_REPO: LoopKit/LoopWorkspace @@ -195,7 +198,7 @@ jobs: | # runs if started manually, or if sync schedule is set and enabled and scheduled on the first Saturday each month, or if sync schedule is set and enabled and new commits were found github.event_name == 'workflow_dispatch' || (needs.check_alive_and_permissions.outputs.WORKFLOW_PERMISSION == 'true' && - (vars.SCHEDULED_BUILD != 'false' && github.event.schedule == '0 6 1 * *') || + (vars.SCHEDULED_BUILD != 'false' && github.event.schedule == '0 7 1 * *') || (vars.SCHEDULED_SYNC != 'false' && needs.check_latest_from_upstream.outputs.NEW_COMMITS == 'true' ) ) steps: From 9f14aaceaa5c0c45dcc54ed508ec28bc98323566 Mon Sep 17 00:00:00 2001 From: marionbarker Date: Wed, 12 Feb 2025 14:23:17 -0800 Subject: [PATCH 15/24] update OmniXXX: fix podSuspend logic error, incorporate tryToValidateComms --- OmniBLE | 2 +- OmniKit | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/OmniBLE b/OmniBLE index 1fa2874419..6f65cbae4c 160000 --- a/OmniBLE +++ b/OmniBLE @@ -1 +1 @@ -Subproject commit 1fa2874419225c8c7af0d9afbd9faf823cda34e5 +Subproject commit 6f65cbae4c8089a892911e273204edfc4cc81e9d diff --git a/OmniKit b/OmniKit index 48a35efa52..39915b05fe 160000 --- a/OmniKit +++ b/OmniKit @@ -1 +1 @@ -Subproject commit 48a35efa52f42e0b72fe2e984f60d4482a11a75f +Subproject commit 39915b05fe46b5d73eca52e156dd7efd11193ee8 From c13c5ce258a2fe2516247f47c813c9e80dbaabec Mon Sep 17 00:00:00 2001 From: marionbarker Date: Mon, 3 Mar 2025 13:49:21 -0800 Subject: [PATCH 16/24] update actions to use macos 15 and Xcode_16.2 --- .github/workflows/add_identifiers.yml | 2 +- .github/workflows/build_loop.yml | 4 ++-- .github/workflows/create_certs.yml | 2 +- .github/workflows/validate_secrets.yml | 6 +++--- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/.github/workflows/add_identifiers.yml b/.github/workflows/add_identifiers.yml index 8ff87a55f5..4628862995 100644 --- a/.github/workflows/add_identifiers.yml +++ b/.github/workflows/add_identifiers.yml @@ -12,7 +12,7 @@ jobs: identifiers: name: Add Identifiers needs: validate - runs-on: macos-14 + runs-on: macos-15 steps: # Uncomment to manually select latest Xcode if needed #- name: Select Latest Xcode diff --git a/.github/workflows/build_loop.yml b/.github/workflows/build_loop.yml index c64d752b5f..8648335a94 100644 --- a/.github/workflows/build_loop.yml +++ b/.github/workflows/build_loop.yml @@ -191,7 +191,7 @@ jobs: build: name: Build needs: [check_certs, check_alive_and_permissions, check_latest_from_upstream] - runs-on: macos-14 + runs-on: macos-15 permissions: contents: write if: @@ -203,7 +203,7 @@ jobs: ) steps: - name: Select Xcode version - run: "sudo xcode-select --switch /Applications/Xcode_15.4.app/Contents/Developer" + run: "sudo xcode-select --switch /Applications/Xcode_16.2.app/Contents/Developer" - name: Checkout Repo for syncing if: | diff --git a/.github/workflows/create_certs.yml b/.github/workflows/create_certs.yml index 025c0cb277..d20001b2ca 100644 --- a/.github/workflows/create_certs.yml +++ b/.github/workflows/create_certs.yml @@ -90,7 +90,7 @@ jobs: nuke_certs: name: Nuke certificates needs: [validate, create_certs] - runs-on: macos-14 + runs-on: macos-15 if: ${{ (needs.create_certs.outputs.new_certificate_needed == 'true' && vars.ENABLE_NUKE_CERTS == 'true') || vars.FORCE_NUKE_CERTS == 'true' }} steps: - name: Output from step id 'check_certs' diff --git a/.github/workflows/validate_secrets.yml b/.github/workflows/validate_secrets.yml index dbbec0f5e5..7f747773ea 100644 --- a/.github/workflows/validate_secrets.yml +++ b/.github/workflows/validate_secrets.yml @@ -5,7 +5,7 @@ on: [workflow_call, workflow_dispatch] jobs: validate-access-token: name: Access - runs-on: macos-14 + runs-on: macos-15 env: GH_PAT: ${{ secrets.GH_PAT }} GH_TOKEN: ${{ secrets.GH_PAT }} @@ -74,7 +74,7 @@ jobs: validate-match-secrets: name: Match-Secrets needs: validate-access-token - runs-on: macos-14 + runs-on: macos-15 env: GH_TOKEN: ${{ secrets.GH_PAT }} steps: @@ -112,7 +112,7 @@ jobs: validate-fastlane-secrets: name: Fastlane needs: [validate-access-token, validate-match-secrets] - runs-on: macos-14 + runs-on: macos-15 env: GH_PAT: ${{ secrets.GH_PAT }} GH_TOKEN: ${{ secrets.GH_PAT }} From e7e54e58e72429575eb9a5c7ffae82eef4dc185a Mon Sep 17 00:00:00 2001 From: marionbarker Date: Fri, 21 Mar 2025 08:08:30 -0700 Subject: [PATCH 17/24] update Loop: Adjust provisioning profile path in script for Xcode 16 compatibility --- Loop | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Loop b/Loop index ae76f90955..f63edf9b70 160000 --- a/Loop +++ b/Loop @@ -1 +1 @@ -Subproject commit ae76f90955843df0e1e4297f6c7c669d21e5eae2 +Subproject commit f63edf9b70177c141d5d67fbaff568b4baa6d3a6 From 67e91f7ef29408f3776f97cc29e68676b62e1fc7 Mon Sep 17 00:00:00 2001 From: Marion Barker <19607791+marionbarker@users.noreply.github.com> Date: Mon, 7 Apr 2025 15:08:04 -0700 Subject: [PATCH 18/24] Configure the version number in LoopWorkspace, not Loop (#241) * Configure the version number in LoopWorkspace, not Loop * Add VersionOverride for DIY numbering * update Loop: version number change and UI bug fixes * stale values could be displayed for bolus progress total dose * stale values could be displayed for Algorithm Experiment selections --- Loop | 2 +- LoopWorkspace.xcworkspace/contents.xcworkspacedata | 3 +++ VersionOverride.xcconfig | 12 ++++++++++++ 3 files changed, 16 insertions(+), 1 deletion(-) create mode 100644 VersionOverride.xcconfig diff --git a/Loop b/Loop index f63edf9b70..0a3a165189 160000 --- a/Loop +++ b/Loop @@ -1 +1 @@ -Subproject commit f63edf9b70177c141d5d67fbaff568b4baa6d3a6 +Subproject commit 0a3a1651894f06ddce7a2feff9b6d299a34e6d2d diff --git a/LoopWorkspace.xcworkspace/contents.xcworkspacedata b/LoopWorkspace.xcworkspace/contents.xcworkspacedata index b1d1574f06..9097fa2796 100644 --- a/LoopWorkspace.xcworkspace/contents.xcworkspacedata +++ b/LoopWorkspace.xcworkspace/contents.xcworkspacedata @@ -20,6 +20,9 @@ + + diff --git a/VersionOverride.xcconfig b/VersionOverride.xcconfig new file mode 100644 index 0000000000..f2af2cbe2b --- /dev/null +++ b/VersionOverride.xcconfig @@ -0,0 +1,12 @@ +// +// VersionOverride.xcconfig +// LoopWorkspace +// +// Created 3/31/2025 +// Copyright © 2020 LoopKit Authors. All rights reserved. +// + +// Version [for DIY Loop] +// configure the version number in LoopWorkspace +LOOP_MARKETING_VERSION = 3.5.0 +CURRENT_PROJECT_VERSION = 57 From a26084a84b53e585151aa2fd2c6d164c7624bddf Mon Sep 17 00:00:00 2001 From: Marion Barker <19607791+marionbarker@users.noreply.github.com> Date: Sun, 13 Apr 2025 13:38:46 -0700 Subject: [PATCH 19/24] Fix typo in testflight.md build instructions (#240) --- fastlane/testflight.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/fastlane/testflight.md b/fastlane/testflight.md index c344e91dc5..7c521a7379 100644 --- a/fastlane/testflight.md +++ b/fastlane/testflight.md @@ -88,7 +88,7 @@ A private Match-Secrets repository is automatically created under your GitHub us ## Setup GitHub LoopWorkspace Repository -1. Fork https://github.com/LoopKit/LoopWorkspace into your GitHub username (using your organization if you have one). If you already have a fork of Trio in that username, you should not make another one. Do not rename the repository. You can continue to work with your existing fork, or delete that from GitHub and then fork again. +1. Fork https://github.com/LoopKit/LoopWorkspace into your GitHub username (using your organization if you have one). If you already have a fork of LoopWorkspace in that username, you should not make another one. Do not rename the repository. You can continue to work with your existing fork, or delete that from GitHub and then fork again. 1. If you are using an organization, do this step at the organization level, e.g., username-org. If you are not using an organization, do this step at the repository level, e.g., username/LoopWorkspace: * Go to Settings -> Secrets and variables -> Actions and make sure the Secrets tab is open 1. For each of the following secrets, tap on "New organization secret" or "New repository secret", then add the name of the secret, along with the value you recorded for it: @@ -281,7 +281,7 @@ Your build will run on the following conditions: This is not typical. But if you do use more than one GitHub username, follow these steps at the time of the annual certificate renewal. 1. After the certificates were removed (nuked) from username1 Match-Secrets storage, you need to switch to username2 -1. Add the variable FORCE_NUKE_CERTS=true to the username2/Trio repository +1. Add the variable FORCE_NUKE_CERTS=true to the username2/LoopWorkspace repository 1. Run the action Create Certificate (or Build, but Create is faster) 1. Immediately set FORCE_NUKE_CERTS=false or delete the variable From 30e24d0dfdf9761be4a105a10857a822d61a3547 Mon Sep 17 00:00:00 2001 From: Marion Barker <19607791+marionbarker@users.noreply.github.com> Date: Mon, 14 Apr 2025 12:15:51 -0700 Subject: [PATCH 20/24] Update to fastlane 2.227.1 and Xcode 16.3 (#243) --- .github/workflows/add_identifiers.yml | 4 -- .github/workflows/build_loop.yml | 2 +- Gemfile.lock | 76 ++++++++++++++------------- 3 files changed, 41 insertions(+), 41 deletions(-) diff --git a/.github/workflows/add_identifiers.yml b/.github/workflows/add_identifiers.yml index 4628862995..6661ba30c9 100644 --- a/.github/workflows/add_identifiers.yml +++ b/.github/workflows/add_identifiers.yml @@ -14,10 +14,6 @@ jobs: needs: validate runs-on: macos-15 steps: - # Uncomment to manually select latest Xcode if needed - #- name: Select Latest Xcode - # run: "sudo xcode-select --switch /Applications/Xcode_13.0.app/Contents/Developer" - # Checks-out the repo - name: Checkout Repo uses: actions/checkout@v4 diff --git a/.github/workflows/build_loop.yml b/.github/workflows/build_loop.yml index 8648335a94..8cc3a36c6a 100644 --- a/.github/workflows/build_loop.yml +++ b/.github/workflows/build_loop.yml @@ -203,7 +203,7 @@ jobs: ) steps: - name: Select Xcode version - run: "sudo xcode-select --switch /Applications/Xcode_16.2.app/Contents/Developer" + run: "sudo xcode-select --switch /Applications/Xcode_16.3.app/Contents/Developer" - name: Checkout Repo for syncing if: | diff --git a/Gemfile.lock b/Gemfile.lock index 6196cbe67e..a6ab3602f3 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -9,21 +9,23 @@ GEM public_suffix (>= 2.0.2, < 7.0) artifactory (3.0.17) atomos (0.1.3) - aws-eventstream (1.3.0) - aws-partitions (1.1007.0) - aws-sdk-core (3.213.0) + aws-eventstream (1.3.2) + aws-partitions (1.1086.0) + aws-sdk-core (3.222.1) aws-eventstream (~> 1, >= 1.3.0) aws-partitions (~> 1, >= 1.992.0) aws-sigv4 (~> 1.9) + base64 jmespath (~> 1, >= 1.6.1) - aws-sdk-kms (1.95.0) - aws-sdk-core (~> 3, >= 3.210.0) + logger + aws-sdk-kms (1.99.0) + aws-sdk-core (~> 3, >= 3.216.0) aws-sigv4 (~> 1.5) - aws-sdk-s3 (1.171.0) - aws-sdk-core (~> 3, >= 3.210.0) + aws-sdk-s3 (1.183.0) + aws-sdk-core (~> 3, >= 3.216.0) aws-sdk-kms (~> 1) aws-sigv4 (~> 1.5) - aws-sigv4 (1.10.1) + aws-sigv4 (1.11.0) aws-eventstream (~> 1, >= 1.0.2) babosa (1.0.4) base64 (0.2.0) @@ -33,13 +35,12 @@ GEM commander (4.6.0) highline (~> 2.0.0) declarative (0.0.20) - digest-crc (0.6.5) + digest-crc (0.7.0) rake (>= 12.0.0, < 14.0.0) - domain_name (0.5.20190701) - unf (>= 0.0.5, < 1.0.0) + domain_name (0.6.20240107) dotenv (2.8.1) emoji_regex (3.2.3) - excon (0.109.0) + excon (0.112.0) faraday (1.10.4) faraday-em_http (~> 1.0) faraday-em_synchrony (~> 1.0) @@ -59,8 +60,8 @@ GEM faraday-em_synchrony (1.0.0) faraday-excon (1.1.0) faraday-httpclient (1.0.1) - faraday-multipart (1.0.4) - multipart-post (~> 2) + faraday-multipart (1.1.0) + multipart-post (~> 2.0) faraday-net_http (1.0.2) faraday-net_http_persistent (1.2.0) faraday-patron (1.0.0) @@ -68,8 +69,8 @@ GEM faraday-retry (1.0.3) faraday_middleware (1.2.1) faraday (~> 1.0) - fastimage (2.3.1) - fastlane (2.225.0) + fastimage (2.4.0) + fastlane (2.227.1) CFPropertyList (>= 2.3, < 4.0.0) addressable (>= 2.8, < 3.0.0) artifactory (~> 3.0) @@ -109,7 +110,7 @@ GEM tty-spinner (>= 0.8.0, < 1.0.0) word_wrap (~> 1.0.0) xcodeproj (>= 1.13.0, < 2.0.0) - xcpretty (~> 0.3.0) + xcpretty (~> 0.4.1) xcpretty-travis-formatter (>= 0.0.3, < 2.0.0) fastlane-sirp (1.0.0) sysrandom (~> 1.0) @@ -128,19 +129,19 @@ GEM google-apis-core (>= 0.11.0, < 2.a) google-apis-playcustomapp_v1 (0.13.0) google-apis-core (>= 0.11.0, < 2.a) - google-apis-storage_v1 (0.29.0) + google-apis-storage_v1 (0.31.0) google-apis-core (>= 0.11.0, < 2.a) - google-cloud-core (1.6.1) + google-cloud-core (1.8.0) google-cloud-env (>= 1.0, < 3.a) google-cloud-errors (~> 1.0) google-cloud-env (1.6.0) faraday (>= 0.17.3, < 3.0) - google-cloud-errors (1.3.1) - google-cloud-storage (1.45.0) + google-cloud-errors (1.5.0) + google-cloud-storage (1.47.0) addressable (~> 2.8) digest-crc (~> 0.4) google-apis-iamcredentials_v1 (~> 0.1) - google-apis-storage_v1 (~> 0.29.0) + google-apis-storage_v1 (~> 0.31.0) google-cloud-core (~> 1.6) googleauth (>= 0.16.2, < 2.a) mini_mime (~> 1.0) @@ -151,36 +152,39 @@ GEM os (>= 0.9, < 2.0) signet (>= 0.16, < 2.a) highline (2.0.3) - http-cookie (1.0.7) + http-cookie (1.0.8) domain_name (~> 0.5) - httpclient (2.8.3) + httpclient (2.9.0) + mutex_m jmespath (1.6.2) - json (2.7.6) - jwt (2.9.3) + json (2.10.2) + jwt (2.10.1) base64 + logger (1.7.0) mini_magick (4.13.2) mini_mime (1.1.5) multi_json (1.15.0) multipart-post (2.4.1) + mutex_m (0.3.0) nanaimo (0.4.0) naturally (2.2.1) nkf (0.2.0) optparse (0.6.0) os (1.1.4) - plist (3.7.1) - public_suffix (5.1.1) + plist (3.7.2) + public_suffix (6.0.1) rake (13.2.1) representable (3.2.0) declarative (< 0.1.0) trailblazer-option (>= 0.1.1, < 0.2.0) uber (< 0.2.0) retriable (3.1.2) - rexml (3.3.9) - rouge (2.0.7) + rexml (3.4.1) + rouge (3.28.0) ruby2_keywords (0.0.5) - rubyzip (2.3.2) + rubyzip (2.4.1) security (0.1.5) - signet (0.18.0) + signet (0.19.0) addressable (~> 2.8) faraday (>= 0.17.5, < 3.a) jwt (>= 1.5, < 3.0) @@ -198,7 +202,6 @@ GEM tty-spinner (0.9.3) tty-cursor (~> 0.7) uber (0.1.0) - unf (0.2.0) unicode-display_width (2.6.0) word_wrap (1.0.0) xcodeproj (1.27.0) @@ -208,8 +211,8 @@ GEM colored2 (~> 3.1) nanaimo (~> 0.4.0) rexml (>= 3.3.6, < 4.0) - xcpretty (0.3.0) - rouge (~> 2.0.7) + xcpretty (0.4.1) + rouge (~> 3.28.0) xcpretty-travis-formatter (1.0.1) xcpretty (~> 0.2, >= 0.0.7) @@ -217,6 +220,7 @@ PLATFORMS arm64-darwin-21 arm64-darwin-22 arm64-darwin-23 + arm64-darwin-24 x86_64-darwin-19 x86_64-darwin-24 x86_64-linux @@ -225,4 +229,4 @@ DEPENDENCIES fastlane BUNDLED WITH - 2.4.19 + 2.6.2 From f3021a573f52a8740374ff0f9031217889f1377d Mon Sep 17 00:00:00 2001 From: Marion Barker <19607791+marionbarker@users.noreply.github.com> Date: Mon, 14 Apr 2025 12:16:38 -0700 Subject: [PATCH 21/24] update G7SensorKit: End of session detection bugfix PR 34 (#244) --- G7SensorKit | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/G7SensorKit b/G7SensorKit index 2be3eb29b0..67c55231dc 160000 --- a/G7SensorKit +++ b/G7SensorKit @@ -1 +1 @@ -Subproject commit 2be3eb29b0a18aa89f8b60281341e46e07d024e5 +Subproject commit 67c55231dc2f4913ed1b04d402985e6692acb37f From 4cb293f234ff81b4734ae46b50cf712f089edd75 Mon Sep 17 00:00:00 2001 From: Marion Barker <19607791+marionbarker@users.noreply.github.com> Date: Sat, 19 Apr 2025 15:08:17 -0700 Subject: [PATCH 22/24] update testflight.md, loopdocs links, generic instructions (#245) * update testflight.md, loopdocs links, generic instructions * fix typos in testflight.md --- fastlane/testflight.md | 38 +++++++++++++++++++------------------- 1 file changed, 19 insertions(+), 19 deletions(-) diff --git a/fastlane/testflight.md b/fastlane/testflight.md index 7c521a7379..126063f753 100644 --- a/fastlane/testflight.md +++ b/fastlane/testflight.md @@ -1,10 +1,10 @@ # Using GitHub Actions + FastLane to deploy to TestFlight -These instructions allow you to build Loop without having access to a Mac. +These instructions allow you to build your app without having access to a Mac. -* You can install Loop on phones using TestFlight that are not connected to your computer +* You can install your app on phones using TestFlight that are not connected to your computer * You can send builds and updates to those you care for -* You can install Loop on your phone using only the TestFlight app if a phone was lost or the app is accidentally deleted +* You can install your app on your phone using only the TestFlight app if a phone was lost or the app is accidentally deleted * You do not need to worry about specific Xcode/Mac versions for a given iOS ## **Automatic Builds** @@ -26,14 +26,14 @@ These instructions allow you to build Loop without having access to a Mac. The setup steps are somewhat involved, but nearly all are one time steps. Subsequent builds are trivial. Your app must be updated once every 90 days, but it's a simple click to make a new build and can be done from anywhere. The 90-day update is a TestFlight requirement, and with this version of Loop, the build process (once you've successfully built once) is automated to update and build at least once a month. -There are more detailed instructions in LoopDocs for using GitHub for Browser Builds of Loop, including troubleshooting and build errors. Please refer to: +There are more detailed instructions in LoopDocs for using GitHub for Browser Builds, including troubleshooting and build errors. Please refer to: -* [LoopDocs: GitHub Overview](https://loopkit.github.io/loopdocs/gh-actions/gh-overview/) -* [LoopDocs: GitHub Errors](https://loopkit.github.io/loopdocs/gh-actions/gh-errors/) +* [LoopDocs: Browser Overview](https://loopkit.github.io/loopdocs/browser/bb-overview/) +* [LoopDocs: Errors with Browser](https://loopkit.github.io/loopdocs/browser/bb-errors/) -Note that installing with TestFlight, (in the US), requires the Apple ID account holder to be 13 years or older. For younger Loopers, an adult must log into Media & Purchase on the child's phone to install Loop. More details on this can be found in [LoopDocs](https://loopkit.github.io/loopdocs/gh-actions/gh-deploy/#install-testflight-loop-for-child). +Note that installing with TestFlight, (in the US), requires the Apple ID account holder to be 13 years or older. For younger Loopers, an adult must log into Media & Purchase on the child's phone to install Loop. More details on this can be found in [LoopDocs](https://loopkit.github.io/loopdocs/browser/phone-install/#testflight-for-a-child). -If you build multiple apps, it is strongly recommended that you configure a free *GitHub* organization and do all your building in the organization. This means you enter items one time for the organization (6 SECRETS required to build and 1 VARIABLE required to automatically update your certificates annually). Otherwise, those 6 SECRETS must be entered for every repository. Please refer to [LoopDocs: Use a *GitHub* Organization Account](https://loopkit.github.io/loopdocs/gh-actions/gh-other-apps/#use-a-github-organization-account). +If you build multiple apps, it is strongly recommended that you configure a free *GitHub* organization and do all your building in the organization. This means you enter items one time for the organization (6 SECRETS required to build and 1 VARIABLE required to automatically update your certificates annually). Otherwise, those 6 SECRETS must be entered for every repository. Please refer to [LoopDocs: Create a *GitHub* Organization](https://loopkit.github.io/loopdocs/browser/secrets/#create-a-free-github-organization). ## Prerequisites @@ -43,14 +43,14 @@ If you build multiple apps, it is strongly recommended that you configure a free ## Save 6 Secrets -You require 6 Secrets (alphanumeric items) to use the GitHub build method and if you use the GitHub method to build more than Loop, e.g., Loop Follow or LoopCaregiver, you will use the same 6 Secrets for each app you build with this method. Each secret is indentified below by `ALL_CAPITAL_LETTER_NAMES`. +You require 6 Secrets (alphanumeric items) to use the GitHub build method and if you use the GitHub method to build more than Loop, e.g., Loop Follow or LoopCaregiver, you will use the same 6 Secrets for each app you build with this method. Each secret is identified below by `ALL_CAPITAL_LETTER_NAMES`. * Four Secrets are from your Apple Account * Two Secrets are from your GitHub account * Be sure to save the 6 Secrets in a text file using a text editor - Do **NOT** use a smart editor, which might auto-correct and change case, because these Secrets are case sensitive -Refer to [LoopDocs: Make a Secrets Reference File](https://loopkit.github.io/loopdocs/gh-actions/gh-first-time/#make-a-secrets-reference-file) for a handy template to use when saving your Secrets. +Refer to [LoopDocs: Make a Secrets Reference File](https://loopkit.github.io/loopdocs/browser/intro-summary/#make-a-secrets-reference-file) for a handy template to use when saving your Secrets. ## Generate App Store Connect API Key @@ -100,7 +100,7 @@ A private Match-Secrets repository is automatically created under your GitHub us * `MATCH_PASSWORD` 1. If you are using an organization, do this step at the organization level, e.g., username-org. If you are not using an organization, do this step at the repository level, e.g., username/LoopWorkspace: * Go to Settings -> Secrets and variables -> Actions and make sure the Variables tab is open -1. Tap on "Create new organization variable" or "Create new repository variable", then add the name below and enter the value true. Unlike secrets variables are visible and can be edited. +1. Tap on "Create new organization variable" or "Create new repository variable", then add the name below and enter the value true. Unlike secrets, variables are visible and can be edited. * `ENABLE_NUKE_CERTS` ## Validate repository secrets @@ -124,11 +124,11 @@ There can be a delay after you start a workflow before the screen changes. Refre ## Create App Group -If you have already built Loop via Xcode using this Apple ID, you can skip on to [Add App Group to Bundle Identifiers](#add-app-group-to-bundle-identifiers). +If you have already built Loop via Xcode using this Apple ID, you can skip ahead to [Add App Group to Bundle Identifiers](#add-app-group-to-bundle-identifiers). -1. Go to [Register an App Group](https://developer.apple.com/account/resources/identifiers/applicationGroup/add/) on the apple developer site. +1. Go to [Register an App Group](https://developer.apple.com/account/resources/identifiers/applicationGroup/add/) on the Apple Developer site. 1. For Description, use "Loop App Group". -1. For Identifier, enter "group.com.TEAMID.loopkit.LoopGroup", subsituting your team id for `TEAMID`. +1. For Identifier, enter "group.com.TEAMID.loopkit.LoopGroup", substituting your team id for `TEAMID`. 1. Click "Continue" and then "Register". ## Add App Group to Bundle Identifiers @@ -137,21 +137,21 @@ Note 1 - If you previously built with Xcode, the `Names` listed below may be dif Note 2 - Depending on your build history, you may find some of the Identifiers are already configured - and you are just verifying the status; but in other cases, you will need to configure the Identifiers. -1. Go to [Certificates, Identifiers & Profiles](https://developer.apple.com/account/resources/identifiers/list) on the apple developer site. +1. Go to [Certificates, Identifiers & Profiles](https://developer.apple.com/account/resources/identifiers/list) on the Apple Developer site. 1. For each of the following identifier names: * Loop * Loop Intent Extension * Loop Status Extension * Loop Widget Extension 1. Click on the identifier's name. -1. On the "App Groups" capabilies, click on the "Configure" button. +1. On the "App Groups" capabilities, click on the "Configure" button. 1. Select the "Loop App Group" 1. Click "Continue". 1. Click "Save". 1. Click "Confirm". 1. Remember to do this for each of the identifiers above. -#### Table with Name and Identifier for Loop 3 +#### Table with Name and Identifier for Loop | NAME | IDENTIFIER | |-------|------------| @@ -197,7 +197,7 @@ Once a year, you will get an email from Apple indicating your certificate will e ## TestFlight and Deployment Details -Please refer to [LoopDocs: Set Up Users](https://loopkit.github.io/loopdocs/gh-actions/gh-first-time/#set-up-users-and-access-testflight) and [LoopDocs: Deploy](https://loopkit.github.io/loopdocs/gh-actions/gh-deploy/) +Please refer to [LoopDocs: TestFlight Overview](https://loopkit.github.io/loopdocs/browser/tf-users) and [LoopDocs: Install on Phone](https://loopkit.github.io/loopdocs/browser/phone-install/) ## Automatic Build FAQs @@ -252,7 +252,7 @@ Note that the weekly and monthly Build Loop actions will continue, but the actio ### How to configure a variable -1. Go to the "Settings" tab of your LoopWorkspace repository. +1. Go to the "Settings" tab of your repository (to modify a single repository schedule) or your organization to affect all repositories. 2. Click on `Secrets and Variables`. 3. Click on `Actions` 4. You will now see a page titled *Actions secrets and variables*. Click on the `Variables` tab From 898fd08551e0c81802a843105a959146a6412751 Mon Sep 17 00:00:00 2001 From: Marion Barker <19607791+marionbarker@users.noreply.github.com> Date: Sat, 19 Apr 2025 15:25:34 -0700 Subject: [PATCH 23/24] Update submodules (#246) * update G7SensorKit: Fix calibration decoding, lagged backfill processing (#35) * update Loop: bugfixes #2163, #2230 * update LibreTransmitter: support Dependency Build Order * update OmniKit: support Dependency Build Order * update Loop: fix Issue 2168, modify save carb & deliver button --- G7SensorKit | 2 +- LibreTransmitter | 2 +- Loop | 2 +- OmniKit | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/G7SensorKit b/G7SensorKit index 67c55231dc..46047ed13c 160000 --- a/G7SensorKit +++ b/G7SensorKit @@ -1 +1 @@ -Subproject commit 67c55231dc2f4913ed1b04d402985e6692acb37f +Subproject commit 46047ed13c44d21bf75c7ca99642f954a35ed6c7 diff --git a/LibreTransmitter b/LibreTransmitter index f6c2d0f552..044cf70bd7 160000 --- a/LibreTransmitter +++ b/LibreTransmitter @@ -1 +1 @@ -Subproject commit f6c2d0f552e07aa778ec639d3faca571eaa0a97b +Subproject commit 044cf70bd79813d47048291b740a599e1ab4ab40 diff --git a/Loop b/Loop index 0a3a165189..e45f1376bc 160000 --- a/Loop +++ b/Loop @@ -1 +1 @@ -Subproject commit 0a3a1651894f06ddce7a2feff9b6d299a34e6d2d +Subproject commit e45f1376bc8cdf5f8ed009f0f165455909e60155 diff --git a/OmniKit b/OmniKit index 39915b05fe..92948a7684 160000 --- a/OmniKit +++ b/OmniKit @@ -1 +1 @@ -Subproject commit 39915b05fe46b5d73eca52e156dd7efd11193ee8 +Subproject commit 92948a7684ec382714becc53c643a1617597bb37 From b121942874f77ef3e9fe14963a2b8273ca87a41c Mon Sep 17 00:00:00 2001 From: Marion Barker <19607791+marionbarker@users.noreply.github.com> Date: Tue, 22 Apr 2025 12:17:52 -0700 Subject: [PATCH 24/24] disable keepalive-workflow because the repo is no longer available (#248) --- .github/workflows/build_loop.yml | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/.github/workflows/build_loop.yml b/.github/workflows/build_loop.yml index 8cc3a36c6a..66a792eea2 100644 --- a/.github/workflows/build_loop.yml +++ b/.github/workflows/build_loop.yml @@ -171,12 +171,14 @@ jobs: # Keep repository "alive": add empty commits to ALIVE_BRANCH after "time_elapsed" days of inactivity to avoid inactivation of scheduled workflows - name: Keep alive - if: | - needs.check_alive_and_permissions.outputs.WORKFLOW_PERMISSION == 'true' && - (vars.SCHEDULED_BUILD != 'false' || vars.SCHEDULED_SYNC != 'false') - uses: gautamkrishnar/keepalive-workflow@v1 # using the workflow with default settings - with: - time_elapsed: 20 # Time elapsed from the previous commit to trigger a new automated commit (in days) + run: | + echo "Keep Alive temporarily removed while gautamkrishnar/keepalive-workflow is not available" + # if: | + # needs.check_alive_and_permissions.outputs.WORKFLOW_PERMISSION == 'true' && + # (vars.SCHEDULED_BUILD != 'false' || vars.SCHEDULED_SYNC != 'false') + # uses: gautamkrishnar/keepalive-workflow@v1 # using the workflow with default settings + # with: + # time_elapsed: 20 # Time elapsed from the previous commit to trigger a new automated commit (in days) - name: Show scheduled build configuration message if: needs.check_alive_and_permissions.outputs.WORKFLOW_PERMISSION != 'true'