Wire a GitLab, Bitbucket or Azure Repos repository to a project, so a push extracts strings and a merge or pull request comes back with translations.
Who this is for
Owners and admins, on the Team plan or above. You also need permission to create a token and a webhook on the repository.
Before you start
Each of these connects with a token you create in the other system, rather than an installable app. Have ready: an access token with permission to read the repository and open merge or pull requests, and the path and format of your localization files.
Steps
Open Integrations and choose GitLab, Bitbucket or Azure Repos.
Add a connection, pasting the access token you created.
Choose the repository and the transglot project it feeds.
Set the file path pattern, the format, the source locale and the target locales.
Save.
What happens next
The connection is listed with its project. On a push to the default branch, changed source strings are extracted into the project, translated, and returned as a merge or pull request on a branch transglot owns.
Each connection carries its own secret for verifying that incoming pushes really came from your repository, so one connection cannot be used to spoof another.
If it doesn't work
If the connection is refused, check the token has permission both to read the repository and to open merge or pull requests. A read-only token connects but can never deliver anything back.
If pushes do not trigger anything, check the webhook exists on the repository side and points at transglot.
GitLab support covers the hosted service. A self-managed GitLab is not connected this way.
Related
Connect GitHub
Why is my repository sync not running?
