amperity / lein-monolith

Leiningen plugin for working with monorepos.
Other
214 stars 18 forks source link

Add :select option to 'each' #8

Closed greglook closed 8 years ago

greglook commented 8 years ago

Per suggestion from @derekslager it'd be useful to have a parallel to the idea of :test-selectors, where you could pass a filter id into each to have it restrict iteration to the projects matching a certain function.

Inside the :monolith config in the metaproject you could have something like this, where the keys are filter ids and the values are functions which run against the (raw) subproject definition:

:project-selectors
{:deployable :deployable
 :bad-versions #(not= "MONOLITH-SNAPSHOT" (:version %))
 ...}