Are you looking for Travis CI alternatives? From this guide, you can learn how to migrate your existing projects from Travis to Bitrise.


Travis vs Bitrise

Travis is all about testing open source projects hosted on GitHub. It supports most of the development platforms and languages, it's deeply integrated with GitHub, so it can help you speed up your code review process by the automated PR comment system.

Bitrise is a universal continuous integration and delivery service. It has one of the best support for mobile development projects, but you can use the platform to automate anything from desktop apps to server-side projects.

A major difference between the two services is that Travis only works with GitHub, while Bitrise supports basically every git hosting provider on the market. You can use your own private git repository too.

Compared to Travis, there is no such thing as a job lifecycle. Bitrise utilizes steps as atomic building blocks. Every single build task is a step. Workflows are basically steps chained together in a given order. There are lots of available steps as part of the Bitrise infrastructure, they are very well documented, and really powerful.

Since Travis has a deep integration with GitHub, you can set up the continuous integration environment for your apps in no time. Moving to Bitrise requires a little bit more effort. That can be a pain point for some people, but there are lots of articles and video tutorials about the basic setup.


Setting up Bitrise is super easy!

I’ll just show you a quick walk-through, so you can see that Bitrise is also very easy to use and it supports all the major git service providers and application templates. First, you have to log in (or register a free account). To create a new app click the Add App menu item and the wizard will guide you through every step in a user-friendly way.

As a first step, you have to select an owner and specify the access level of your brand new app (private or public). Next, you have to connect your git repository (GitHub, Bitbucket, GitLab or manual connection) and provide the necessary credentials, so the CI process can check out the source code, from the given branch.

Bitrise will then validate everything, it even scans your project and gives you a primary workflow based on the code (detected) inside your repository. iOS, Android, Xamarin, fastlane, macOS, Cordova, Ionic, React Native, Flutter are the built-in ones, but you can also set up a completely unique workflow if those won't fit your needs.

Let's assume that you have an iOS app, so as a final step you can customize a few more things like project path, scheme name, export method, build stack (macOS & Xcode version).  Optionally you can register a webhook, to make Bitrise automatically start a build every time "something" happens inside your repository.

No more config files

You can safely remove the hidden .travis.yml file from your repository, you won't need that anymore. At Bitrise every configuration is stored as part of the service, so the CI related stuff won't be mixed with the actual codebase.

I believe this is a huge advantage compared to other providers because you don't have to pollute your git history with useless 'changed ci file again'  commits. I know you can squash & rebase, but honestly, I like the way how Bitrise handles this as a part of the service infrastructure. It's just a small thing, but it has a huge impact on the DX. 🤓

Quick note:
If you'd like to run Bitrise locally, you can install the Bitrise CLI tools through brew, but in order to make it work, you have to create a local bitrise.yml configuration file to declare your workflow.

I don't want to get too much into the workflow setup details, because there are great tutorials about how to setup & fine tune them. Let's just say that you can safely configure everything by using the built-in workflow editor.

Although I would highlight one thing, that's enabled on Travis by default...

Automatic status check on GitHub pull requests

Checking GitHub pull requests is one of the best features of Travis CI. Bitrise can do the exact same thing, you just have to set up the proper webhooks & trigger mechanism to make it work. If you skipped the automatic webhook setup on the Create New App screen you can still enable it on the Code tab. 🔨

Webhooks can be registered automatically for GitHub, Bitbucket or GitLab if you grant access to these service providers on the Account settings page. Otherwise, you can connect webhooks for the following tools manually:

  • GitHub (Code Push, Pull Request, Tag Push)
  • Bitbucket Webhooks (Code Push, Pull Request, Tag Push)
  • Bitbucket Server Webhooks (Code Push, Pull Request, Tag Push)
  • GitLab (Code Push, Merge Request, Tag Push)
  • Visual Studio Online / Visual Studio Team Services (Code Push, Tag Push)
  • Slack (Outgoing Webhook & Slash Command)
  • Gogs (Code Push)
  • Deveo (Code Push, Tag Push)
  • Assembla (Code Push)

After the webhook is connected you will be able to trigger builds based on supported events listed above in the brackets. The nice thing is if you are using GitHub, an automated status check report will be available directly on the pull request page.

You can bind all the available events to build actions, for example, a pull request from the dev source branch to the master target branch can trigger a specific test workflow. These trigger maps for the git repository events can be configured inside the workflow editor under the Triggers tab. 🔫


Conclusion

Congratulations, you just learned the basic process of migrating an iOS project from Travis to Bitrise. As you can see the hardest part of the whole transfer procedure is the initial project set up, but that's quite unavoidable if you are replacing your CI provider. Bitrise can be integrated to GitHub and it can do the exact same checks too.

I believe that if you are looking for a good alternative for Travis, you should definitely try Bitrise. I can't emphasize enough how powerful is the step based workflow setup approach. Bitrise is flexible, feature rich, has an amazing support team and most importantly it's ridiculously easy to learn. Try Bitrise now! 😉


External sources