Skip to content

Commit

Permalink
Merge pull request #3355 from nightscout/dev
Browse files Browse the repository at this point in the history
3.3.0.0
  • Loading branch information
MilosKozak authored Dec 29, 2024
2 parents 3df8353 + dc7b777 commit 9090561
Show file tree
Hide file tree
Showing 5,308 changed files with 197,831 additions and 90,147 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
57 changes: 40 additions & 17 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,35 +4,58 @@ version: 2.1

# Orbs are reusable packages of CircleCI configuration that you may share across projects, enabling you to create encapsulated, parameterized commands, jobs, and executors that can be used across multiple projects.
orbs:
android: circleci/android@2.3.0
android: circleci/android@2.4.0
codecov: codecov/[email protected]

jobs:
# Below is the definition of your job to build and test your app, you can rename and customize it as you want.
build-and-test:
# These next lines define the Android machine image executor: https://circleci.com/docs/2.0/executor-types/
executor:
name: android/android-machine
resource-class: large
tag: 2023.11.1
machine: true
resource_class: nightscout/android

steps:
- checkout

- android/change-java-version:
java-version: 17
- run:
name: Create avd
command: |
echo "no" | /opt/android-sdk/cmdline-tools/latest/bin/avdmanager --verbose create avd -n citest -k "system-images;android-30;google_apis_playstore;x86" --force
- android/start-emulator-and-run-tests:
system-image: system-images;android-29;google_apis;x86
# Compile while the emulator starts to use the time.
post-emulator-launch-assemble-command: ./gradlew compileFullDebugUnitTestSources compileFullDebugAndroidTestSources
test-command: ./gradlew connectedFullDebugAndroidTest
- run:
name: Launch emulator
command: |
export ANDROID_SDK_ROOT=/opt/android-sdk
export ANDROID_HOME=/opt/android-sdk
emulator -avd citest -delay-adb -verbose -no-window -gpu swiftshader_indirect -no-snapshot -noaudio -no-boot-anim
background: true

- android/run-tests:
test-command: ./gradlew testFullDebugUnitTest
- run:
name: Run connectedFullDebugAndroidTest
command: |
export ANDROID_SDK_ROOT=/opt/android-sdk
export ANDROID_HOME=/opt/android-sdk
env
./gradlew -Dorg.gradle.jvmargs=-Xmx6g connectedFullDebugAndroidTest
- run:
name: Kill emulators
command: |
echo "Killing emulators"
adb devices | grep emulator | cut -f1 | while read -r line; do adb -s $line emu kill; done
- run:
name: Run testFullDebugUnitTest
command: |
export ANDROID_SDK_ROOT=/opt/android-sdk
export ANDROID_HOME=/opt/android-sdk
./gradlew -Dorg.gradle.jvmargs=-Xmx6g testFullDebugUnitTest
- android/run-tests:
test-command: ./gradlew --stacktrace jacocoAllDebugReport
- run:
run: Run jacocoAllDebugReport
command: |
export ANDROID_SDK_ROOT=/opt/android-sdk
export ANDROID_HOME=/opt/android-sdk
./gradlew --stacktrace jacocoAllDebugReport
- run:
name: Save test results
Expand Down
60 changes: 60 additions & 0 deletions .circleci/config.yml.cloud
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
# Use the latest 2.1 version of CircleCI pipeline process engine.
# See: https://circleci.com/docs/2.0/configuration-reference
version: 2.1

# Orbs are reusable packages of CircleCI configuration that you may share across projects, enabling you to create encapsulated, parameterized commands, jobs, and executors that can be used across multiple projects.
orbs:
android: circleci/[email protected]
codecov: codecov/[email protected]

jobs:
# Below is the definition of your job to build and test your app, you can rename and customize it as you want.
build-and-test:
# These next lines define the Android machine image executor: https://circleci.com/docs/2.0/executor-types/
executor:
name: android/android-machine
resource-class: large
tag: 2023.11.1

steps:
- checkout

- android/change-java-version:
java-version: 17

- android/start-emulator-and-run-tests:
system-image: system-images;android-29;google_apis;x86
# Compile while the emulator starts to use the time.
post-emulator-launch-assemble-command: ./gradlew compileFullDebugUnitTestSources compileFullDebugAndroidTestSources
test-command: ./gradlew connectedFullDebugAndroidTest

- android/run-tests:
test-command: ./gradlew testFullDebugUnitTest

- android/run-tests:
test-command: ./gradlew --stacktrace jacocoAllDebugReport

- run:
name: Save test results
command: |
mkdir -p ~/test-results/junit/
find . -type f -regex ".*/build/outputs/androidTest-results/.*xml" -exec cp {} ~/test-results/junit/ \;
when: always

