StyleCI Blog

Getting started with StyleCI and GitHub

July 17, 2018

StyleCI Banner

Welcome to our tutorial on getting started with StyleCI and GitHub! If you’d prefer to watch a video, our friends at Laracasts released a free video on StyleCI.

Connecting your account

As with GitLab and BitBucket, connecting your GitHub account to StyleCI is just a few clicks away.

We’re going to start by visiting the StyleCI website at https://styleci.io.

Screen 1

As we’re new to StyleCI, we’ll click the green Get started button, taking us to the Signup page.

Screen 2

To signup with GitHub click the Login with GitHub button. Doing so will take us to a GitHub authorisation page. If you’re asked to login during this stage, please do so. If we’re already signed in, GitHub will ask us to authorise the account. You will see two authentication screens. The first asks only for basic information about you account, so we can determine if you are an existing user.

Screen 3

By default, StyleCI requires access to your public data only. Unless you upgrade to a paid plan and explicitly authorise private access we will not access or use your private data. Clicking Authorise StyleCI will then request additional access, so we can see you public repos:

Screen 4

Let’s break down what we’re accessing here:

  1. Personal user data: We access your email address so that we’re able to communicate with you through transactional emails. We’ll send you a welcome email, updates when a repository has failed to enable and other repository event emails.
  2. Repository webhooks and services: You’ll notice that this is requesting Admin access, this is so that we’re able to create the webhooks that are required to notify StyleCI when you’ve pushed changes to your repository and to report back to the GitHub status.
  3. Repositories: Of course, we need to access your repositories. Unless you’re on a paid plan and have authorised private access, we will be unable to access your private data.
  4. Organisations and teams: This helps us fetch and categorise repositories between your organisations, allowing us to switch you to different accounts.

Click Authorise StyleCI again to agree and continue to your account page.

Screen 5

Congratulations! You’ve now connected your GitHub account to StyleCI, you’re now ready to get your code standards automated.