DEV Community

Cover image for Monorepo Support Is Now Generally Available on Semaphore
Marko Anastasov for Semaphore

Posted on

Monorepo Support Is Now Generally Available on Semaphore

Our mission at Semaphore is to empower engineers to ship great products by providing them with a state-of-the-art CI/CD experience. We’re excited to announce that Semaphore now provides out-of-the-box support for monorepo projects.

What is monorepo? 🚝

A monorepo is a version-controlled code repository that holds many projects. While these may be related, they are often logically independent and run by different teams.

A monorepo CI/CD pipeline

How it works? πŸ€”

The key building block of monorepo CI/CD pipelines on Semaphore is the change_in function which detects if a file or set of files have changed in a particular Git commit range.

You can use the change_in function to:

  • Run custom workflows for changes on specific files. Use change_in in combination with glob patterns to define jobs that will run only when certain files change.
  • Skip unnecessary checks. No need to run that whole test suite when you change README.md. Save some CI time by using exclude option to define files and folders you want to ignore.
  • Continuously deploy the right things. Combine change_in with automatic promotions to deploy what has changed.

Monorepo CI/CD workflow in action

So what? 😜

Skipping parts of your code which were not affected by a change can lead to a dramatically faster feedback loop.

For example, the front-end engineering team at BlueLabs was able to reduce their build time from 17mins to 4mins.

BlueLabs monorepo ci/cd workflow

How can I use this? πŸ˜„

Semaphore is free for personal, hobby and open source projects, so giving this a spin is pretty easy.

You can fork a pre-made monorepo demo project and run it yourself.

Or you can just add your own project and play with it.

Happy building!


A more PR-ish version of this announcement was originally published on the Semaphore blog.

Oldest comments (0)