This gem will help you migrate the repositories you have on https://travis-ci.com from legacy GitHub Services integration to the new GitHub Apps integration.
The main difference is that you will now give Travis CI access to your repositories on a repository basis instead of giving it access to all of them.
Hence, we have developped this gem to help you migrate your repositories that are currently active on Travis CI in one sweep rather than having to add them manually one by one in the GitHub UI.
Here are the steps:
gem install travis_migrate_to_apps
You can generate a new GitHub token here.
Choose the name of your liking and ensure to select the whole repo
scope as shown below:
Then click the "Generate token" button at the bottom to generate the token.
You'll then be back on the GitHub token page:
Take care of copying the newly generated token and save it for later usage.
Note: if you are migrating an organization, the token must be generated by an owner of the GitHub organization.
Go to your profile page on Travis CI: https://travis-ci.com/profile
Click the "Activate GitHub Apps Integration" button highlighted below:
You'll directed to the GitHub Apps page for the Travis CI app:
Choose at least one repository and click the "Approve & Install" button.
You'll then be redirected to your profile page on Travis CI and the newly added repository should appear under "GitHub Apps Integration":
Here are the two ways you can get this token:
- On your profile page: https://travis-ci.com/profile
- Via the Travis CI client by running:
travis token --pro
travis_migrate_to_apps [owner_name] [travis_access_token] [github_access_token]
where
[owner_name]
is the GitHub account (user or organization) where the repositories you want to migrate are located[travis_access_token]
is the Travis CI token obtained in step #4 above[github_access_token]
is the GitHub token obtained in step #2 above
Happy migration!