From 2e92f1f6b44577939c26fa0a1555d8d3111a5909 Mon Sep 17 00:00:00 2001 From: kdoroszko-splunk Date: Fri, 30 Aug 2024 12:51:23 +0200 Subject: [PATCH] docs: update setup-workflow description in README.md (#315) Updating README.md to be aligned with the latest changes (https://github.com/splunk/addonfactory-workflow-addon-release/pull/309). --------- Co-authored-by: mkolasinski-splunk <105011638+mkolasinski-splunk@users.noreply.github.com> --- .github/workflows/reusable-build-test-release.yml | 2 +- README.md | 7 ++++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/.github/workflows/reusable-build-test-release.yml b/.github/workflows/reusable-build-test-release.yml index 68950815..f9fa2fb4 100644 --- a/.github/workflows/reusable-build-test-release.yml +++ b/.github/workflows/reusable-build-test-release.yml @@ -168,7 +168,7 @@ jobs: fi ;; "push") - if ${{ github.ref_name == 'main' }} || ${{ github.ref_name == 'develop' }} || ${{ github.ref_type == 'tag' }} || + if ${{ github.ref_name == 'main' }} || ${{ github.ref_name == 'develop' }} || ${{ startsWith(github.ref_name, 'release/') && inputs.execute-tests-on-push-to-release == 'true' }} ; then for test_type in "${TESTSET[@]}"; do EXECUTE_LABELED["$test_type"]="true" diff --git a/README.md b/README.md index 8dc77b6d..3a801f20 100644 --- a/README.md +++ b/README.md @@ -37,7 +37,12 @@ Job that is scanning PR and based on PR body or included labels defining tests t * All tests are executed by default when (controlled from [here](https://github.com/splunk/addonfactory-repository-template/blob/main/enforce/.github/workflows/build-test-release.yml)) * PR target branch is `main` (unless `use_labels` label is used then specific test labels (see below) should be added to execute specific test types) - * push event on branches `main`, `develop` and on `tags` (on release) + * triggering event is push to `main` branch + * triggering event is push to `develop` branch + * triggering event is push event to `release/*` branch + * only when `execute-tests-on-push-to-release` is set to 'true' + * when `execute-tests-on-push-to-release` is set to 'false' tests will not be triggered + * triggering event is workflow_dispatch (used to create custom release version) * schedule event (controlled from [here](https://github.com/splunk/addonfactory-repository-template/blob/main/tools/jinja_parameters.yml)) * To trigger specific test type * add to PR one or multiple labels, available choices can be found [here](https://github.com/splunk/addonfactory-workflow-addon-release/blob/4f3fa4d779b6ec7649f0dc6b973eb4d68e5fcc48/.github/workflows/reusable-build-test-release.yml#L153)