Skip to content

Commit

Permalink
Merge branch 'medic:master' into master
Browse files Browse the repository at this point in the history
  • Loading branch information
kennethatria authored Mar 15, 2022
2 parents 87ae4b9 + 7d487dd commit b5e8d91
Show file tree
Hide file tree
Showing 114 changed files with 2,062 additions and 2,414 deletions.
3 changes: 3 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ root = true
charset = utf-8
end_of_line = lf
insert_final_newline = true
indent_style = space
indent_size = 2

[{*.java, Makefile}]
indent_style = tab
indent_size = 4
37 changes: 37 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
---
name: Bug report
about: Create a report to help us improve
title: ''
labels: 'Type: Bug'
assignees: ''

---

**Important**: This is a public repository. Anyone in the world can see what's posted here. If you are posting screenshots or log files, please **carefully examine them for** the presence of any kind of **protected health information** (PHI). Images or logs containing PHI _must_ be posted in fully-redacted form, with no visible PHI.

**Describe the bug**
A clear and concise description of what the bug is.

**To Reproduce**
Steps to reproduce the behavior:
1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error

**Expected behavior**
A clear and concise description of what you expected to happen.

**Logs**
If applicable, include the server or browser logs.

**Screenshots**
If applicable, add screenshots to help explain your problem.

**Environment**
- Instance: (eg: alpha.dev.medicmobile.org, etc)
- Android Version: (eg: 4.4, 11, etc)
- App Version: (eg: 0.7.3, 0.9.0, etc)

**Additional context**
Add any other context about the problem here. What have you tried? Is there a workaround?
20 changes: 20 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
---
name: Feature request
about: Suggest an idea for this project
title: ''
labels: 'Type: Feature'
assignees: ''

---

**Is your feature request related to a problem? Please describe.**
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

**Describe the solution you'd like**
A clear and concise description of what you want to happen.

**Describe alternatives you've considered**
A clear and concise description of any alternative solutions or features you've considered.

**Additional context**
Add any other context or screenshots about the feature request here.
20 changes: 20 additions & 0 deletions .github/ISSUE_TEMPLATE/improvement.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
---
name: Improvement
about: Suggest something to make an existing feature better
title: ''
labels: 'Type: Improvement'
assignees: ''

---

**What feature do you want to improve?**
A clear and concise description of what the problem is. Ex. It would be better to [...]

**Describe the improvement you'd like**
A clear and concise description of what you want to happen.

**Describe alternatives you've considered**
A clear and concise description of any alternative solutions or features you've considered.

**Additional context**
Add any other context or screenshots about the feature request here.
14 changes: 14 additions & 0 deletions .github/ISSUE_TEMPLATE/support_request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---
name: Support request
about: Ask for assistance
title: ''
labels: ''
assignees: ''

---

READ THIS FIRST

The best way to get support and answers to questions is by posting on the CHT Forum as it has high engagement amongst the wider CHT community so you're more likely to get the answer you need.

Please raise your request on the Forum: https://forum.communityhealthtoolkit.org
17 changes: 17 additions & 0 deletions .github/ISSUE_TEMPLATE/technical_issue.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
name: Technical issue
about: Suggest an improvement users won't notice
title: ''
labels: 'Type: Technical issue'
assignees: ''

---

**Describe the issue**
A clear and concise description of what the problem is.

**Describe the improvement you'd like**
A clear and concise description of what you want to change.

**Describe alternatives you've considered**
A clear and concise description of any alternative solutions or features you've considered.
53 changes: 53 additions & 0 deletions .github/ISSUE_TEMPLATE/z_release_major.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
---
name: Major/minor release
about: Schedule a major or minor release
title: 'Release vX.Y.Z'
labels: 'Type: Internal process'
assignees: ''

---

# Planning - Product Manager

