Hi!
I am new in monorepo.
I have a one monorepo and it is hosted on netlify
monorepo
|--- netlify.toml
|--- files.js
|----apps
| |----app1
| | |--- netlify.toml
| |
| |----app2
| |--- netlify.toml
|
|-----libs
| |-----lib1
| | |---filename.js
| |
| |-----lib2
| |---fileeename.js
|
My folder is looks something like this
What I tried on root netlify.toml
[build]
ignore = "git diff --quiet $CACHED_COMMIT_REF $COMMIT_REF . ./libs/"
but not worked
what I tried on app1
and app2
[build]
ignore = "git diff --quiet $CACHED_COMMIT_REF $COMMIT_REF . ../../libs/"
But this also doesn’t work.
What I want to achieve
If I change something on root
folder or libs
folder then netlify should build for every website.
But If I change app1
then It should only build for app1
and ignore app2
or other applications.
If I change app2
then It should only build for app2
and ignore other builds.
But,
- How to achieve that?
- Is there any example project similar like this in GitHub?
- where to place ignore codes in root
netlify.toml
or onapp1
orapp2
netlify.toml
?
Please help me!
Thanks!