Say your monorepo is organised this way:
/ README.md ... aCppPrj/ README.md build/ doc/ src/ ... aJavaPrj/ ... aNodePrj/ ... common/
In this example the common directory has some scripts shared by all projects and changes there should queue a build as well.
The build for the C++ project must have a similar trigger
- trigger: paths: include: - 'aCppPrj' - 'common' exclude: - '*'
note the quotes to avoid the YAML parser going mad.You include the folders that must trigger your build and exclude everything else.