Glob patten support for "vercel.json"'s "git.deploymentEnabled" config

Hello there

I am using a Turborepo which contains several projects which are deloyed to Vercel with a rather simple Git workflow using a development branch for each app (“develop/app-a”).

When pushing changes to “develop/app-a”, a deployment for “app-b”, “app-c”, etc is triggered, which is not desirable.

After looking into the project configuration, I thought this might do the trick. However, since every branch that should be ignored for a certain project has to be disabled explicitly, I had to implement a workaround:

  • explicitly enable branches that should be deployed
  • running a script that collects all enabled branches across all projects and disables them in every project where they are not explicitly allowed

This kind of works for only using a develop branch for each app, but will get out of hands when using feature branches (e.g. “feature/app-a/some-feature”).

Therefore, it would be awesome to be able to configure the project like this:

{
  "git": {
    "deploymentEnabled": {
      "!develop/app-a": false,
      "!feature/app-a/*": false,
    }
  }
}

or even better:

{
  "git": {
    "deploymentEnabled": {
      "main": true,
      "develop/app-a": true,
      "feature/app-a/*": true,
    }
  }
}

Best wishes,
Michael

Hello and welcome, @michaelcamper! You can use Ignored Build Step to skip deploying unchanged projects. There are options to Only build Turborepo app if there are changes, to Only build if there are changes in a folder, or to run a custom script.

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.