Ability to specify root directory
We have a couple of projects that are mono-repo's. Each sub project is contained in a folder but it makes command steps and hooks a bit harder to use.
It would be great to be able to specify a root directory to change into at the start of a build as well as the ability to have folder level hooks.
I.e.
project/
ui/ - root
.buildkite/
api/ - root
.buildkite/hooks/pre-command
Hi @elliot, I think you can already do this by adding a post-checkout hook which changes the $BUILDKITE_BUILD_CHECKOUT_PATH to a subdirectory (export BUILDKITE_BUILD_CHECKOUT_PATH="$BUILDKITE_BUILD_CHECKOUT_PATH/ui"). Local hooks are resolved from the current working (so ui/.buildkite/hooks/pre-command would be run). Does something like that work?
You can see how this works in the beta agent here:
https://github.com/buildkite/agent/blob/5a591236b5e1a35ea97ceeb038797c761b7f0346/bootstrap/bootstrap.go#L1077-L1098
What about if you wanted to have different pipelines from the same repo? In your example, it looks like the ui subfolder would always be selected.