1 min read

GitHub

Last Updated - Platform 21.0 - SDK 16.0

At Poq we use GitHub to host our repositories.

Set up a new repository

  1. After creating your repository locally, open GitHub in your browser.
  2. Tap on the Create New repository button.
  3. Select the correct owner (this should be your organisation, e.g. poqcommerce).
  4. Set the name to match your apps name.

For Poq clients we use the following naming Poq.iOS.ClientName.

  1. Set the repository to Private.
  2. Tap Create Repository to finish.
  3. From your local repository set the remote to your new repository, e.g. https://github.com/poqcommerce/Poq.iOS.ClientName.
  4. Push the repository up as the dev and master branches (or matching your desired branch strategy).

You have done the initial GitHub setup for your app.

Set up branch protection

  1. Set up your CI and run your PR validation pipeline once so that you can set up your branch protection. Check out our Azure DevOps strategy document.
  2. On GitHub head to your repository Settings then Branches.
  3. Make sure the default branch is set to dev (if using GitFlow).
  4. Tap Add rule, set the following rules then Save changes for each branch name pattern:
  • For master use:
    • Requires status checks to pass before merging.
      • Add your PR validation pipeline as a status check.
  • For dev use:
    • Require a pull request before merging.
      • Require approvals (1 review).
    • Requires status checks to pass before merging.
      • Require branches to be up to date before merging.
      • Add your PR validation pipeline as a status check.
  • For release/* and hotfix/* use:
    • Require a pull request before merging.
      • Require approvals (1 review).
    • Requires status checks to pass before merging.
      • Require branches to be up to date before merging.
      • Add your PR validation pipeline as a status check.
    • Allow deletions.

You have set up branch protection.

Set up developer access

  1. On GitHub head to your repository Settings then Manage access.
  2. Tap on Add teams and set the access for each of the following:
  • For ios-admin use Admin.
  • For ios-developer use Write.
  • For ios-reader use Read.
  • For parters we have ios-{partner} teams that should use Read or Write access depending on involvement.
  1. Remove yourself from the list.

You have provided other developers with access.

Next steps