- store_test_results:
path: ~/test-results

- store_artifacts:
path: ~/test-results/junit

- codecov/upload:
file: './build/reports/jacoco/jacocoAllDebugReport/jacocoAllDebugReport.xml'

workflows:
# Below is the definition of your workflow.
# Inside the workflow, you provide the jobs you want to run, e.g this workflow runs the build-and-test job above.
# CircleCI will run this workflow on every commit.
# For more details on extending your workflow, see the configuration docs: https://circleci.com/docs/2.0/configuration-reference/#workflows
dotests:
jobs:
- build-and-test
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/custom.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,5 @@ Reporting bugs
upper-right corner).
- Obtain the app's log files, which can be found on the phone in
_/storage/emulated/0/Android/data/info.nightscout.androidaps/_
See https://wiki.aaps.app/en/latest/Usage/Accessing-logfiles.html
See https://wiki.aaps.app/en/latest/GettingHelp/AccessingLogFiles.html
- Open an issue at https://github.com/nightscout/AndroidAPS/issues/new
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
*/output-metadata.json
/build
/captures
/java_pid*
*.apk
build/
!.idea/dictionaries/project-dictionary.xml
Expand All @@ -26,3 +27,6 @@ app/pumpcontrol/*
wear/aapsclient/*
wear/aapsclient2/*
wear/pumpcontrol/*
.kotlin/*
/*.log
*.preferences_pb
4 changes: 2 additions & 2 deletions .idea/codeStyles/Project.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 15 additions & 0 deletions .idea/dictionaries/project_dictionary.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 4 additions & 0 deletions .kotlin/errors/errors-1730369688333.log
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
kotlin version: 2.0.21
error message: The daemon has terminated unexpectedly on startup attempt #1 with error code: 0. The daemon process output:
1. Kotlin compile daemon is ready

20 changes: 10 additions & 10 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,31 +1,31 @@
This document speciffy hints and good practices for source code contributions.
This document specify hints and good practices for source code contributions.

AndroidAPS is community effort and all contributions are welcome! If you wish help us improving AAPS - please read and try to adhere to
this guidelines, to make the development and process of change aproval as smooth as possible :)
this guidelines, to make the development and process of change approval as smooth as possible :)

General rules
=============

* There are plenty of ways you can help, some of them are listed on wiki:
https://wiki.aaps.app/en/latest/Getting-Started/How-can-I-help.html
* If you wish to help with documentation or translating:
https://wiki.aaps.app/en/latest/translations.html
* There are plenty of ways you can help, some of them are listed on wiki:
https://wiki.aaps.app/en/latest/SupportingAaps/HowCanIHelp.html
* If you wish to help with documentation or translating:
https://wiki.aaps.app/en/latest/SupportingAaps/Translations.html

Development guidelines
======================

Coding convetions
Coding conventions
-----------------
1. Use Android Studio with default indents (4 chars, use spaces)
2. Use autoformat feature CTRL-ALT-L in every changed file before commit

Committing Changes / Pull Requests
---------------------------------

1. Make fork of repository on github
1. Make a fork of [repository](https://github.com/nightscout/AndroidAPS) on GitHub (be aware to uncheck the box "Copy the master branch only")
2. Create separate branch for each feature, branch from most recent dev
3. Commit all changes to your fork
4. When ready, rebase on top of dev and make pull request to main repo
4. When ready, rebase on top of dev and make Pull Request to main repo

Naming Conventions for Pull Requests / Branches
-----------------------------------------------
Expand All @@ -45,4 +45,4 @@ Hints
* Take a look into Issues list (https://github.com/nightscout/AndroidAPS/issues) - maybe there is something you can fix or implement
* For new features, make sure there is Issue to track progress and have on-topic discussion
* Reach out to community, discuss idea on Discord (https://discord.gg/4fQUWHZ4Mw)
* Speak with other developers to minimise merge conflicts. Find out who worked, working or plan to work on speciffic issue or part of app
* Speak with other developers to minimize merge conflicts. Find out who worked, working or plan to work on specific issue or part of app
2 changes: 1 addition & 1 deletion ISSUE_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,5 @@ Reporting bugs
upper-right corner).
- Obtain the app's log files, which can be found on the phone in
_/storage/emulated/0/Android/data/info.nightscout.androidaps/_
See https://wiki.aaps.app/en/latest/Usage/Accessing-logfiles.html
See https://wiki.aaps.app/en/latest/GettingHelp/AccessingLogFiles.html
- Open an issue at https://github.com/nightscout/AndroidAPS/issues/new
Loading

0 comments on commit 9090561

Please sign in to comment.