Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Starter pack test #613

Open
wants to merge 4 commits into
base: starter-pack
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 22 additions & 10 deletions .github/workflows/flutter-build-apk.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ name: Build APK Workflow

on:
push:
branches: ['develop', 'starter-pack'] # This specifies that the workflow will run on any push to the 'main' branch
branches: ['develop', 'starter-pack-test'] # This specifies that the workflow will run on any push to the 'main' branch
pull_request:
branches: ['develop', 'starter-pack'] # Optionally, run on pull requests targeting the 'main' branch
branches: ['develop', 'starter-pack-test'] # Optionally, run on pull requests targeting the 'main' branch

jobs:
build-apk:
Expand Down Expand Up @@ -49,14 +49,26 @@ jobs:
echo "HIERARCHY_TYPE=${{ vars.HIERARCHY_TYPE }}" >> apps/health_campaign_field_worker_app/.env
echo "ENV_NAME=${{ vars.ENV_NAME }}" >> apps/health_campaign_field_worker_app/.env

- name: Run APK build script
env:
BUILD_CONFIG: release # or profile depending on your choice
run: bash ./tools/generate-apk.sh
- name: Verify .env file
run: |
ls -l apps/health_campaign_field_worker_app/.env
cat apps/health_campaign_field_worker_app/.env

# - name: Run APK build script
# env:
# BUILD_CONFIG: release # or profile depending on your choice
# run: bash ./tools/generate-apk.sh

# # Archive the APK as a build artifact so it can be downloaded
# - name: Upload APKs
# uses: actions/upload-artifact@v3
# with:
# name: app-release-apk
# path: apps/health_campaign_field_worker_app/build/app/outputs/flutter-apk/app-release.apk

# Archive the APK as a build artifact so it can be downloaded
- name: Upload APKs
- name: Upload .env as artifact
uses: actions/upload-artifact@v3
with:
name: app-release-apk
path: apps/health_campaign_field_worker_app/build/app/outputs/flutter-apk/app-release.apk
name: env-file
path: apps/health_campaign_field_worker_app/.env
include-hidden-files: true
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,8 @@ extension ContextUtilityExtensions on BuildContext {

final projectState = projectBloc.state;

final BeneficiaryType? selectedBeneficiary =
projectState.selectedProject?.targets?.firstOrNull?.beneficiaryType;
final BeneficiaryType? selectedBeneficiary = projectState
.selectedProject?.additionalDetails?.projectType?.beneficiaryType;

if (selectedBeneficiary == null) {
throw AppException('No beneficiary type is selected');
Expand Down
Loading
Loading