Breaking change: Fixing the default publish directory in monorepo configurations

Currently, we default to publishing your root directory if you haven’t specified a publish directory in the UI or netlify.toml. For the most part, this works great! It doesn’t work as well if you haven’t specified a publish directory but you have specified a base directory; in that case, we still publish your root instead of your base directory.

We’re shipping a fix to this behavior on June 14, 2021. We will continue to default to publishing the root as long as no publish or base is set. But if a base directory is set, we will default to publishing that instead of the root.

What does this mean for you?

You will only be impacted if you have a base directory set, but no publish directory.

If you’re not sure whether this applies to you, you can check your build logs. On May 20, we started printing these log lines in builds that would be impacted by the change:

Warning: the “publish” directory was not set and will default to the repository root directory.
To publish the root directory, please set the “publish” directory to “/”
To publish the “base” directory instead, please set the “publish” directory to “${base}”

What do you need to do?

Follow the guidance in the logs, and let us know in this thread if there’s anything we can help with!