- [ ] Create a GH Milestone for the release. We use [semver](http://semver.org) so if there are breaking changes increment the major, otherwise if there are new features increment the minor, otherwise increment the service pack. Breaking changes in our case relate to updated software requirements (egs: minimum Android versions), broken backwards compatibility in an api, or a major visual update that requires user retraining.
- [ ] Add all the issues to be worked on to the Milestone. Ideally each minor release will have one or two features, a handful of improvements, and plenty of bug fixes.
- [ ] Identify any features and improvements in the release that need end-user documentation (beyond eng team documentation improvements) and create corresponding issues in the cht-docs repo
- [ ] Assign an engineer as Release Engineer for this release.

# Development - Release Engineer

When development is ready to begin one of the engineers should be nominated as a Release Engineer. They will be responsible for making sure the following tasks are completed though not necessarily completing them.

- [ ] Raise a new issue called `Update dependencies for <version>`. This should be done early in the release cycle so find a volunteer to take this on and assign it to them.
- [ ] Write an update in the weekly Product Team call agenda summarising development and acceptance testing progress and identifying any blockers. The release Engineer is to update this every week until the version is released.

# Releasing - Release Engineer

Once all issues have passed acceptance testing and have been merged into `master` release testing can begin.

- [ ] Create a new release branch from `master` named `v<major>.<minor>.x`.
- [ ] Build an alpha named `v<major>.<minor>.<patch>-alpha.1` as described in the [release docs](https://docs.communityhealthtoolkit.org/core/guides/android/releasing/#alpha-for-release-testing).
- [ ] Until release testing passes, make sure regressions are fixed in `master`, cherry-pick them into the release branch, and release another alpha.
- [ ] Create a `release_notes_v<major>.<minor>.<patch>` branch from `master` and add a new section in the [CHANGELOG](https://github.com/medic/cht-android/blob/master/CHANGELOG.md).
- [ ] Ensure all issues are in the GH Milestone, that they're correctly labelled (in particular: they have the right Type, "UI/UX" if they change the UI, and "Breaking change" if appropriate), and have human readable descriptions.
- [ ] Document any known migration steps and known issues.
- [ ] Provide description, screenshots, videos, and anything else to help communicate particularly important changes.
- [ ] Document any required or recommended upgrades to our other products (eg: cht-core, cht-conf, cht-gateway).
- [ ] Assign the PR to the Director of Technology to review and confirm the documentation on upgrade instructions and breaking changes is sufficient.
- [ ] Create a release in GitHub as described in the [release docs](https://docs.communityhealthtoolkit.org/core/guides/android/releasing/#production-release).

# Publishing - Release Engineer

- [ ] Download the `.apk` files (or `.aab` files) from the assets on the release in GitHub for each reference flavor to publish:
- `medicmobilegamma`
- `unbranded`
- [ ] Publish a release for each flavor as described in the [publishing docs](https://docs.communityhealthtoolkit.org/core/guides/android/publishing/#google-play-store).
- [ ] Announce the release on the [CHT forum](https://forum.communityhealthtoolkit.org/c/product/releases/26), under the "Product - Releases" category using this template:
```
*We're excited to announce the release of [{{version}}](https://github.com/medic/cht-android/releases/tag/{{version}}) of cht-android*
New features include {{key_features}}. We've also implemented loads of other improvements and fixed a heap of bugs.
Read the release notes for full details: {{url}}
```
- [ ] Mark this issue "done" and close the Milestone.
47 changes: 47 additions & 0 deletions .github/ISSUE_TEMPLATE/z_release_patch.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
---
name: Patch release
about: Schedule a patch release
title: 'Release vX.Y.Z'
labels: 'Type: Internal process'
assignees: ''

---

# Planning - Product Manager

- [ ] Create an GH Milestone and add this issue to it.
- [ ] Add all the issues to be worked on to the Milestone.

# Development - Release Engineer

When development is ready to begin one of the engineers should be nominated as a Release Engineer. They will be responsible for making sure the following tasks are completed though not necessarily completing them.

- [ ] Write an update in the weekly Product Team call agenda summarising development and acceptance testing progress and identifying any blockers. The Release Engineer is to update this every week until the version is released.

# Releasing - Release Engineer

Once all issues have passed acceptance testing and have been merged into `master` and backported to the release branch release testing can begin.

- [ ] Build an alpha named `v<major>.<minor>.<patch>-alpha.1` as described in the [release docs](https://docs.communityhealthtoolkit.org/core/guides/android/releasing/#alpha-for-release-testing).
- [ ] Until release testing passes, make sure regressions are fixed in `master`, cherry-pick them into the release branch, and release another alpha.
- [ ] Create a `release_notes_v<major>.<minor>.<patch>` branch from `master` and add a new section in the [CHANGELOG](https://github.com/medic/cht-android/blob/master/CHANGELOG.md).
- [ ] Ensure all issues are in the GH Milestone, that they're correctly labelled (in particular: they have the right Type, "UI/UX" if they change the UI, and "Breaking change" if appropriate), and have human readable descriptions.
- [ ] Document any known migration steps and known issues.
- [ ] Provide description, screenshots, videos, and anything else to help communicate particularly important changes.
- [ ] Document any required or recommended upgrades to our other products (eg: cht-core, cht-conf, cht-gateway).
- [ ] Assign the PR to the Director of Technology to review and confirm the documentation on upgrade instructions and breaking changes is sufficient.
- [ ] Create a release in GitHub as described in the [release docs](https://docs.communityhealthtoolkit.org/core/guides/android/releasing/#production-release).

# Publishing - Release Engineer

- [ ] Download the `.apk` files (or `.aab` files) from the assets on the release in GitHub for each reference flavor to publish:
- `medicmobilegamma`
- `unbranded`
- [ ] Publish a release for each flavor as described in the [publishing docs](https://docs.communityhealthtoolkit.org/core/guides/android/publishing/#google-play-store).
- [ ] Announce the release on the [CHT forum](https://forum.communityhealthtoolkit.org/c/product/releases/26), under the "Product - Releases" category using this template:
```
*Announcing the release of [{{version}}](https://github.com/medic/cht-android/releases/tag/{{version}}) of cht-android*
This release fixes {{number of bugs}}. Read the release notes for full details: {{url}}
```
- [ ] Mark this issue "done" and close the Milestone.
57 changes: 47 additions & 10 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -1,32 +1,45 @@
name: Build and test

on:
push:
branches:
- master
paths-ignore:
- '**.md'
pull_request:
paths-ignore:
- '**.md'
on: [push, pull_request]

jobs:

skip_check:

name: Skip Check
runs-on: ubuntu-latest
outputs:
should_skip: ${{ steps.skip_check.outputs.should_skip }}
steps:
- id: skip_check
uses: fkirc/skip-duplicate-actions@master
with:
concurrent_skipping: 'same_content_newer'
paths_ignore: '["**.md"]'


build:

name: Build
runs-on: ubuntu-18.04
runs-on: ubuntu-latest
needs: skip_check
if: ${{ needs.skip_check.outputs.should_skip != 'true' }}
steps:

- name: Checkout
uses: actions/checkout@v2
with:
submodules: true

- name: Set up Java 11
uses: actions/setup-java@v2
with:
distribution: 'adopt'
java-version: '11'

- name: Test Bash Keystores scripts
run: make test-bash-keystore

- name: Test
run: make test

Expand Down Expand Up @@ -63,10 +76,14 @@ jobs:

name: Instrumentation tests
runs-on: macos-latest
needs: skip_check
if: ${{ needs.skip_check.outputs.should_skip != 'true' }}
steps:

- name: Checkout
uses: actions/checkout@v2
with:
submodules: true

- name: Set up Java 11
uses: actions/setup-java@v2
Expand Down Expand Up @@ -102,6 +119,9 @@ jobs:
disable-animations: false
script: echo "Generated AVD snapshot for caching."

- name: Test Bash Keystores scripts on MacOS
run: make test-bash-keystore

- name: Run test-ui on unbranded
uses: reactivecircus/android-emulator-runner@v2
with:
Expand All @@ -119,3 +139,20 @@ jobs:
force-avd-creation: false
emulator-options: -no-snapshot-save -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none
script: make test-ui-gamma

- name: Run test-ui-url
uses: reactivecircus/android-emulator-runner@v2
with:
api-level: 29
target: default
force-avd-creation: false
emulator-options: -no-snapshot-save -no-window -gpu swiftshader_indirect -noaudio -no-boot-anim -camera-back none
script: make test-ui-url

- name: Archive Results
uses: actions/upload-artifact@v2
with:
name: Test Report
path: |
build/reports/
if: ${{ failure() }}
Loading

0 comments on commit b5e8d91

Please sign in to comment.