// in ProjectA:
farms {
farm 'X', {
webapp project // ProjectA
}
farm 'Y', {
webapp ':ProjectB'
}
}
// in ProjectC:
farm {
farm 'P', {
webapp project // ProjectC
}
farm 'Q', {
webapp ':ProjectD'
}
}
// in ProjectE:
farms {
farm 'R', {
include ':ProjectA', 'X'
include ':ProjectC', 'Q'
}
farm 'S', {
include ':ProjectA', 'Y'
include ':ProjectC', 'P'
}
}
// Farm 'R' of ProjectE effectively includes webapps ProjectA and ProjectD.
// Farm 'S' of ProjectE effectively includes webapps ProjectB and ProjectC.