Skip to content

Commit

Permalink
5.2.0 (#881)
Browse files Browse the repository at this point in the history
  • Loading branch information
Jon-b-m authored Sep 23, 2024
1 parent d76297b commit aca9462
Show file tree
Hide file tree
Showing 36 changed files with 363 additions and 184 deletions.
52 changes: 38 additions & 14 deletions .github/workflows/build_iAPS.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,23 +3,47 @@ run-name: Build iAPS (${{ 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:
# this will trigger this workflow for any push to any branch that this workflow is
# active on, *but*, the auto_build_check job will check to see if this branch is
# enabled *for* being auto built, and short circuit the process if so.
#
# if AUTO_BUILD_BRANCHES is not set, or the current branch is not listed, this
# workflow is triggered, but doesn't actually do anything.
#
push:

schedule:
#- cron: '30 04 1 * *' # Runs at 04:30 UTC on the 1st every month
- 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: Artificial-Pancreas/iAPS
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

jobs:
auto_build_check:
name: Check Auto Build Status
runs-on: ubuntu-latest
outputs:
AUTO_BUILD_ENABLED: ${{ steps.auto-build-enabled.outputs.auto_build }}

steps:
- name: Is Auto Build Branch
id: auto-build-enabled
run: |
echo "auto_build=false" >> $GITHUB_OUTPUT
if [ ! -z "${{ vars.AUTO_BUILD_BRANCHES }}" ]; then
if echo ",${{ vars.AUTO_BUILD_BRANCHES }}," | grep -q ",${{ github.ref_name }},"; then
echo "auto_build=true" >> $GITHUB_OUTPUT
fi
fi
- name: Show Auto Build Status
run: |
echo "Auto Build Status: ${{ steps.auto-build-enabled.outputs.auto_build }}"
validate:
name: Validate
needs: auto_build_check
if: needs.auto_build_check.outputs.AUTO_BUILD_ENABLED == 'true' || github.event_name == 'workflow_dispatch'
uses: ./.github/workflows/validate_secrets.yml
secrets: inherit

Expand All @@ -44,7 +68,7 @@ jobs:
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.
echo "has_permission=true" >> $GITHUB_OUTPUT # Set WORKFLOW_PERMISSION to true.
else
echo "GH_PAT lacks workflow permissions."
echo "Automated build features will be skipped!"
Expand Down Expand Up @@ -128,13 +152,13 @@ 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 == 'true' && needs.check_latest_from_upstream.outputs.NEW_COMMITS == 'true' )
)
steps:
- name: Set special variables
run: |
if [ ! -z ${{ vars.APP_IDENTIFIER }} ]; then
echo "APP_IDENTIFIER=${{ vars.APP_IDENTIFIER }}" >> $GITHUB_ENV
fi
- name: Select Xcode version
run: "sudo xcode-select --switch /Applications/Xcode_15.3.app/Contents/Developer"

Expand Down
40 changes: 40 additions & 0 deletions .github/workflows/syncUpstreamRepo.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@

name: 5. Sync Upstream
run-name: Sync Upstream (${{ github.ref_name }})

env:
UPSTREAM_URL: "https://github.com/Artificial-Pancreas/iAPS.git"
WORKFLOW_TOKEN: ${{ secrets.GH_PAT }}
UPSTREAM_BRANCH: "${{ github.ref_name }}"
DOWNSTREAM_BRANCH: "${{ github.ref_name }}"
# Optional fetch arguments
FETCH_ARGS: ""
# Optional merge arguments
MERGE_ARGS: ""
# Optional push arguments
PUSH_ARGS: ""
# Optional toggle to spawn time logs (keeps action active)
SPAWN_LOGS: "false" # "true" or "false"

on:

schedule:
- cron: '0 * * * *' # scheduled to run hourly

workflow_dispatch: # trigger manually

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: GitHub Sync to Upstream Repository
uses: Artificial-Pancreas/sync-upstream-repo@master
with:
upstream_repo: ${{ env.UPSTREAM_URL }}
upstream_branch: ${{ env.UPSTREAM_BRANCH }}
downstream_branch: ${{ env.DOWNSTREAM_BRANCH }}
token: ${{ env.WORKFLOW_TOKEN }}
fetch_args: ${{ env.FETCH_ARGS }}
merge_args: ${{ env.MERGE_ARGS }}
push_args: ${{ env.PUSH_ARGS }}
spawn_logs: ${{ env.SPAWN_LOGS }}
2 changes: 1 addition & 1 deletion Config.xcconfig
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
APP_DISPLAY_NAME = iAPS
APP_VERSION = 5.0.4
APP_VERSION = 5.2.0
APP_BUILD_NUMBER = 1
COPYRIGHT_NOTICE =
DEVELOPER_TEAM = ##TEAM_ID##
Expand Down
4 changes: 2 additions & 2 deletions FreeAPS/Resources/json/defaults/freeaps/freeaps_settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@
"minumimPrediction": true,
"minimumSMB": 0.3,
"useInsulinBars": false,
"uploadVersion": true,
"birthDate": Date.distantPast,
"displayDelta": false
"displayDelta": false,
"profileID": "Hypo Treatment"
}
2 changes: 1 addition & 1 deletion FreeAPS/Sources/APS/APSManager.swift
Original file line number Diff line number Diff line change
Expand Up @@ -1247,7 +1247,7 @@ final class BaseAPSManager: APSManager, Injectable {
)
storage.save(dailystat, as: file)
nightscout.uploadStatistics(dailystat: dailystat)
} else if settingsManager.settings.uploadVersion {
} else {
let json = BareMinimum(
id: getIdentifier(),
created_at: Date.now,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -642,6 +642,9 @@ Enact a temp Basal or a temp target */
/* Treatments list */
"Treatments" = "العلاجات";

/* Hypo Treatment Preset */
"Treatment" = "Treatment";

/* " min" in Treatments list */
" min" = " د";

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -641,6 +641,9 @@ Enact a temp Basal or a temp target */
/* Treatments list */
"Treatments" = "Behandlinger";

/* Hypo Treatment Preset */
"Treatment" = "Treatment";

/* " min" in Treatments list */
" min" = " min";

Expand Down Expand Up @@ -2521,15 +2524,12 @@ Enact a temp Basal or a temp target */
/* UI/UX option */
"Never display the small glucose chart when scrolling" = "Never display the small glucose chart when scrolling";

<<<<<<< HEAD
=======
/* UI/UX option */
"Disable Hypo Treatments" = "Disable Hypo Treatments";

/* UI/UX option */
"Display Glucose Delta" = "Display Glucose Delta";

>>>>>>> dev
/* Setting title */
"Bolus Calculator" = "Bolus Lommeregner";

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -641,6 +641,9 @@ Enact a temp Basal or a temp target */
/* Treatments list */
"Treatments" = "Behandlungen";

/* Hypo Treatment Preset */
"Treatment" = "Treatment";

/* " min" in Treatments list */
" min" = " Min";

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -641,6 +641,9 @@ Enact a temp Basal or a temp target */
/* Treatments list */
"Treatments" = "Tratamientos";

/* Hypo Treatment Preset */
"Treatment" = "Treatment";

/* " min" in Treatments list */
" min" = " min";

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -641,6 +641,9 @@ Enact a temp Basal or a temp target */
/* Treatments list */
"Treatments" = "Treatments";

/* Hypo Treatment Preset */
"Treatment" = "Treatment";

/* " min" in Treatments list */
" min" = " min";

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -641,6 +641,9 @@ Enact a temp Basal or a temp target */
/* Treatments list */
"Treatments" = "Traitements";

/* Hypo Treatment Preset */
"Treatment" = "Traitement";

/* " min" in Treatments list */
" min" = " min";

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -641,6 +641,9 @@ Enact a temp Basal or a temp target */
/* Treatments list */
"Treatments" = "Treatments";

/* Hypo Treatment Preset */
"Treatment" = "Treatment";

/* " min" in Treatments list */
" min" = " min";

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -641,6 +641,9 @@ Enact a temp Basal or a temp target */
/* Treatments list */
"Treatments" = "Kezelések";

/* Hypo Treatment Preset */
"Treatment" = "Treatment";

/* " min" in Treatments list */
" min" = " perc";

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -641,6 +641,9 @@ Enact a temp Basal or a temp target */
/* Treatments list */
"Treatments" = "Trattamenti";

/* Hypo Treatment Preset */
"Treatment" = "Treatment";

/* " min" in Treatments list */
" min" = " min";

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -641,6 +641,9 @@ Enact a temp Basal or a temp target */
/* Treatments list */
"Treatments" = "Behandlinger";

/* Hypo Treatment Preset */
"Treatment" = "Treatment";

/* " min" in Treatments list */
" min" = " min";

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@
"Suggested at" = "Voorgesteld op";

/* Headline in enacted pop up (at: at what time) */
"Status at" = "Status at";
"Status at" = "Status op";

/* Bolus View Meal Summary Header */
"Meal Summary" = "Maaltijd overzicht";
Expand Down Expand Up @@ -149,7 +149,7 @@
"No suggestion" = "Geen suggestie";

/* Replace pod text in Header */
"Replace pod" = "Vervang Pod";
"Replace pod" = "Vervang pod";

/* Add carbs screen */
"Add Carbs" = "Koolhydraten toevoegen";
Expand Down Expand Up @@ -641,6 +641,9 @@ Enact a temp Basal or a temp target */
/* Treatments list */
"Treatments" = "Behandelingen";

/* Hypo Treatment Preset */
"Treatment" = "Behandeling";

/* " min" in Treatments list */
" min" = "min";

Expand Down Expand Up @@ -1249,7 +1252,7 @@ Enact a temp Basal or a temp target */
"Can't enact the new loop cycle recommendation, because a Bolus is in progress. Wait for next loop cycle" = "Kan het nieuwe loopcyclus advies niet uitvoeren, omdat er een bolus bezig is. Wacht op de volgende cyclus";

/* Pump Error */
"Pump is Busy." = "Pump is Busy.";
"Pump is Busy." = "Je pomp is bezig.";

/* -------------- Developer settings ---------------------- */
/* Debug options */
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -643,6 +643,9 @@ Połączono z Nightscout!";
/* Treatments list */
"Treatments" = "Treatments";

/* Hypo Treatment Preset */
"Treatment" = "Treatment";

/* " min" in Treatments list */
" min" = " min";

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -641,6 +641,9 @@ Enact a temp Basal or a temp target */
/* Treatments list */
"Treatments" = "Tratamentos";

/* Hypo Treatment Preset */
"Treatment" = "Treatment";

/* " min" in Treatments list */
" min" = " min";

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -641,6 +641,9 @@ Enact a temp Basal or a temp target */
/* Treatments list */
"Treatments" = "Treatments";

/* Hypo Treatment Preset */
"Treatment" = "Treatment";

/* " min" in Treatments list */
" min" = " min";

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -641,6 +641,9 @@ Enact a temp Basal or a temp target */
/* Treatments list */
"Treatments" = "События";

/* Hypo Treatment Preset */
"Treatment" = "Терапия";

/* " min" in Treatments list */
" min" = " мин";

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -641,6 +641,9 @@ Enact a temp Basal or a temp target */
/* Treatments list */
"Treatments" = "Ošetrenia";

/* Hypo Treatment Preset */
"Treatment" = "Treatment";

/* " min" in Treatments list */
" min" = " min";

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -641,6 +641,9 @@ Enact a temp Basal or a temp target */
/* Treatments list */
"Treatments" = "Behandlingar";

/* Hypo Treatment Preset */
"Treatment" = "Behandling";

/* " min" in Treatments list */
" min" = " min";

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -641,6 +641,9 @@ Enact a temp Basal or a temp target */
/* Treatments list */
"Treatments" = "Tedaviler";

/* Hypo Treatment Preset */
"Treatment" = "Treatment";

/* " min" in Treatments list */
" min" = " dk";

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -641,6 +641,9 @@ Enact a temp Basal or a temp target */
/* Treatments list */
"Treatments" = "Події";

/* Hypo Treatment Preset */
"Treatment" = "Лікування";

/* " min" in Treatments list */
" min" = " хв";

Expand Down Expand Up @@ -2525,7 +2528,7 @@ Enact a temp Basal or a temp target */
"Disable Hypo Treatments" = "Вимкнути гіпотерапію";

/* UI/UX option */
"Display Glucose Delta" = "Display Glucose Delta";
"Display Glucose Delta" = "Відображати дельту Глюкози";

/* Setting title */
"Bolus Calculator" = "Калькулятор Болюса";
Expand Down
Loading

0 comments on commit aca9462

Please sign in to comment.