Skip to content

sem 244 support monorepos with single branch - #168

Merged
fiftin merged 3 commits into
mainfrom
sem-244-support-monorepos-with-single-branch
Oct 11, 2026
Merged

fiftin merged 3 commits into
mainfrom
sem-244-support-monorepos-with-single-branch

Conversation

@fiftin

@fiftin fiftin commented Oct 11, 2026

Copy link
Copy Markdown
Collaborator
  • feat: monorepo
  • feat: monorepo

Copilot AI balanced review requested due to automatic review settings October 11, 2026 10:49

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

The checkout-write warning incorrectly limits the restriction to Ansible playbooks despite supporting multiple task applications.

11 open findings
What changed in this PR

Documents shared monorepo checkouts and branch restrictions across English and all translations.

Changes:

  • Explains enabling and operating shared checkouts.
  • Documents disabled template branch controls.
  • Adds localized screenshots and guidance.
File Description
docs/​user-guide/​repositories.md Adds monorepo checkout guidance.
docs/​user-guide/​task-templates/​README.md Documents monorepo branch restrictions.
i18n/​de/​.../​repositories.md Adds German repository guidance.
i18n/​de/​.../​task-templates/​README.md Adds German template guidance.
i18n/​es/​.../​repositories.md Adds Spanish repository guidance.
i18n/​es/​.../​task-templates/​README.md Adds Spanish template guidance.
i18n/​fr/​.../​repositories.md Adds French repository guidance.
i18n/​fr/​.../​task-templates/​README.md Adds French template guidance.
i18n/​it/​.../​repositories.md Adds Italian repository guidance.
i18n/​it/​.../​task-templates/​README.md Adds Italian template guidance.
i18n/​ja/​.../​repositories.md Adds Japanese repository guidance.
i18n/​ja/​.../​task-templates/​README.md Adds Japanese template guidance.
i18n/​ko/​.../​repositories.md Adds Korean repository guidance.
i18n/​ko/​.../​task-templates/​README.md Adds Korean template guidance.
i18n/​pt/​.../​repositories.md Adds Portuguese repository guidance.
i18n/​pt/​.../​task-templates/​README.md Adds Portuguese template guidance.
i18n/​ru/​.../​repositories.md Adds Russian repository guidance.
i18n/​ru/​.../​task-templates/​README.md Adds Russian template guidance.
i18n/​sr/​.../​repositories.md Adds Serbian repository guidance.
i18n/​sr/​.../​task-templates/​README.md Adds Serbian template guidance.
i18n/​zh/​.../​repositories.md Adds Chinese repository guidance.
i18n/​zh/​.../​task-templates/​README.md Adds Chinese template guidance.

🧠 Review effort: Balanced


💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

* Every branch still gets a checkout of its own, so Repositories with different branches never share a working tree.
* The checkout is shared, but the Ansible home directory (roles and collections installed from `requirements.yml`) stays separate for every template.

Because every template works in the same checkout on the same branch, a template of a monorepo cannot have a **Branch** of its own, and it cannot enable the **Branch** prompt that lets a task pick a branch or commit. The template form disables both and explains why, and the API rejects such a template. Make sure the playbooks do not write into the checkout: a changed working tree breaks the next pull, and Semaphore then removes the checkout and clones it again.
* Jeder Branch erhält weiterhin einen eigenen Checkout, sodass Repositories mit unterschiedlichen Branches nie denselben Arbeitsbaum teilen.
* Der Checkout wird gemeinsam genutzt, aber das Ansible-Home-Verzeichnis (aus `requirements.yml` installierte Rollen und Collections) bleibt für jede Vorlage getrennt.

Da alle Vorlagen im selben Checkout auf demselben Branch arbeiten, kann eine Vorlage eines Monorepos keinen eigenen **Branch** haben und den **Branch**-Prompt, mit dem ein Task einen Branch oder Commit wählen kann, nicht aktivieren. Das Vorlagenformular deaktiviert beides und erklärt den Grund, und die API lehnt eine solche Vorlage ab. Stellen Sie sicher, dass die Playbooks nicht in den Checkout schreiben: Ein geänderter Arbeitsbaum bricht den nächsten Pull, und Semaphore entfernt dann den Checkout und klont ihn neu.
* Cada rama sigue teniendo su propia copia, por lo que los repositorios con ramas distintas nunca comparten un árbol de trabajo.
* La copia se comparte, pero el directorio home de Ansible (roles y colecciones instalados desde `requirements.yml`) sigue siendo independiente para cada plantilla.

Como todas las plantillas trabajan en la misma copia y en la misma rama, una plantilla de un monorepo no puede tener una **Rama** propia ni activar la solicitud **Rama**, que permite a una tarea elegir una rama o un commit. El formulario de la plantilla desactiva ambas opciones y explica el motivo, y la API rechaza una plantilla así. Asegúrese de que los playbooks no escriban en la copia: un árbol de trabajo modificado rompe el siguiente pull, y Semaphore entonces elimina la copia y la clona de nuevo.
* Chaque branche conserve sa propre extraction, de sorte que des dépôts avec des branches différentes ne partagent jamais le même arbre de travail.
* L'extraction est partagée, mais le répertoire home d'Ansible (rôles et collections installés depuis `requirements.yml`) reste distinct pour chaque modèle.

