From 3e7393637aca25b21bf608275693fd7c353e0b3e Mon Sep 17 00:00:00 2001 From: Avi Weiss Date: Tue, 7 Jan 2025 17:24:11 +0100 Subject: [PATCH] add input parameter --- .github/workflows/build-run-app.yml | 12 +++++++----- .github/workflows/unit-test-coverage.yml | 10 ++++++---- apps/sample_app | 2 +- apps/to_lab | 2 +- cfe | 2 +- osal | 2 +- psp | 2 +- tools/cFS-GroundSystem | 2 +- 8 files changed, 19 insertions(+), 15 deletions(-) diff --git a/.github/workflows/build-run-app.yml b/.github/workflows/build-run-app.yml index cd436fcae..e5d346b1d 100644 --- a/.github/workflows/build-run-app.yml +++ b/.github/workflows/build-run-app.yml @@ -14,6 +14,11 @@ on: type: string required: false default: '' + is_framework_app: + description: Whether this is a framework app (TO/CI/SCH Lab, Sample App) + type: boolean + required: false + default: false # Force bash to apply pipefail option so pipeline failures aren't masked defaults: @@ -44,12 +49,9 @@ jobs: steps: - name: Set up environment variables - # Apps typically use lowercase targets and uppercase names, this logic is fragile but works - # Mark the sample app/lib and lab apps as we don't need to add them to the build or startup file (they're already part of the bundle) run: | echo "APP_UPPER=$(echo ${{ inputs.app-name }} | sed 's/[a-z]/\U&/g')" >> $GITHUB_ENV echo "APP_LOWER=$(echo ${{ inputs.app-name }} | sed 's/[A-Z]/\L&/g')" >> $GITHUB_ENV - echo "IS_SAMPLE_OR_LAB=$(echo ${{ inputs.app-name }} | grep -iqE 'sample|lab' && echo true || echo false)" >> $GITHUB_ENV - name: Set up start string for verification run: | @@ -77,13 +79,13 @@ jobs: - name: Add To Build run: | - if [[ "$IS_SAMPLE_OR_LAB" == "false" ]]; then + if [[ "${{ inputs.is_framework_app }}" == "false" ]]; then sed -i "/list(APPEND MISSION_GLOBAL_APPLIST/a list(APPEND MISSION_GLOBAL_APPLIST $APP_LOWER)" sample_defs/targets.cmake fi - name: Add To Startup run: | - if [[ "$IS_SAMPLE_OR_LAB" == "false" ]]; then + if [[ "${{ inputs.is_framework_app }}" == "false" ]]; then sed -i "1i CFE_APP, $APP_LOWER, ${APP_UPPER}_AppMain, $APP_UPPER, 80, 16384, 0x0, 0;" sample_defs/cpu1_cfe_es_startup.scr cat sample_defs/cpu1_cfe_es_startup.scr fi diff --git a/.github/workflows/unit-test-coverage.yml b/.github/workflows/unit-test-coverage.yml index 6ae74c935..3c2d33716 100644 --- a/.github/workflows/unit-test-coverage.yml +++ b/.github/workflows/unit-test-coverage.yml @@ -19,6 +19,11 @@ on: type: number required: false default: 0 + is_framework_app: + description: Whether this is a framework app (TO/CI/SCH Lab, Sample App) + type: boolean + required: false + default: false # Force bash to apply pipefail option so pipeline failures aren't masked defaults: @@ -52,12 +57,9 @@ jobs: run: sudo apt-get install lcov -y - name: Set up environment variables - # Apps typically use lowercase targets and uppercase names, this logic is fragile but works - # Mark the sample app/lib and lab apps as we don't need to add them to the build or startup file (they're already part of the bundle) run: | echo "APP_UPPER=$(echo ${{ inputs.app-name }} | sed 's/[a-z]/\U&/g')" >> $GITHUB_ENV echo "APP_LOWER=$(echo ${{ inputs.app-name }} | sed 's/[A-Z]/\L&/g')" >> $GITHUB_ENV - echo "IS_SAMPLE_OR_LAB=$(echo ${{ inputs.app-name }} | grep -iqE 'sample|lab' && echo true || echo false)" >> $GITHUB_ENV - name: Checkout Bundle Main uses: actions/checkout@v4 @@ -77,7 +79,7 @@ jobs: - name: Add Repo To Build run: | - if [[ "$IS_SAMPLE_OR_LAB" == "false" ]]; then + if [[ "${{ inputs.is_framework_app }}" == "false" ]]; then sed -i "/list(APPEND MISSION_GLOBAL_APPLIST/a list(APPEND MISSION_GLOBAL_APPLIST $APP_LOWER)" sample_defs/targets.cmake fi diff --git a/apps/sample_app b/apps/sample_app index ceaf7ab5f..d6b7277c5 160000 --- a/apps/sample_app +++ b/apps/sample_app @@ -1 +1 @@ -Subproject commit ceaf7ab5fadc7ac80f9bee6f5a2757593417e461 +Subproject commit d6b7277c522715d316e28aa08032094e229b95a9 diff --git a/apps/to_lab b/apps/to_lab index d972baf9e..fe6c9fd51 160000 --- a/apps/to_lab +++ b/apps/to_lab @@ -1 +1 @@ -Subproject commit d972baf9e44e865ed507b31741e78ee83a6b217d +Subproject commit fe6c9fd513f32c45615494554bafdbb646fcba6b diff --git a/cfe b/cfe index 561ff532d..d6e610756 160000 --- a/cfe +++ b/cfe @@ -1 +1 @@ -Subproject commit 561ff532d109d19d9caf8872a62374cb7afc6bfc +Subproject commit d6e610756cc8f2caddf465a92dff92fcd26d8e33 diff --git a/osal b/osal index 827016689..dd4f0e9ba 160000 --- a/osal +++ b/osal @@ -1 +1 @@ -Subproject commit 827016689c1acba664843f18c4081be4dc174743 +Subproject commit dd4f0e9ba58bbf74f364d5cd9e2a6b1d153931d4 diff --git a/psp b/psp index ab82f6a23..cdc73e5f6 160000 --- a/psp +++ b/psp @@ -1 +1 @@ -Subproject commit ab82f6a2336da125ba4cff2a10862869f7016fab +Subproject commit cdc73e5f6564f678207bec69cb75d456795ce91c diff --git a/tools/cFS-GroundSystem b/tools/cFS-GroundSystem index 821a16372..f5efb99f9 160000 --- a/tools/cFS-GroundSystem +++ b/tools/cFS-GroundSystem @@ -1 +1 @@ -Subproject commit 821a163729ebd5bb77ce89711929d55ee837204d +Subproject commit f5efb99f9e9d535ace1bf01285a74c6507876bed