You'll need homebrew asdf, Yarn and Watchman installed (brew install watchman
).
There are instructions here: https://asdf-vm.com/guide/getting-started.html You will want the java, nodejs, and ruby plugins to get all of our tooling.
brew install asdf
# configure your shell setup scripts for your shell, see asdfs instructions on the site
asdf plugin add ruby
asdf plugin add nodejs
asdf plugin add java
Download Xcode version 15. You can find all available versions of Xcode at Apple's Developer Portal 🔐.
Ask your mentor to add you on the firebase.console to be able to release.
NOTE: After installing Xcode
Check that Command Line Tools version is added in the Locations tab. Xcode>Settings>Locations:
-
Android development environment: Follow the official docs. Select "React Native CLI Quickstart" tab
-
Create a virtual device on which to run the Android app.
git clone https://github.com/artsy/eigen.git
cd eigen
Work at Artsy?
- Run
asdf install
yarn setup:artsy
yarn install:all
yarn relay
You will need awscli to get our ENV vars.
Artsy/App/EchoNew.json
is used to toggle features and it is not checked in (a sample file is included for OSS contributors). When you runpod install
, the latestEchoNew.json
file will be downloaded for you.
Independent Contributor?
You will need awscli to get our font files. You can configure it with a personal user account.
yarn setup:oss # this is `yarn setup:artsy` if you're working at Artsy
You can create an account on mapbox and get a token with their free tier:
Follow the instructions here: https://docs.mapbox.com/ios/maps/guides/install.
Add the token to .env.shared as MAPBOX_DOWNLOAD_TOKEN
yarn install:all
yarn relay
Some third party services will not function when working as an open source contributor including but not limited to Braze, Unleash, Sentry and Google Sign In. The conversations tab and related features are also inaccessible. Thanks for supporting open source!
Note: yarn pod-install
(which is included in yarn install:all
) may fail the first time you run it (due to a bug in a dependency of ours). Re-running the command should work.
If there are issues setting up the app, see the troubleshooting doc.
We welcome independent contributions! Feel free to open an issue and open a PR and assign one of Brian Beckerle, Pavlos Vinieratos, Mounir Dhahri as a reviewer or anyone else listed here.
If you work at Artsy you can find a ticket on CX backlog 🔐 and look for a #good-first-issue
Start the react-native bundler:
yarn start
First, ask for your apple developer account to be added on the project and login with your apple id under settings/accounts/apple Id.
Open the app in Xcode:
open ios/Artsy.xcworkspace
From Xcode, run the app by hitting Product > Run
(or ⌘R). This will start the Artsy app in an iOS simulator, pointed at Artsy's staging environment.
Make sure that you have a simulator running before running the command. In order to do so you can use the
yarn open-sim
command
yarn ios
Once you've built & run the app through Xcode once, you can use Flipper to run/debug the iOS app locally. This is typically much faster than running through Xcode.
Make sure Flipper is running, then start the iOS simulator directly via your terminal:
yarn open-sim
The simulator that opens should include the Artsy app even if you don’t have xcode running, and then you can use Flipper's dev tools for inspecting log output.
Occasionally you'll need to rebuild the app in Xcode for Flipper. The most likely scenario that requires a rebuild is that you’ve pulled latest, run bundle exec pod install, and dependency versions were updated in Podfile.lock.
Note: You'll want to confirm that the above command started the same simulator that you last ran in xcode, i.e. iPhone 12 vs iPhone 12 max. If it didn't, you can choose the correct simulator from File|Open|…
Note: The Artsy app icon is on the second screen of the simulator, not the first, so make sure you swipe over to find it.
yarn android
This will start the Artsy app in an Android emulator, pointed at Artsy's staging environment.
In order to have internet access on android emulator you need to add Google's DNS servers to your device's network settings. You can do that by following these steps:
- Click Apple menu > System Preferences > Search for DNS.
- Click DNS Domains.
- Select the DNS tab.
- Add 8.8.8.8 and 8.8.4.4
- Click OK > Apply.
- Restart the emulator with cold boot now. (Android Studio > Device Manager > Three Dots (settings) > Cold Boot Now)
⚠️ You might need to run the last step above after you get setup with Artsy's VPN or if you edit your DNS settings!
We can only run tests in one specific environment, today that is iPhone 12 Pro with the iOS 14.2 Simulator. This is because we use visual snapshots for UI regressions.
Tap cmd + u
to run all tests, use ctrl + alt + cmd + g
to run the last set you clicked on via the GUI.
You can run tests via the CLI using:
./scripts/ci/test-ios
We use Xcode's auto-codesigning. It should magically "just work" if you log in to Xcode with an iTunes account which is on the Artsy team.
We have cert troubleshooting here
When you connect an iPhone to your machine, Xcode will prompt you to join a team, then to enable the device for development. If you have to choose a team, choose Art.sY Inc..
- On your Android device go to Settings > About Phone
- Find the 'Build number' menu item and tap it 7 times to enable developer mode.
- Now go to Settings > System > Developer Options, and turn on 'USB Debugging'
- Connect your device to your computer via USB cable. After a moment the device should show a prompt for you to allow USB debugging for your computer. Press yes.
- After that run
yarn android
from within the eigen directory. This will build the app, install it on your device, and run it.
Learn about what things are architecturally here, then move to the blog. for more in-depth discussions on Eigen.