Comme tous les modèles travaillent dans la même extraction sur la même branche, un modèle d'un monorepo ne peut pas avoir sa propre **Branche** ni activer l'invite **Branche** qui permet à une tâche de choisir une branche ou un commit. Le formulaire du modèle désactive les deux et en explique la raison, et l'API rejette un tel modèle. Assurez-vous que les playbooks n'écrivent pas dans l'extraction : un arbre de travail modifié casse le pull suivant, et Semaphore supprime alors l'extraction et la clone à nouveau.
* Ogni branch ha comunque un checkout proprio, quindi repository con branch diversi non condividono mai la stessa working tree.
* Il checkout è condiviso, ma la home directory di Ansible (ruoli e collection installati da `requirements.yml`) resta separata per ogni modello.

Poiché tutti i modelli lavorano nello stesso checkout sullo stesso branch, un modello di un monorepo non può avere un **Branch** proprio e non può abilitare il prompt **Branch** che consente a un task di scegliere un branch o un commit. Il modulo del modello disabilita entrambi e ne spiega il motivo, e l'API rifiuta un modello di questo tipo. Assicurarsi che i playbook non scrivano nel checkout: una working tree modificata interrompe il pull successivo e Semaphore rimuove quindi il checkout e lo clona di nuovo.
* 브랜치마다 여전히 자체 체크아웃을 가지므로 브랜치가 다른 리포지토리는 작업 트리를 공유하지 않습니다.
* 체크아웃은 공유되지만 Ansible 홈 디렉터리(`requirements.yml`에서 설치된 역할과 컬렉션)는 템플릿마다 분리되어 있습니다.

모든 템플릿이 같은 브랜치의 같은 체크아웃에서 작업하므로 모노레포의 템플릿은 자체 **브랜치**를 가질 수 없고, 작업이 브랜치나 커밋을 선택할 수 있게 하는 **브랜치** 프롬프트도 활성화할 수 없습니다. 템플릿 폼은 둘 다 비활성화하고 그 이유를 설명하며, API는 그러한 템플릿을 거부합니다. 플레이북이 체크아웃에 쓰지 않도록 하십시오. 작업 트리가 변경되면 다음 pull이 실패하고, Semaphore는 체크아웃을 제거한 뒤 다시 복제합니다.
* Cada branch continua tendo o seu próprio checkout, portanto Repositórios com branches diferentes nunca compartilham uma árvore de trabalho.
* O checkout é compartilhado, mas o diretório home do Ansible (roles e coleções instaladas a partir do `requirements.yml`) permanece separado para cada template.

Como todos os templates trabalham no mesmo checkout e no mesmo branch, um template de um monorepo não pode ter um **Branch** próprio nem ativar o prompt **Branch**, que permite a uma tarefa escolher um branch ou commit. O formulário do template desativa ambos e explica o motivo, e a API rejeita esse template. Certifique-se de que os playbooks não gravem no checkout: uma árvore de trabalho alterada quebra o próximo pull, e o Semaphore então remove o checkout e o clona novamente.
* Для каждой ветки по-прежнему создаётся отдельная рабочая копия, поэтому репозитории с разными ветками никогда не используют одно рабочее дерево.
* Рабочая копия общая, но домашний каталог Ansible (роли и коллекции, установленные из `requirements.yml`) остаётся отдельным для каждого шаблона.

Поскольку все шаблоны работают в одной рабочей копии на одной ветке, у шаблона монорепозитория не может быть собственного поля **Branch**, и он не может включить подсказку **Branch**, которая позволяет задаче выбрать ветку или коммит. Форма шаблона отключает оба поля и объясняет причину, а API отклоняет такой шаблон. Убедитесь, что playbook не пишут в рабочую копию: изменённое рабочее дерево ломает следующий pull, после чего Semaphore удаляет рабочую копию и клонирует её заново.
* Svaka grana i dalje dobija sopstveno preuzimanje, tako da repozitorijumi sa različitim granama nikada ne dele radno stablo.
* Preuzimanje je deljeno, ali Ansible home direktorijum (role i kolekcije instalirane iz `requirements.yml`) ostaje odvojen za svaki šablon.

Pošto svi šabloni rade u istom preuzimanju na istoj grani, šablon monorepo repozitorijuma ne može imati sopstvenu granu (**Branch**) i ne može uključiti upit **Branch** koji zadatku omogućava da izabere granu ili commit. Forma šablona onemogućava oboje i objašnjava zašto, a API odbija takav šablon. Vodite računa da playbook-ovi ne pišu u preuzimanje: izmenjeno radno stablo prekida sledeći pull, pa Semaphore tada uklanja preuzimanje i ponovo ga klonira.
* 每个分支仍然拥有自己的检出,因此分支不同的仓库永远不会共用同一个工作树。
* 检出是共享的,但 Ansible 主目录(从 `requirements.yml` 安装的 role 和 collection)对每个模板仍然是独立的。

由于所有模板都在同一分支的同一检出中工作,monorepo 的模板不能拥有自己的 **Branch**,也不能启用允许任务选择分支或提交的 **Branch** 提示。模板表单会禁用这两项并说明原因,API 也会拒绝这样的模板。请确保 playbook 不会向检出中写入内容:被修改的工作树会导致下一次 pull 失败,Semaphore 随后会删除该检出并重新克隆。
@fiftin
fiftin merged commit f359cdc into main Oct 11, 2026
11 of 12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants