How do I skip the "Preparing Working Directory" step?

How do I skip the “Preparing Working Directory” step to speedup my steps that don’t need to clone the repo?

That is the checkout phase. In recent agents, you can set BUILDKITE_REPO to a blank string in a pre-checkout hook and it will skip it.

Might also be worth checking out Shared git repository checkouts in the Agent.

Did this solve your problem @nathan.pierce?

I wanted to follow up on this: Is there any way we can do this in specific steps? Adding it to the hooks makes me uncomfortable as it’s obscure to users of the mac fleet we have. It’d be nice to have an option on the same level as timeout, agents, and plugins, that can be set to avoid the preparing working directory only for certain steps.

There isn’t currently, but @keithpitt and I were discussing adding it to steps as checkout: true|false or possible repository: url | null


We ended up using the plugin to do this, but having it native would be way better and less of a security concern to pulling in a community plugin to our infrastructure/hosts in-house.

Our tests on Friday using the plugin to avoid the checkout cut a lot of wasted time out of the pipelines (more than we estimated); it’s really a great feature to have.

Also, I opened Non-agent hook method of disabling the cloning/submodule update into working directory as a feature request for this. Not sure if that helps. We can re-vote for it if you need us to.