This repository demonstrates a simple Ona setup for multi-repository workspaces.
When the environment is prebuilt, Ona runs an automation that clones every
repository from a GitHub organization into /workspaces/all. VS Code opens at
/workspaces, so the source repository and all cloned repositories are visible
side by side.
Manual or prebuild automation
-> authenticate gh with the Git credential helper
-> list repositories in the configured GitHub organization
-> clone missing repositories into /workspaces/all
-> skip repositories that already exist locally
.ona/automations.yamldefines the automation and when it runs.scripts/clone-org-repositories.shcontains the cloning logic..devcontainer/devcontainer.jsonopens VS Code at/workspaces..devcontainer/Dockerfileinstalls the GitHub CLI.
The automation also runs during prebuilds, but you can run it any time:
gitpod automations task start clone-org-repositoriesRepositories are cloned into:
/workspaces/all/<repository-name>
If you run the automation again, existing repositories are skipped.
To use this pattern with another organization, change ORGANIZATION in
scripts/clone-org-repositories.sh:
ORGANIZATION="your-github-org"To use another clone location, change DESTINATION_ROOT in the same script.