From c2c4fbd5ee1f7e5b81d54da0672619c65e0bd5ef Mon Sep 17 00:00:00 2001 From: Dani Bodor Date: Tue, 18 Jun 2024 13:41:24 +0200 Subject: [PATCH] extra input --- .github/workflows/build.yml | 11 +++++++---- .github/workflows/remote_build.yml | 5 ++++- 2 files changed, 11 insertions(+), 5 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 2a30b20..e51914f 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -23,6 +23,9 @@ on: caller_branch: required: true type: string + remote: + required: true + type: boolean jobs: build: @@ -46,11 +49,11 @@ jobs: username: wbaccinelli password: ${{ secrets.GITHUB_TOKEN }} - name: Conditionally add specific branch of eitprocessing - if: github.event_name == 'workflow_call' + if: inputs.remote == true run: poetry add git+https://github.com/EIT-ALIVE/eitprocessing.git#${{ inputs.caller_branch }} - name: Run Tests in Container - run: > - echo "action triggered by: ${{github.event_name}}"; + run: | + echo "remote input: ${{inputs.remote}}"; docker run --rm -v $GITHUB_WORKSPACE:/ci @@ -64,7 +67,7 @@ jobs: python -m build' lint: - if: github.event.pull_request.draft == false && github.event_name != 'workflow_call' + if: github.event.pull_request.draft == false && inputs.remote != true name: Linting build runs-on: ubuntu-latest strategy: diff --git a/.github/workflows/remote_build.yml b/.github/workflows/remote_build.yml index c6ce803..540e474 100644 --- a/.github/workflows/remote_build.yml +++ b/.github/workflows/remote_build.yml @@ -6,6 +6,9 @@ on: caller_branch: required: true type: string + remote: + required: true + type: boolean jobs: build: @@ -23,7 +26,7 @@ jobs: repository: EIT-ALIVE/eit_dash # needs to be made explicit to avoid the remote repo being used - name: Verify Repository Structure # echo debugging info in case things go haywire run: | - echo "action triggered by: ${{github.event_name}}"; + echo "remote input: ${{inputs.remote}}"; echo "Current directory: $(pwd)" ls -al echo "Contents of $GITHUB_WORKSPACE:"