Skip to main content

Github

First create your fine-grained personal access token.

  1. Go to personal-access-tokens.

  2. Click in Create new token.

  3. Choose a name, for example: twigg-mirror-<YOUR-REPO-NAME>.

  4. Select an expiration date. You'll have to repeat this process when the token expires, so feel free to chose a large duration.

  5. Under Repository access choose Only select repositories and select the target repository.

  6. Under Permissions, click Add permissions, select:

  • Contents, and set access to Read and write.
  • Workflows, and set access to Read and write.
  1. Click Generate token.

  2. Copy the generated token.

Now lets set mirror in twigg.

  1. Go to home and open your repository.
  2. Click in repository setting icon. click_repo_setting_icon
  3. Scroll to Git Mirror section and click on the switch button to enable Git Mirror.
  4. Construct your mirror URL using this format:
https://<TOKEN>@github.com<PATH-TO-YOUR-GITHUB-REPOSITORY>

Example:

https://ghp_abcd1234@github.com/your-org/your-repo.git
  1. Click Save URL.

Your setup is complete. After this, any submitted commits in Twigg will be automatically pushed to the mirror repository on GitHub.