Skip to content

Commit

Permalink
ci: run all workflows on config change (#1829)
Browse files Browse the repository at this point in the history
Signed-off-by: Jared Van Bortel <[email protected]>
  • Loading branch information
cebtenzzre authored Jan 17, 2024
1 parent b98e5f3 commit 15ce428
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 9 deletions.
1 change: 1 addition & 0 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ workflows:
base-revision: main
config-path: .circleci/continue_config.yml
mapping: |
.circleci/.* run-all-workflows true
gpt4all-bindings/python/.* run-python-workflow true
gpt4all-bindings/typescript/.* run-ts-workflow true
gpt4all-bindings/csharp/.* run-csharp-workflow true
Expand Down
37 changes: 28 additions & 9 deletions .circleci/continue_config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ orbs:
node: circleci/[email protected]

parameters:
run-all-workflows:
type: boolean
default: false
run-default-workflow:
type: boolean
default: false
Expand Down Expand Up @@ -1011,11 +1014,17 @@ jobs:
workflows:
version: 2
default:
when: << pipeline.parameters.run-default-workflow >>
when:
or:
- << pipeline.parameters.run-all-workflows >>
- << pipeline.parameters.run-default-workflow >>
jobs:
- default-job
build-chat-offline-installers:
when: << pipeline.parameters.run-chat-workflow >>
when:
or:
- << pipeline.parameters.run-all-workflows >>
- << pipeline.parameters.run-chat-workflow >>
jobs:
- hold:
type: approval
Expand All @@ -1029,7 +1038,10 @@ workflows:
requires:
- hold
build-and-test-gpt4all-chat:
when: << pipeline.parameters.run-chat-workflow >>
when:
or:
- << pipeline.parameters.run-all-workflows >>
- << pipeline.parameters.run-chat-workflow >>
jobs:
- hold:
type: approval
Expand All @@ -1043,7 +1055,10 @@ workflows:
requires:
- hold
deploy-docs:
when: << pipeline.parameters.run-python-workflow >>
when:
or:
- << pipeline.parameters.run-all-workflows >>
- << pipeline.parameters.run-python-workflow >>
jobs:
- build-ts-docs:
filters:
Expand All @@ -1056,7 +1071,10 @@ workflows:
only:
- main
build-py-deploy:
when: << pipeline.parameters.run-python-workflow >>
when:
or:
- << pipeline.parameters.run-all-workflows >>
- << pipeline.parameters.run-python-workflow >>
jobs:
- pypi-hold:
type: approval
Expand Down Expand Up @@ -1091,10 +1109,11 @@ workflows:
- build-py-macos
build-bindings:
when:
or:
- << pipeline.parameters.run-python-workflow >>
- << pipeline.parameters.run-csharp-workflow >>
- << pipeline.parameters.run-ts-workflow >>
or:
- << pipeline.parameters.run-all-workflows >>
- << pipeline.parameters.run-python-workflow >>
- << pipeline.parameters.run-csharp-workflow >>
- << pipeline.parameters.run-ts-workflow >>
jobs:
- hold:
type: approval
Expand Down

0 comments on commit 15ce428

Please sign in to comment.