-
Notifications
You must be signed in to change notification settings - Fork 263
Development Environment Setup
This document describes how to setup a development environment for Focus iOS that allows you to Build & Run this app on both the sumulator and a real device. It assumes you are a Mozillian with an account on the Mozilla Apple Developer portal.
- An Intel or M1 Mac with the latest macOS 12.
- A
@mozilla.com
Apple ID that has been added to Mozilla's Developer Account with the Developer role and access to Focus iOS. - An iOS device that has been registered in the Mozilla Developer Account.
If you do not have a Developer account, work with your contact to set that up. You cannot use a Free Personal Developer Account to work on Focus iOS. The product uses app extensions, which only work in paid account. Working in the Simulator with your own account is fine though.
TODO We have a PR that needs to land to make it simple to switch development teams. This will allow anyone to work on Focus on their own device. See Move build settings to xcconfig
The latest version of Xcode 13 can be downloaded from developer.apple.com/download/more or the App Store.
After installing Xcode 13, go to Settings/Account and add your @mozilla.com
Apple ID. In the list of Teams & Roles you should see that you are now part of Mozilla Corporation with the Developer role. If you do not see this, reach out to your engineering manager to get that setup.
There is no need to install the command line tools as these are embedded in Xcode and can be activated with:
sudo xcode-select -s /Applications/Xcode.app
git clone [email protected]:mozilla-mobile/focus-ios.git
cd focus-ios
sh ./checkout.sh
This will pull in and convert the tracker blocklists that Focus uses.
Before running on a device, run the app in the simulator. If this works you are 75% there and know that your development environment is setup correctly.
At this point you should be able to select your iOS device and run the app on it.