This repository was archived by the owner on Jun 15, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 58
Pipeline Structure DSL
Florian Sellmayr edited this page Sep 16, 2015
·
2 revisions
The structure of a pipeline in LambdaCD is defined as a syntax-quoted list of functions.
(def pipeline
`(
(either
wait-for-manual-trigger
wait-for-repo)
(with-repo
run-tests
compile-and-deploy)))
Those functions are the Build Steps. You can either directly put in functions that fulfill the build-step contract or calls to a function that returns a function that fulfills the same contract. Those functions will be evaluated when starting the pipeline.
Pipeline Structures don't have to be static. They can be generated on the fly, using all the usual methods for dealing with (syntax-quoted) lists.
They can be concatenated, filtered, mapped.
Specifically, the unquote-operator ~
can be used to include dynamic values:
(defn mk-pipeline-def [repo-uri test-command]
`(
wait-for-manual-trigger
(with-repo ~repo-uri
(run-tests ~test-command)
publish)))
See also Howto